I just upgraded the FreeBSD buildbot machine from 6.4 to 8.0, and I ran across some interesting differences. The libusb API that we use (0.1) is available in /usr/include/usb.h and /usr/lib/libusb.* as before, but it seems to be the compatibility layer from libusb 1.0. However, it doesn't include the libusb-config binary. This is from the 'ports' Makefile for NUT: ########## - - 8< - - cut here - - ############## .if !defined(WITHOUT_USB) . if ${OSVERSION} < 800069 LIB_DEPENDS+= usb-0.1.8:${PORTSDIR}/devel/libusb . else EXTRA_PATCHES= ${FILESDIR}/extra-patch-m4_nut_check_libusb.m4 . endif CONFIGURE_ARGS+= --with-usb=auto MAN8+= bcmxcp_usb.8 megatec_usb.8 richcomm_usb.8 tripplite_usb.8 \ usbhid-ups.8 PLIST_SUB+= NUT_USB="" .else CONFIGURE_ARGS+= --without-usb PLIST_SUB+= NUT_USB="@comment " .endif ########## - - 8< - - cut here - - ############## The full text of the m4 patch is here: http://www.freebsd.org/cgi/cvsweb.cgi/ports/sysutils/nut/files/extra-patch-m4_nut_check_libusb.m4?rev=1.1;content-type=text%2Fx-cvsweb-markup But the gist of it is that they just hardcode "" and "-lusb" for $CFLAGS and $LDFLAGS, respectively. For many FreeBSD 8.0 users, this will be a non-issue, since they can just run 'make install' in the ports directory. However, given all of the USB stack changes, I suspect we might have to ask some users to test against a SVN version of NUT, so it might be nice to enable USB support out-of-the-box. Suggestions? Arjen: if you don't have much free time, I can do some local testing here, but I am not sure which of the autoconf library search routines I should use as a model. -- - Charles Lepple
> I just upgraded the FreeBSD buildbot machine from 6.4 to 8.0, and I > ran across some interesting differences.For reference, here is the config.log that prompted the preceding email: http://buildbot.ghz.cc/public/nut/FreeBSD-i686/builds/32/step-configure/1 There also seems to be an issue finding uu_lock, but that probably just needs to include sys/types.h first. -- - Charles Lepple
Citeren Charles Lepple <clepple op gmail.com>:> I just upgraded the FreeBSD buildbot machine from 6.4 to 8.0, and I > ran across some interesting differences.I noticed that.> The libusb API that we use (0.1) is available in /usr/include/usb.h > and /usr/lib/libusb.* as before, but it seems to be the compatibility > layer from libusb 1.0.That's OK. The same is happening in other distro's too.> However, it doesn't include the libusb-config binary.That sucks... :-(> But the gist of it is that they just hardcode "" and "-lusb" for > $CFLAGS and $LDFLAGS, respectively.Ditto... :-(> For many FreeBSD 8.0 users, this will be a non-issue, since they can > just run 'make install' in the ports directory. However, given all of > the USB stack changes, I suspect we might have to ask some users to > test against a SVN version of NUT, so it might be nice to enable USB > support out-of-the-box. > > Suggestions?Well, the only thing we could do, is fallback to these defaults if the detection via 'libusb-config' fails to detect the libusb presence. But I really feel that this is a regression in FreeBSD and that not including libusb-config is really hurting. I fail to understand why the FreeBSD maintainers choose this is easier to fix in all packages that use libusb, than to just include a 'libusb-config' that simply returns these values.> Arjen: if you don't have much free time, I can do some local testing > here, but I am not sure which of the autoconf library search routines > I should use as a model.I've submitted something. Once you get the hang of it, the autoconf tools are remarkably easy to use. Best regards, Arjen -- Please keep list traffic on the list