Re: libgphoto2 and sane-backends FTBFS with libusb2-dev
Hi.
Do we have other options except waiting for a new release of libusb2-dev
and removing the outdated kfreebsd packages from testing to make
libgphoto2 and sane-backends swiftly migrate to testing?
Anyways, what keeps us from just integrating
a patch in the libusb2-dev Debian package and do a quick upload. Be it
a normal upload or an NMU.
I am member of maintainer group, but not a DD. I cannot upload myself.
Feel free to use attached patch to debian packaging, alter
debian/changelog as needed and do an upload of freebsd-libs.
Petr
Index: debian/libusb.pc
===================================================================
--- debian/libusb.pc (revision 4785)
+++ debian/libusb.pc (working copy)
@@ -7,4 +7,5 @@
Description: USB access library
Version: 0.1.12
Libs: -L${libdir} -lusb
+Libs.private: -lbsd
Cflags: -I${includedir}
Index: debian/patches/cdefs_macros.diff
===================================================================
--- debian/patches/cdefs_macros.diff (revision 4785)
+++ debian/patches/cdefs_macros.diff (working copy)
@@ -53,6 +53,15 @@
typedef struct libusb_ss_endpoint_companion_descriptor {
uint8_t bLength;
+@@ -250,7 +250,7 @@
+ uint8_t bMaxBurst;
+ uint8_t bmAttributes;
+ uint16_t wBytesPerInterval;
+-} libusb_ss_endpoint_companion_descriptor __aligned(sizeof(void *));
++} libusb_ss_endpoint_companion_descriptor __attribute__((__aligned__(sizeof(void *))));
+
+ typedef struct libusb_interface_descriptor {
+ uint8_t bLength;
@@ -265,12 +265,12 @@
struct libusb_endpoint_descriptor *endpoint;
uint8_t *extra;
@@ -77,6 +86,33 @@
typedef struct libusb_usb_2_0_device_capability_descriptor {
uint8_t bLength;
+@@ -292,7 +292,7 @@
+ uint8_t bDevCapabilityType;
+ uint32_t bmAttributes;
+ #define LIBUSB_USB_2_0_CAPABILITY_LPM_SUPPORT (1 << 1)
+-} libusb_usb_2_0_device_capability_descriptor __aligned(sizeof(void *));
++} libusb_usb_2_0_device_capability_descriptor __attribute__((__aligned__(sizeof(void *))));
+
+ typedef struct libusb_ss_usb_device_capability_descriptor {
+ uint8_t bLength;
+@@ -308,7 +308,7 @@
+ uint8_t bFunctionalitySupport;
+ uint8_t bU1DevExitLat;
+ uint16_t wU2DevExitLat;
+-} libusb_ss_usb_device_capability_descriptor __aligned(sizeof(void *));
++} libusb_ss_usb_device_capability_descriptor __attribute__((__aligned__(sizeof(void *))));
+
+ typedef struct libusb_bos_descriptor {
+ uint8_t bLength;
+@@ -317,7 +317,7 @@
+ uint8_t bNumDeviceCapabilities;
+ struct libusb_usb_2_0_device_capability_descriptor *usb_2_0_ext_cap;
+ struct libusb_ss_usb_device_capability_descriptor *ss_usb_cap;
+-} libusb_bos_descriptor __aligned(sizeof(void *));
++} libusb_bos_descriptor __attribute__((__aligned__(sizeof(void *))));
+
+ typedef struct libusb_control_setup {
+ uint8_t bmRequestType;
@@ -333,7 +333,7 @@
uint32_t length;
uint32_t actual_length;
Index: debian/patches/12_usb.diff
===================================================================
--- debian/patches/12_usb.diff (revision 4785)
+++ debian/patches/12_usb.diff (working copy)
@@ -11,13 +11,14 @@
--- a/lib/libusb/Makefile
+++ b/lib/libusb/Makefile
-@@ -15,6 +15,7 @@
- MAN= libusb.3 libusb20.3
- MKLINT= no
- NOGCCERROR=
+@@ -19,7 +19,7 @@
+ WARNS?= 2
+
+ DPADD= ${LIBPTHREAD}
+-LDADD= -lpthread
+LDADD+= -lpthread -lrt -lbsd
- WARNS?= 2
+ MLINKS+= libusb.3 usb.3
--- a/lib/libusb/libusb.h
+++ b/lib/libusb/libusb.h
Index: debian/libusb-1.0.pc
===================================================================
--- debian/libusb-1.0.pc (revision 4785)
+++ debian/libusb-1.0.pc (working copy)
@@ -7,4 +7,5 @@
Description: C API for USB device access from FreeBSD userspace
Version: 1.0.6
Libs: -L${libdir} -lusb
+Libs.private: -lbsd
Cflags: -I${includedir}
Index: debian/changelog
===================================================================
--- debian/changelog (revision 4785)
+++ debian/changelog (working copy)
@@ -1,3 +1,11 @@
+freebsd-libs (9.1+ds1-3) UNRELEASED; urgency=low
+
+ [ Petr Salinger ]
+ * extend cdefs_macros.diff in libusb.h part
+ * libusb really needs libbsd
+
+ -- Robert Millan <rmh@debian.org> Tue, 16 Jul 2013 15:24:27 +0200
+
freebsd-libs (9.1+ds1-2) unstable; urgency=low
* Bump freebsd-glue B-D (for roundup2).
Reply to: