[Bug 279556] libux_hotplug_callback_handle type incompatibility between FreeBSD and libusb
Date: Thu, 06 Jun 2024 13:52:00 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=279556 Bug ID: 279556 Summary: libux_hotplug_callback_handle type incompatibility between FreeBSD and libusb Product: Base System Version: CURRENT Hardware: Any OS: Any Status: New Severity: Affects Only Me Priority: --- Component: usb Assignee: usb@FreeBSD.org Reporter: emaste@freebsd.org See PR277799 for background. libusb_hotplug_callback_handle_struct has a different type between FreeBSD and libusb FreeBSD: lib/libusb/libusb.h:typedef struct libusb_hotplug_callback_handle_struct *libusb_hotplug_callback_handle; libusb: libusb/libusb.h:typedef int libusb_hotplug_callback_handle; which caused a build failure: ../keepassxc-2.7.7/src/gui/osutils/nixutils/DeviceListenerLibUsb.cpp:71:21: error: no matching function for call to 'libusb_hotplug_register_callback' 71 | const int ret = libusb_hotplug_register_callback( | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ /usr/include/libusb.h:597:5: note: candidate function not viable: no known conversion from 'int *' to 'libusb_hotplug_callback_handle *' (aka 'libusb_hotplug_callback_handle_struct **') for 9th argument 597 | int libusb_hotplug_register_callback(libusb_context *ctx, libusb_hotplug_event events, libusb_hotplug_flag flags, int vendor_id, int product_id, int dev_class, libusb_hotplug_callback_fn cb_fn, void *user_data, libusb_hotplug_callback_handle *handle); | ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -- You are receiving this mail because: You are the assignee for the bug.