Many of our C programs are presented in the form of DLLs in Windows, and Linux is shown in so form.
Windows generally does not have DLL files that cannot be executed because the compiler version of the DLL file is different.
But under Linux, the C program compiled under Linux with different versions of the kernel is prone to problems that cannot be performed under other versions of Linux. The main possibility is that the kernel of the support program is higher than the kernel at compile time or the version is lower than the kernel at compile time.
How do we see if the dynamic-link library file (so suffix) provided to us by others is available under the current Linux system? First we need to see if the relevant file he depends on exists, check the command as follows: LDD file.so
If I want to see if Jnative's dynamic link library is supported under a version of Linux, first switch to the directory where the file is located, and then write the following command:
LDD libjnativecpp.so
If normal, the display is as follows:
libstdc++.so.6 =>/usr/lib/libstdc++.so.6 (0x0069c000)
libm.so.6 =>/lib/tls/libm.so.6 (0x00111000)
libgcc_s.so.1 =>/lib/libgcc_s.so.1 (0x00562000)
libc.so.6 =>/lib/tls/libc.so.6 (0x00134000)
/lib/ Ld-linux.so.2 (0x0097b000)
may appear as follows if not normal:
./libjnativecpp.so:/lib/tls/libc.so.6:version ' glibc_2.4 ' not found (required by./jnativecpp.so)
Libstdc++.so.6 =>/usr/lib/libstdc++.so.6 (0x0047e000)
Libm.so.6 =>/lib/tls/libm.so.6 (0x00111000)
Libc.so.6 =>/lib/tls/libc.so.6 (0x0056e000)
Libgcc_s.so.1 =>/lib/libgcc_s.so.1 (0x00c3d000)
/lib/ld-linux.so.2 (0x0097b000)
Here is the default lib for the famous Jni third party class library, and the error message above shows that our libjnativecpp.so is compiled under the 2.4 kernel and the current kernel version is not supported. After viewing, my current Linux version of the kernel is 2.6 higher than the libjnativecpp.so compile-time kernel.
Turn from: http://blog.csdn.net/kongqz/article/details/4027912