Problem linking with C shared library on linux

I think you're linking/compiling fine now, and that's a runtime error, in the loader

Your issue seems similar/the same as Call functions from a relative path lib.so/dll - #2 by Yandros and Linking Rust application with a dynamic library not in the runtime linker search path - Stack Overflow

Either set the LD_LIBRARY_PATH, use an rpath, or put the .so dylibs in a folder already in your loader's search path

2 Likes