LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Identifying the official (or supported) gcc version for a given Labview version

Solved!
Go to solution

As far as I know, there is no NI web page identifying the official (or at least, supported) gcc/g++ version(s) for a given LabVIEW release.

By 'official version', I mean the one which is binarily compatible with the LabVIEW executable file (i.e. the binary).

NI should provide such information (as Mathworks does for Matlab). Until then, here is a trick to obtain the quested information:

 

1. cd to your local labview installation directory (i.e. where the labview binary is located)

2. type the following command: strings ./labview  | grep GLIBCXX

3. identify the highest GLIBCXX (i.e. stdlibc++) version in the resulting list (let's say GLIBCXX_3.4.9 for LabVIEW 13)

4. open your favorite web browser and visit the gcc ABI Policy and Guidelines page

5. search for the GLIBCXX identified at step 3 (i.e. GLIBCXX_3.4.9 in our case)

6. you should find something like : GCC 4.2.0: GLIBCXX_3.4.9

7. pray to have the corresponding gcc version (i.e. 4.2.0 here)  installed on your host or, at least, to have the corresponding package available for your platform

8. if step 7 fails, be prepared to either: recompile the required gcc version,  upgrade your OS or upgrade your LabVIEW copy

 

 

 

0 Kudos
Message 1 of 7
(4,525 Views)
Solution
Accepted by topic author nl-soleil

Hello,

 

It depends of the OS that you use :

http://zone.ni.com/reference/en-XX/help/371361G-01/lvhowto/compiling_cin_source/

 

For LabVIEW Linux, you have a liste of libstdc++ supported :

http://digital.ni.com/public.nsf/allkb/4596349739E988088625761C005B197E

 

For LabVIEW Windows, it's Microsoft Visual C++ :

http://www.ni.com/white-paper/3056/en/

http://digital.ni.com/public.nsf/allkb/6229347C7982CC81862576E30076A4AE?OpenDocument

 

If you reaaly want to use GCC, there is different workaround, withour support :

http://forums.ni.com/t5/LabVIEW/Creating-a-DLL-including-manager-support-in-mingw-gcc/td-p/633123

 

Best Regards

 

Guillaume D
Message 2 of 7
(4,481 Views)
Solution
Accepted by topic author nl-soleil

Thanks for the information Guillaume! Smiley LOL

 

While it shows that the OP was wrong about NI not documenting what libstdc++ versions LabVIEW requires (which is the really important part, not the gcc compiler version used to create it) there is one information that can be a little misleading to casual users. Your first link references the online help about CIN code resource creation which has been a legacy technology in LabVIEW since at least version 7 and should in the meantime be considered obsolete. The status with CINs at this point is that they do simply not work in RT targets and all 64 bit targets of LabVIEW and support for creating them has been basically removed since at least LabVIEW 2009.

 

Technically the information presented in that online help is equally valid for the creation of DLLs/shared libraries that want to link to the LabVIEW manager API functions but CINs shouldn't be mentioned there anymore. For DLLs/shared libraries not interfacing to LabVIEW manager functions (so DLLs/shared libraries that were not specifically written to interface to LabVIEW) the binary compatibility of the calling application and the shared library is only really important if you happen to want to pass runtime objects from one to the other (creating file handles/descriptors in one and operating on them from the other, or memory pointers created in one and resized and/or freed in the other as an example). Potentially there are more and other complications on Linux with binary compatibility with shared libraries but for Windows that at least are the limitations.

 

 

The problem about having to have the right gcc version stems from the fact that under Linux the standard operation is to install whatever GCC version your fancy strikes you and recompile all the applications from source when problems arise. That obviously doesn't work for closed source applications and the strength of the open source environment gets its weakness here. Otherwise the GCC developers would have spend more time to make sure that different shared library binary versions in the same process can more easily coexist. It may even be intentional to not make it easier as a sort of finger pointing and shaming at closed source applications. However reality here is that LabVIEW for Linux is more likely to be discontinued than that NI makes it open source! Not saying here NI will discontinue it, they have no interest at all to do that, but if forced to make the decision to discontue or go open source I'm 100% sure of the outcome

Rolf Kalbermatter
My Blog
0 Kudos
Message 3 of 7
(4,474 Views)

Guillaume,

Touché 🙂 I finally obtained the info I was looking for. Thanks for that. I tried almost all keywords searching NI web site - without success, cause my search was gcc (i.e. supported compiler) oriented.

 

Rolf,

Right, the stdlibc++ is the important part of the problem. However the gcc version tells you what stdlibc++ it comes with. So it still makes sense to determine which gcc version you need to compile your shared lib for a particular LV version. Anyway, thanks for reply. It contains very useful info.

 

 

 

 

 

0 Kudos
Message 4 of 7
(4,446 Views)

BTW, I found an interesting announcement googling the web about labVIEW and Linux.

0 Kudos
Message 5 of 7
(4,429 Views)

@nl-soleil wrote:

Guillaume,

Touché 🙂 I finally obtained the info I was looking for. Thanks for that. I tried almost all keywords searching NI web site - without success, cause my search was gcc (i.e. supported compiler) oriented.

 

Rolf,

Right, the stdlibc++ is the important part of the problem. However the gcc version tells you what stdlibc++ it comes with. So it still makes sense to determine which gcc version you need to compile your shared lib for a particular LV version. Anyway, thanks for reply. It contains very useful info.


Unless you do not work with a standard GCC installation. Probably not an issue for most normal users and those who thinkered with non-standard stdlibc++ and other libraries support inside a GCC developer toolchain most likely know better about this than you and me together. Smiley Very Happy

Rolf Kalbermatter
My Blog
0 Kudos
Message 6 of 7
(4,404 Views)

@nl-soleil wrote:

BTW, I found an interesting announcement googling the web about labVIEW and Linux.


That was specifically for LabVIEW 2014. This was the first version to support a native 64 Bit Linux version (and 64 Bit MacOS X) and yes CERN was probably one of the driving forces behind this. The other was support for their x86 based NI Linux RT targets. Both these things will make sure that LabVIEW for Linux is not going to disappear quickly from this globe, but Linux will remain one of the several other supported LabVIEW platforms with LabVIEW for Windows making still a larger dent into the pocket than all the others together.

 

But strategically LabVIEW for Linux remains important for NI and got even more important since the NI Linux RT targets appeared. The only problem with customers like CERN is that they are using so much non-standard hardware that they are writing their own interface drivers anyways, so they are not such a strategic force to drive support for DAQmx or other drivers for the Linux platform. And device driver development is to much platform specific that NI Linux RT drivers could simply be taken to desktop Linux.

Rolf Kalbermatter
My Blog
0 Kudos
Message 7 of 7
(4,395 Views)