What is LD_LIBRARY_PATH and how to use it?

前端 未结 6 986
一生所求
一生所求 2020-11-27 16:10

I take part in developing a Java project, which uses some C++ components, thus I need Jacob.dll. (on Windows 7)

I keep getting java.lang.UnsatisfiedLinkError:

6条回答
  •  Happy的楠姐
    2020-11-27 16:35

    My error was also related to not finding the required .so file by a service. I used LD_LIBRARY_PATH variable to priorities the path picked up by the linker to search the required lib.

    I copied both service and .so file in a folder and fed it to LD_LIBRARY_PATH variable as

    LD_LIBRARY_PATH=. ./service
    

    being in the same folder I have given the above command and it worked.

提交回复
热议问题