1
我從一個在Windows上運行的代碼中獲得了一個.jar文件,並且我試圖在Linux上運行它,但我不斷收到此消息,並且不知道該怎麼做做。java.library.path中沒有usbJava
Exception in thread "Thread-0" java.lang.UnsatisfiedLinkError: no usbJava in java.library.path
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1856)
at java.lang.Runtime.loadLibrary0(Runtime.java:845)
at java.lang.System.loadLibrary(System.java:1084)
at ch.ntb.usb.LibusbJava.<clinit>(LibusbJava.java:366)
at ch.ntb.usb.USB.init(USB.java:315)
at ch.ntb.usb.USB.getBus(USB.java:296)
at ch.ntb.usb.Device.initDevice(Device.java:102)
at ch.ntb.usb.Device.open(Device.java:222)
at TransmitterModuleHIDInterface.run(TransmitterModuleHIDInterface.java:28)
at java.lang.Thread.run(Thread.java:722)
我使用產品中的libusb-0.1的Java包裝(我按照安裝說明操作here)。
任何幫助將非常感謝!
不幸的是,這似乎不是問題所在。我設法構建了這個庫,並且我使用了'System.out.println(System.getProperty(「java.library.path」))'來確保在java.library.path上有一個指向它的鏈接 – gbelisario