Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

org.flashtool.libusb.LibUsbException: Libusb not found although it is already installed on macOS #207

Open
sebma opened this issue Dec 22, 2023 · 3 comments

Comments

@sebma
Copy link

sebma commented Dec 22, 2023

Hi,
I have this error on macOS 12.6 :

$ /Applications/FlashTool.app/Contents/MacOS/FlashTool
/Applications/FlashTool.app/Contents/MacOS/x10flasher_native/udev
22/17/2023 18:17:00 - INFO  - <- This level is successfully initialized
22/17/2023 18:17:00 - INFO  - JAVA_HOME : /Applications/FlashTool.app/Contents/MacOS/jre
org.flashtool.libusb.LibUsbException: Libusb not found. Minimum libusb version is 1.0.15. It can be downloaded on http://www.libusbx.org
	at org.flashtool.libusb.UsbSystem.initSystem(UsbSystem.java:32)
	at org.flashtool.libusb.UsbSystem.<init>(UsbSystem.java:19)
	at org.flashtool.jna.linux.JUsb.init(JUsb.java:24)
	at org.flashtool.gui.Main.initLinuxUsb(Main.java:83)
	at org.flashtool.gui.Main.run(Main.java:65)
	at org.flashtool.gui.Main.main(Main.java:49)

but libusb v1.0.26 is already installed :

$ brew info libusb
==> libusb: stable 1.0.26 (bottled), HEAD
Library for USB device access
https://libusb.info/
/usr/local/Cellar/libusb/1.0.26 (22 files, 531.7KB) *
  Poured from bottle on 2022-12-30 at 00:57:31
From: https:/Homebrew/homebrew-core/blob/HEAD/Formula/lib/libusb.rb
License: LGPL-2.1-or-later
==> Options
--HEAD
	Install HEAD version
$
@sebma sebma changed the title org.flashtool.libusb.LibUsbException: Libusb not found on macOS org.flashtool.libusb.LibUsbException: Libusb not found although it is already installed on macOS Dec 22, 2023
@nms42
Copy link

nms42 commented Jun 12, 2024

In folder FlashTool.app/Contents/MacOS/x10flasher_native/udev there is incorrect symlink

libusbx-1.0.dylib -> /Users/emmanuel/git/Flashtool/Flashtool/build/install/Flashtool/FlashTool.app/Contents/MacOS/x10flasher_native/udev/libusbx-1.0.0.dylib

Should it be libusbx-1.0.dylib -> libusbx-1.0.0.dylib?

@MartinVonReichenberg
Copy link

MartinVonReichenberg commented Jun 13, 2024

In folder FlashTool.app/Contents/MacOS/x10flasher_native/udev there is incorrect symlink

libusbx-1.0.dylib -> /Users/emmanuel/git/Flashtool/Flashtool/build/install/Flashtool/FlashTool.app/Contents/MacOS/x10flasher_native/udev/libusbx-1.0.0.dylib

Should it be libusbx-1.0.dylib -> libusbx-1.0.0.dylib?

If it is meant to be a UNIX/POSIX-like symlink then you can use any name you want/need for the link pointing to the source . . .

@biaji
Copy link

biaji commented Oct 14, 2024

In folder FlashTool.app/Contents/MacOS/x10flasher_native/udev there is incorrect symlink

libusbx-1.0.dylib -> /Users/emmanuel/git/Flashtool/Flashtool/build/install/Flashtool/FlashTool.app/Contents/MacOS/x10flasher_native/udev/libusbx-1.0.0.dylib

Should it be libusbx-1.0.dylib -> libusbx-1.0.0.dylib?

ln -sf libusbx-1.0.0.dylib libusbx-1.0.dylib

and it's work like a charm

the origin code caused this is :

  public static final LibUsbLibrary libUsb = (LibUsbLibrary)Native.loadLibrary("usbx-1.0", LibUsbLibrary.class);

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants