I am using CentOS6.9 and I am using python3.6 to load the c library from a .so file. However, I have encounter the following error:
OSError: /lib64/libc.so.6: version 'GLIBC_2.14' not found
I did some research and found out it is because centOS 6 is using version 2.12. I follow one of the post from here(https://stackoverflow.com/a/38317265/8406938) to install GLIBC_2.14 in centOS 6, and can now successfully run external applications if they're linked against this libc by first running:
export LD_LIBRARY_PATH=/opt/glibc-2.14
My question is after I install that, how do I use it in python such that I can load the library through ctypes, here is the code I load:
filepath = os.path.dirname(os.path.join(os.path.realpath(__file__)))
lib = CDLL(os.path.join(filepath, 'lib.so'))
I still get the error
OSError: /lib64/libc.so.6: version 'GLIBC_2.14' not found
after I install 2.14. Do I need to set something in python (like the path variable) in order to use it?