Closed spongus711 closed 1 year ago
Hello, Under which flavor of Linux and libc can you see this build error ? Also, is it when building against libusb 0.1.x, which is scarce on modern distros, rather than the libusb 0.1.x compatibility layer for libusb 1.0.x ? libticalcs' libusb 0.1.x backend cannot work against the latter, and by now, most users should be using the libusb 1.0.x backend, which - unless there's a bug - ought to be enabled by default :)
I'm using Linux Mint 20.3 with libc 2.31, and libusb 1.0.0.
The libusb 1.0.x backend is in link_usb1.c, so you're compiling against the libusb 0.1.x API, whether you're using the compat layer or not.
With libusb-1.0-0-dev
installed, try passing --enable-libusb10
to libticables' configure explicitly. That's what both the standard libti*+gfm+tilp maintainer and the user build scripts ( https://github.com/debrouxl/tilp_and_gfm/blob/master/tilp/trunk/build/scripts/install_tilp.sh ) are doing, for historical reasons.
(that said, it does look like the fix is correct? At least the other usages of this struct have struct
)
Building against libusb 0.1.12 throws the same error as before, so I think struct
does belong there. And --enable-libusb10
works with libusb 1.0.x, thanks.
when building for linux, the compiler gives the following errors which have been fixed in this commit:
linux/link_usb.cc:402:31: error: expected primary-expression before ‘)’ token 402 | *udh = usb_open((usb_device *)(tigl_devices[id].dev));
linux/link_usb.cc:507:22: error: expected primary-expression before ‘)’ token 507 | uDev = (usb_device *)(tigl_devices[h->address].dev);