WindowsLinuxMac OS X
NOTE: This document addresses only how LabVIEW locates shared libraries specified by name in the Call Library Function dialog box. If you specify a shared library by path, LabVIEW uses its own algorithm to locate the shared library. Specifying a shared library by path produces different consequences when you distribute or relocate your VIs and applications. Refer to the Specifying the Locations of Shared Libraries on Disk topic in the LabVIEW Help (linked below) for more information about these consequences as well as how LabVIEW loads a shared library by path.
When you specify a shared library by name on Windows, LabVIEW locates the shared library by calling the Win32 function LoadLibraryEx with the flag LOAD_WITH_ALTERED_SEARCH_PATH. The Dynamic-Link Library Search Order topic in MSDN (linked below) describes the specific directories that the function searches. However, LabVIEW makes the following two modifications to this search algorithm:
When you specify a shared library by name on Linux, LabVIEW locates the shared library by calling the dlopen function using RTLD_NOW for the mode parameter. Refer to the main page for dlopen for more details about its behavior.This function searches in the following locations:
LabVIEW does not define the values of LD_LIBRARY_PATH or _CS_LIBPATH, but LabVIEW does specify the following locations for RPATH.
For VIs running in the LabVIEW development environment, RPATH includes the following directories, in order:
For LabVIEW-built applications that run in the LabVIEW Run-Time Engine, RPATH includes the following directories, in order:
Mac OS X
When you specify a shared library by name on Mac OS X, LabVIEW can load both frameworks and dylibs. LabVIEW initially attempts to load both kinds of shared libraries as a framework by searching in the following directories, in order:
/Applications/National Instruments/LabVIEW <year>/resource
<User Application Support>/National Instruments
~/Library/Application Support/National Instruments
<Local Application Support>/National Instruments
/Library/Application Support/National Instruments
If LabVIEW fails to load the shared library as a framework, LabVIEW then tries to load the shared library as a dylib by using the dlopen function. Refer to the Mac OS X Developer Library: dlopen(3) Mac OS X Manual Page (linked below) for the search order performed by that function.
NOTE: If you specify a shared library name as library.*, LabVIEW replaces .* with .framework.
Collaborate with other users in our discussion forums
A valid service agreement may be required, and support options vary by country.