简体   繁体   中英

Java Exception in thread “main” java.lang.UnsatisfiedLinkError:

Exception in thread "main" java.lang.UnsatisfiedLinkError:    
/home/stud/userx/Downloads/lp_solve_5.5_java/lib/ux64/liblpsolve55j.so: liblpsolve55.so: cannot open shared object file: No such file or directory

But in the folder is:

liblpsolve55j.so
liblpsolve55.so

Why does java not find it?

It is right there!

启动应用程序时,必须将java.library.path属性设置为所需的.so所在的目录,否则将收到UnsatisfiedLinkError ,例如:

java -Djava.library.path=<path_to_.so> <main_class>

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM