How to install LabVIEW on a Debian Machine

Labview ships prepackaged to install on rpm based Linux machines (Redhat, Mandrake and so on). But it is quite simple to convert and install it on a Debian machine instead.

The machine I will be using is a Thinkpad T40 with Debian Lenny installed, it should be the same for the current stable (Etch) but this is yet to be confirmed.

First we need to install alien

# aptitude install alien

The conversion process is quite simple, all you have to is to type

# alien -d *.rpm

And after some time (about 15 minutes or so on my laptop) you should be left with a bunch of .deb files.

You might have guessed it.. to install:

# dpkg -i *.deb

Now for the hacking part, when you try to run Labview all you get is this error:

/usr/local/natinst/LabVIEW-8.2/labview: symbol lookup error: /usr/local/natinst/LabVIEW-8.2/linux/ undefined symbol: _glapi_add_entrypoint

To work around this you need to install libosmesa (of current writing libosmesa6)

# aptitude install libosmesa6

and relink

# (cd /usr/local/natinst/LabVIEW-8.2/linux; rm; ln -s /usr/lib/

And it works! If you feel like it, you can also put a little icon on your desktop or in your Applications menu (this part is for gnome), this is the contents of the labview.desktop file with my corrections. It originates from /usr/local/natinst/LabVIEW-8.2/linux/gnome/gnome/apps/Applications/labview82.desktop and there is a similar file for KDE in the /usr/local/natinst/LabVIEW-8.2/linux/kde folder for those who want to make a KDE shortcut.
Contents of labview82.desktop

[Desktop Entry]
Name=LabVIEW 8.2
Comment=LabVIEW Graphical Dataflow Programming Environment

This file can be placed either in ~/.local/share/applications/ or in /usr/share/applications