Why Does Linux GPIB for 64bits Not Have Libgpibapi-so?

Updated Jun 17, 2019

Reported In


  • NI-488.2

Operating System

  • Linux

Programming Language

  • C
  • C++

Issue Details

I used GPIB for 32bits on Linux and changed it to 64bits this time and installed the driver for 64bits, but I can not find libgpibapi.so. Why is this happening?


Based on NI-488.2 15.1 for Linux, the following objects are installed for 32-bit and 64-bit, respectively.
  • 32bits
$ rpm -ql ni4882i-15.1.0-f0.i386 | grep lib    
  • 64bits
$ rpm -ql ni4882i-15.1.0-f0.x86_64 | grep lib 
[usernet@swdev1 natinst]$ 

If you have installed the Linux GPIB driver for 64bits, it is normal for libgpibapi.so not to be installed. 
The NI 488.2 User manual has the following description:
The NI-488.2 for Windows 2.6, NI-488.2 for Linux 3.2, and NI-488.2 for Mac OS X 3.2 releases officially add support for a new API as part of the 64-bit application interface. Every effort has been made to have the new NI4882 API closely match the existing GPIB32 API while incorporating API design best practices. To use the new API, you must recompile applications using the new header and object files.

Modifying existing applications to use the NI4882 API should require minimal changes. In most cases, using the new include file (ni4882.h instead of ni488.h) and linking to the new object file:
(Windows) ni4882.obj instead of gpib-32.obj
(Linux) libni4882.so instead of libgpibapi.so
(OS X) ni4882.framework instead of ni488.framework

So if you want to reuse existing code, you need to change the header files and object files and recompile it. Please refer to the NI 488.2 User Manual to determine the differences between the two libraries.