diff options
83 files changed, 842 insertions, 157 deletions
diff --git a/astro/gpsbabel/Makefile b/astro/gpsbabel/Makefile index d40659b9a567..f8b5c7f1f6c1 100644 --- a/astro/gpsbabel/Makefile +++ b/astro/gpsbabel/Makefile @@ -12,12 +12,19 @@ MASTER_SITES= http://www.lexort.com/pkgsrc/distfiles/ MAINTAINER= wenheping@gmail.com COMMENT= A gps file translating tool -LIB_DEPENDS= usb:${PORTSDIR}/devel/libusb \ - expat:${PORTSDIR}/textproc/expat2 +LIB_DEPENDS= expat:${PORTSDIR}/textproc/expat2 USE_AUTOTOOLS= autoconf:262 GNU_CONFIGURE= yes PLIST_FILES= bin/gpsbabel -.include <bsd.port.mk> +.include <bsd.port.pre.mk> + +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb:${PORTSDIR}/devel/libusb +.else +EXTRA_PATCHES= ${FILESDIR}/extra-patch-libusb +.endif + +.include <bsd.port.post.mk> diff --git a/astro/gpsbabel/files/extra-patch-libusb b/astro/gpsbabel/files/extra-patch-libusb new file mode 100644 index 000000000000..4bf7613de5d0 --- /dev/null +++ b/astro/gpsbabel/files/extra-patch-libusb @@ -0,0 +1,31 @@ +--- configure.in.orig 2008-10-31 15:43:21.000000000 +0300 ++++ configure.in 2009-03-07 01:08:46.000000000 +0300 +@@ -170,6 +169,28 @@ + AC_DEFINE(HAVE_LIBUSB, 1) + CFLAGS="$CFLAGS -Imac/libusb/" + ;; ++ *-*-freebsd*) ++ GBSER=gbser_posix.o ++ AC_MSG_CHECKING(for libusb) ++ if test "$with_libusb" = no ; then ++ AC_MSG_RESULT(check not done) ++ OSJEEPS=jeeps/gpsusbstub.o ++ else ++ OLDFLAGS=$LDFLAGS ++ OCFLAGS=$CFLAGS ++ LDFLAGS="$LDFLAGS -lusb" ++ CFLAGS="$OCFLAGS" ++ ++ AC_CHECK_LIB([usb], [usb_interrupt_read], ++ AC_DEFINE(HAVE_LIBUSB, 1, [Defined if you have libusb]) ++ [USB_CFLAGS=""] ++ [USB_LIBS="-lusb"] ++# ,[AC_MSG_ERROR([libusb is needed])] ++ ) ++ OSJEEPS=jeeps/gpslibusb.o ++ CFLAGS="$OCFLAGS" ++ fi ++ ;; + *) + GBSER=gbser_posix.o + AC_MSG_CHECKING(for libusb) diff --git a/audio/ardour/Makefile b/audio/ardour/Makefile index 0a691b1137ba..6bef2ebdf17a 100644 --- a/audio/ardour/Makefile +++ b/audio/ardour/Makefile @@ -25,7 +25,6 @@ LIB_DEPENDS= lrdf.2:${PORTSDIR}/textproc/liblrdf \ sqlite3:${PORTSDIR}/databases/sqlite3 \ lo.6:${PORTSDIR}/audio/liblo \ SoundTouch.0:${PORTSDIR}/audio/soundtouch \ - usb:${PORTSDIR}/devel/libusb \ fftw3f:${PORTSDIR}/math/fftw3-float \ fftw3:${PORTSDIR}/math/fftw3 \ aubio.3:${PORTSDIR}/audio/aubio @@ -53,6 +52,10 @@ OPTIONS= OPTIMIZED_CFLAGS "Builds with compiler optimizations" on \ BROKEN= needs posix_memalign() .endif +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb:${PORTSDIR}/devel/libusb +.endif + .if defined(WITH_VST) # Yes, 'PlugIns' is not a typo. VST_DIST+= vst_sdk2_3.zip diff --git a/audio/ifp-line/Makefile b/audio/ifp-line/Makefile index f1a95a8a4460..c08ce5d28dc5 100644 --- a/audio/ifp-line/Makefile +++ b/audio/ifp-line/Makefile @@ -15,13 +15,23 @@ MASTER_SITE_SUBDIR= ifp-driver MAINTAINER= riggs@rrr.de COMMENT= Command line interface to iRiver music players -LIB_DEPENDS= usb-0.1.8:${PORTSDIR}/devel/libusb - MAN1= ifp.1 PLIST_FILES+= bin/ifp +.include <bsd.port.pre.mk> + +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb-0.1.8:${PORTSDIR}/devel/libusb +.endif + +post-patch: +.if ${OSVERSION} >= 800069 + @${REINPLACE_CMD} -E -e 's,`libusb-config --cflags`,,g' \ + -e 's,`libusb-config --libs`,-lusb,g' ${WRKSRC}/Makefile +.endif + post-install: @${CAT} ${.CURDIR}/pkg-message -.include <bsd.port.mk> +.include <bsd.port.post.mk> diff --git a/audio/libmtp/Makefile b/audio/libmtp/Makefile index fdd2c69be81b..8636bb2b16ff 100644 --- a/audio/libmtp/Makefile +++ b/audio/libmtp/Makefile @@ -15,8 +15,7 @@ MASTER_SITE_SUBDIR= ${PORTNAME} MAINTAINER= pesho.petrov@gmail.com COMMENT= Media Transfer Protocol (MTP) library -LIB_DEPENDS= usb:${PORTSDIR}/devel/libusb \ - iconv:${PORTSDIR}/converters/libiconv +LIB_DEPENDS= iconv:${PORTSDIR}/converters/libiconv GNU_CONFIGURE= yes CONFIGURE_ENV= LDFLAGS="${LDFLAGS}" CPPFLAGS="${CPPFLAGS}" @@ -26,7 +25,12 @@ USE_LDCONFIG= yes CPPFLAGS= -I${LOCALBASE}/include LDFLAGS= -L${LOCALBASE}/lib -liconv +.include <bsd.port.pre.mk> +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb:${PORTSDIR}/devel/libusb +.endif + post-patch: @${REINPLACE_CMD} -e '/^SUBDIRS/s|doc||' ${WRKSRC}/Makefile.in -.include <bsd.port.mk> +.include <bsd.port.post.mk> diff --git a/audio/libnjb/Makefile b/audio/libnjb/Makefile index 6ae6d5a912b1..8b158fad8af8 100644 --- a/audio/libnjb/Makefile +++ b/audio/libnjb/Makefile @@ -14,8 +14,6 @@ MASTER_SITES= SF MAINTAINER= ports@FreeBSD.org COMMENT= C library, API for communicating with Creative and Dell audio players -LIB_DEPENDS= usb-0.1.8:${PORTSDIR}/devel/libusb - USE_AUTOTOOLS= libtool:15 GNU_CONFIGURE= yes CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include" \ @@ -24,6 +22,10 @@ USE_LDCONFIG= yes .include <bsd.port.pre.mk> +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb-0.1.8:${PORTSDIR}/devel/libusb +.endif + .if !defined(NOPORTDOCS) BUILD_DEPENDS+= doxygen:${PORTSDIR}/devel/doxygen PLIST_SUB= PORTVERSION=${PORTVERSION} diff --git a/audio/mpiosh/Makefile b/audio/mpiosh/Makefile index 0c51baec17bc..8d62ba3a0585 100644 --- a/audio/mpiosh/Makefile +++ b/audio/mpiosh/Makefile @@ -14,8 +14,6 @@ DISTNAME= mpio-${PORTVERSION:S|.p|_pre|} MAINTAINER= ports@FreeBSD.org COMMENT= Digit@lway MPIO MP3 player tool -LIB_DEPENDS= usb-0.1:${PORTSDIR}/devel/libusb - USE_AUTOTOOLS= libtool:15 USE_ICONV= yes GNU_CONFIGURE= yes @@ -23,4 +21,18 @@ USE_LDCONFIG= yes CONFIGURE_ENV= CFLAGS="-I${LOCALBASE}/include" LDFLAGS="-L${LOCALBASE}/lib" -.include <bsd.port.mk> +.include <bsd.port.pre.mk> + +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb-0.1:${PORTSDIR}/devel/libusb +.else +EXTRA_PATCHES= ${FILESDIR}/extra-patch-configure.in +USE_AUTOTOOLS= autoconf:262 +.endif + +post-patch: +.if ${OSVERSION} >= 800069 + ${RM} -f ${WRKSRC}/configure +.endif + +.include <bsd.port.post.mk> diff --git a/audio/mpiosh/files/extra-patch-configure.in b/audio/mpiosh/files/extra-patch-configure.in new file mode 100644 index 000000000000..22deee13d378 --- /dev/null +++ b/audio/mpiosh/files/extra-patch-configure.in @@ -0,0 +1,41 @@ +--- configure.in.orig 2004-05-30 05:45:55.000000000 +0400 ++++ configure.in 2009-03-07 01:43:55.000000000 +0300 +@@ -60,34 +60,18 @@ + dnl -- check for libusb + dnl -- this is stolen from libgphoto2 + +-AC_PATH_PROG(LIBUSB_CONFIG,libusb-config) +-if test -n "${LIBUSB_CONFIG}"; then +- CPPFLAGS_save="$CPPFLAGS" +- CPPFLAGS="$CPPFLAGS `$LIBUSB_CONFIG --cflags`" ++CPPFLAGS_save="$CPPFLAGS" + AC_CHECK_HEADER(usb.h,[ + LDFLAGS_orig="$LDFLAGS" +- LDFLAGS="`$LIBUSB_CONFIG --libs`" ++ LDFLAGS="-lusb" + AC_CHECK_LIB(usb,usb_busses,[ + usb_msg="yes" + IOLIB_SUBDIRS="$IOLIB_SUBDIRS usb" +- USB_LIBS="`$LIBUSB_CONFIG --libs`" +- USB_CFLAGS="`$LIBUSB_CONFIG --cflags`" +- LIBUSB_VER="`$LIBUSB_CONFIG --version`"],[ ++ USB_LIBS="-lusb" ++ USB_CFLAGS=""],[ + usb_msg="no (available version too old)"]) + LDFLAGS="$LDFLAGS_orig"]) + CPPFLAGS="$CPPFLAGS_save" +-fi +- +- # This 'test' call uses non-standard syntax and will fail on most +- # systems, but it's just informational so any warning can be ignored. +-if test "$LIBUSB_VER" \< "0.1.7"; then +- AC_MSG_WARN([ +-*** You need at least version 0.1.7 of the libusb library for USB support +-*** http://sourceforge.net/projects/libusb/ +-*** If you cannot find the appropriate version, try CVS +- ]) +- exit 1 +-fi + + case "$usb_msg" in + yes*) AC_DEFINE(HAVE_USB,1,[Whether you have USB support enabled]);; diff --git a/audio/rioutil/Makefile b/audio/rioutil/Makefile index 1ad61d795220..f2ae6eef104f 100644 --- a/audio/rioutil/Makefile +++ b/audio/rioutil/Makefile @@ -13,8 +13,6 @@ MASTER_SITES= SF MAINTAINER= ports@FreeBSD.org COMMENT= A program to inferface with the Rio600, Rio800, and psa[play devices -LIB_DEPENDS= usb-0.1.8:${PORTSDIR}/devel/libusb - USE_AUTOTOOLS= libtool:15 USE_GMAKE= yes GNU_CONFIGURE= yes @@ -26,10 +24,19 @@ MAN1= rioutil.1 CPPFLAGS= -I${LOCALBASE}/include LDFLAGS= -L${LOCALBASE}/lib +.include <bsd.port.pre.mk> + +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb-0.1.8:${PORTSDIR}/devel/libusb +.else +EXTRA_PATCHES= ${FILESDIR}/extra-patch-configure.ac +USE_AUTOTOOLS= autoconf:262 +.endif + post-extract: - @${RM} -f ${WRKSRC}/src/getopt* +# @${RM} -f ${WRKSRC}/src/getopt* # Fix for GCC 4.2 @${REINPLACE_CMD} -e 's,read_buffer = .*),(&),' \ ${WRKSRC}/librioutil/rio.c -.include <bsd.port.mk> +.include <bsd.port.post.mk> diff --git a/audio/rioutil/files/extra-patch-configure.ac b/audio/rioutil/files/extra-patch-configure.ac new file mode 100644 index 000000000000..34d3d9d06a68 --- /dev/null +++ b/audio/rioutil/files/extra-patch-configure.ac @@ -0,0 +1,17 @@ +--- configure.ac.orig 2009-03-07 01:48:24.000000000 +0300 ++++ configure.ac 2009-03-07 01:49:07.000000000 +0300 +@@ -74,13 +74,7 @@ + AC_MSG_RESULT(yes) + AC_DEFINE_UNQUOTED(WITH_LIBUSB) + +- AC_PATH_PROG(LIBUSB_CONFIG,libusb-config) +- if test -n "${LIBUSB_CONFIG}"; then +- CFLAGS="`${LIBUSB_CONFIG} --cflags` $CFLAGS" +- LIBS="`${LIBUSB_CONFIG} --libs` $LIBS" +- else +- AC_MSG_ERROR(Can't find libusb) +- fi ++ LIBS="-lusb $LIBS" + + AC_CHECK_LIB(usb, usb_open) + AC_SUBST(WITH_LIBUSB) diff --git a/comms/dfu-util/Makefile b/comms/dfu-util/Makefile index 6f8748f77847..00f953e601e7 100644 --- a/comms/dfu-util/Makefile +++ b/comms/dfu-util/Makefile @@ -23,7 +23,7 @@ GNU_CONFIGURE= yes .include <bsd.port.pre.mk> -.if ${OSVERSION} < 800063 +.if ${OSVERSION} < 800069 IGNORE= requires new USB stack in FreeBSD 8 .endif diff --git a/comms/dfu-util/files/patch-configure.ac b/comms/dfu-util/files/patch-configure.ac index b8e800739dd7..956d8181827e 100644 --- a/comms/dfu-util/files/patch-configure.ac +++ b/comms/dfu-util/files/patch-configure.ac @@ -1,13 +1,13 @@ ---- configure.ac.orig 2008-10-07 14:14:07.000000000 +0100 -+++ configure.ac 2009-02-04 22:04:02.000000000 +0000 -@@ -15,9 +15,7 @@ +--- configure.ac.orig 2008-10-07 17:14:07.000000000 +0400 ++++ configure.ac 2009-03-08 11:54:32.000000000 +0300 +@@ -15,9 +15,8 @@ # Checks for libraries. -PKG_CHECK_MODULES(USB, libusb >= 0.1.4,, - AC_MSG_ERROR([*** Required libusb >= 0.1.4 not installed ***])) --AC_CHECK_LIB([usbpath],[usb_path2devnum],,,-lusb) -+USB_LIBS=-lusb20 + AC_CHECK_LIB([usbpath],[usb_path2devnum],,,-lusb) ++USB_LIBS=-lusb LIBS="$LIBS $USB_LIBS" CFLAGS="$CFLAGS $USB_CFLAGS" diff --git a/comms/dfu-util/files/patch-src-commands.h b/comms/dfu-util/files/patch-src-commands.h deleted file mode 100644 index 2cfa3d43aef5..000000000000 --- a/comms/dfu-util/files/patch-src-commands.h +++ /dev/null @@ -1,11 +0,0 @@ ---- src/commands.h.orig 2007-02-22 21:33:15.000000000 +0000 -+++ src/commands.h 2009-02-04 22:04:41.000000000 +0000 -@@ -21,7 +21,7 @@ - #ifndef __COMMANDS_H__ - #define __COMMANDS_H__ - --#include <usb.h> -+#include <libusb20_compat01.h> - #include "arguments.h" - - int execute_command( struct usb_dev_handle *device, diff --git a/comms/dfu-util/files/patch-src-dfu.c b/comms/dfu-util/files/patch-src-dfu.c deleted file mode 100644 index 03fd922339e7..000000000000 --- a/comms/dfu-util/files/patch-src-dfu.c +++ /dev/null @@ -1,11 +0,0 @@ ---- src/dfu.c.orig 2007-02-25 15:43:05.000000000 +0000 -+++ src/dfu.c 2009-02-04 22:05:08.000000000 +0000 -@@ -19,7 +19,7 @@ - */ - - #include <stdio.h> --#include <usb.h> -+#include <libusb20_compat01.h> - #include "dfu.h" - - /* DFU commands */ diff --git a/comms/dfu-util/files/patch-src-dfu.h b/comms/dfu-util/files/patch-src-dfu.h deleted file mode 100644 index d7e08a0b911c..000000000000 --- a/comms/dfu-util/files/patch-src-dfu.h +++ /dev/null @@ -1,11 +0,0 @@ ---- src/dfu.h.orig 2007-02-25 15:43:05.000000000 +0000 -+++ src/dfu.h 2009-02-04 22:05:15.000000000 +0000 -@@ -21,7 +21,7 @@ - #ifndef __DFU_H__ - #define __DFU_H__ - --#include <usb.h> -+#include <libusb20_compat01.h> - #include "usb_dfu.h" - - /* DFU states */ diff --git a/comms/dfu-util/files/patch-src-main.c b/comms/dfu-util/files/patch-src-main.c deleted file mode 100644 index 5a09bb0f48b0..000000000000 --- a/comms/dfu-util/files/patch-src-main.c +++ /dev/null @@ -1,11 +0,0 @@ ---- src/main.c 2009-02-09 01:50:55.118776000 +0000 -+++ src/main.c 2009-02-12 21:15:13.000000000 +0000 -@@ -26,7 +26,7 @@ - #include <unistd.h> - #include <string.h> - #include <getopt.h> --#include <usb.h> -+#include <libusb20_compat01.h> - #include <errno.h> - - #include "dfu.h" diff --git a/comms/dfu-util/files/patch-src-sam7dfu.c b/comms/dfu-util/files/patch-src-sam7dfu.c deleted file mode 100644 index 85227047092f..000000000000 --- a/comms/dfu-util/files/patch-src-sam7dfu.c +++ /dev/null @@ -1,11 +0,0 @@ ---- src/sam7dfu.c 2009-02-09 01:50:55.118776000 +0000 -+++ src/sam7dfu.c 2009-02-12 21:15:27.000000000 +0000 -@@ -12,7 +12,7 @@ - #include <fcntl.h> - #include <errno.h> - #include <string.h> --#include <usb.h> -+#include <libusb20_compat01.h> - - #include "config.h" - #include "dfu.h" diff --git a/comms/gnocky/Makefile b/comms/gnocky/Makefile index 220a4640f152..bc28bff3b0b4 100644 --- a/comms/gnocky/Makefile +++ b/comms/gnocky/Makefile @@ -14,8 +14,7 @@ MASTER_SITES= http://www.gnokii.org/download/gnocky/ MAINTAINER= danfe@FreeBSD.org COMMENT= A graphical (GTK+2) frontend for gnokii -LIB_DEPENDS= gnokii.4:${PORTSDIR}/comms/gnokii \ - usb-0.1.8:${PORTSDIR}/devel/libusb +LIB_DEPENDS= gnokii.4:${PORTSDIR}/comms/gnokii USE_GNOME= gtk20 libglade2 GNU_CONFIGURE= yes diff --git a/comms/gnokii/Makefile b/comms/gnokii/Makefile index cde2a72811e3..d90c15ee44c1 100644 --- a/comms/gnokii/Makefile +++ b/comms/gnokii/Makefile @@ -55,8 +55,10 @@ OPTIONS= ICAL "Build with IETF iCal support" off \ LIB_DEPENDS+= ical.42:${PORTSDIR}/devel/libical .endif -.if exists(${LOCALBASE}/lib/libusb.so) || defined(WITH_USB) +.if ${OSVERSION} < 800069 +. if exists(${LOCALBASE}/lib/libusb.so) || defined(WITH_USB) LIB_DEPENDS+= usb-0.1.8:${PORTSDIR}/devel/libusb +. endif .endif .if exists(${LOCALBASE}/lib/libpcsclite.so) || defined(WITH_PCSC) diff --git a/comms/gnuradio/Makefile b/comms/gnuradio/Makefile index 8243f8296f80..3eb4e0ff50f0 100644 --- a/comms/gnuradio/Makefile +++ b/comms/gnuradio/Makefile @@ -23,7 +23,6 @@ BUILD_DEPENDS= sdcc:${PORTSDIR}/lang/sdcc \ guile:${PORTSDIR}/lang/guile LIB_DEPENDS= fftw3:${PORTSDIR}/math/fftw3 \ fftw3f:${PORTSDIR}/math/fftw3-float \ - usb:${PORTSDIR}/devel/libusb \ boost_python:${PORTSDIR}/devel/boost-python RUN_DEPENDS= ${PYNUMPY} \ ${PYTHON_SITELIBDIR}/ephem/__init__.py:${PORTSDIR}/astro/pyephem @@ -50,6 +49,12 @@ CONFIGURE_ARGS= --with-boost-include-dir="${LOCALBASE}/include/" \ --disable-html-docs \ --disable-latex-docs +.include <bsd.port.pre.mk> + +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb:${PORTSDIR}/devel/libusb +.endif + post-patch: @${REINPLACE_CMD} -e 's|2.61|2.62|g' ${WRKSRC}/aclocal.m4 @${FIND} ${WRKSRC} -type f -name "Makefile.in" | ${XARGS} \ @@ -80,4 +85,4 @@ post-install: @${ECHO} without the .sample suffix and edited as needed before use. @${ECHO} -.include <bsd.port.mk> +.include <bsd.port.post.mk> diff --git a/comms/libticables/Makefile b/comms/libticables/Makefile index a1805e1b1ae1..78a40cb6c708 100644 --- a/comms/libticables/Makefile +++ b/comms/libticables/Makefile @@ -15,8 +15,6 @@ MASTER_SITE_SUBDIR= tilp MAINTAINER= tijl@ulyssis.org COMMENT= TI calculator link cables library -LIB_DEPENDS= usb-0.1.8:${PORTSDIR}/devel/libusb - CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include" LDFLAGS="-L${LOCALBASE}/lib" USE_GETTEXT= yes USE_GNOME= gnomehack pkgconfig @@ -24,4 +22,12 @@ USE_AUTOTOOLS= libtool:15 USE_GMAKE= yes USE_LDCONFIG= yes -.include <bsd.port.mk> +.include <bsd.port.pre.mk> + +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb:${PORTSDIR}/devel/libusb +.else +EXTRA_PATCHES= ${FILESDIR}/extra-patch-configure +.endif + +.include <bsd.port.post.mk> diff --git a/comms/libticables/files/extra-patch-configure b/comms/libticables/files/extra-patch-configure new file mode 100644 index 000000000000..7b30c348af12 --- /dev/null +++ b/comms/libticables/files/extra-patch-configure @@ -0,0 +1,26 @@ +--- configure.orig 2009-03-07 19:05:24.000000000 +0300 ++++ configure 2009-03-07 19:06:25.000000000 +0300 +@@ -26925,21 +26925,13 @@ + echo "${ECHO_T}no" >&6 + fi + +-if test x$LIBUSB_CONFIG = xyes; then +- LIBUSB_CFLAGS=`libusb-config --cflags` +- LIBUSB_LIBS=`libusb-config --libs` ++ LIBUSB_CFLAGS="" ++ LIBUSB_LIBS="-lusb" + + cat >>confdefs.h <<\_ACEOF + #define HAVE_LIBUSB 1 + _ACEOF + +-else +- LIBUSB_CFLAGS= +- LIBUSB_LIBS= +-fi +- +- +- + # Checks for header files. + + diff --git a/comms/openobex/Makefile b/comms/openobex/Makefile index 790d2a2ef3e6..9bfb750c1f05 100644 --- a/comms/openobex/Makefile +++ b/comms/openobex/Makefile @@ -24,9 +24,13 @@ OPTIONS= LIBUSB "Enable OBEX over USB" no .include <bsd.port.pre.mk> .if defined(WITH_LIBUSB) +. if ${OSVERSION} < 800069 LIB_DEPENDS+= usb-0.1.8:${PORTSDIR}/devel/libusb -CONFIGURE_ARGS+=--enable-usb CFLAGS+= -I${PREFIX}/include +. else +EXTRA_PATCHES= ${FILESDIR}/extra-patch-configure +. endif +CONFIGURE_ARGS+=--enable-usb .else CONFIGURE_ARGS+=--disable-usb .endif diff --git a/comms/openobex/files/extra-patch-configure b/comms/openobex/files/extra-patch-configure new file mode 100644 index 000000000000..01099804dc96 --- /dev/null +++ b/comms/openobex/files/extra-patch-configure @@ -0,0 +1,14 @@ +--- configure.orig 2009-03-07 19:35:55.000000000 +0300 ++++ configure 2009-03-07 19:36:21.000000000 +0300 +@@ -10736,6 +10736,11 @@ + USB_LIBS="-lusb" + usb_lib_found=yes + ;; ++ *-*-freebsd*) ++ USB_CFLAGS="" ++ USB_LIBS="-lusb" ++ usb_lib_found=yes ++ ;; + *) + + pkg_failed=no diff --git a/devel/avarice/Makefile b/devel/avarice/Makefile index 76d285807a3d..defbb5ea50df 100644 --- a/devel/avarice/Makefile +++ b/devel/avarice/Makefile @@ -16,7 +16,6 @@ COMMENT= Atmel AVR JTAG programmer and debugging interface for avr-gdb BUILD_DEPENDS= ${LOCALBASE}/lib/libbfd.a:${PORTSDIR}/devel/libbfd \ ${LOCALBASE}/lib/libiberty.a:${PORTSDIR}/devel/gnulibiberty -LIB_DEPENDS= usb-0.1.8:${PORTSDIR}/devel/libusb USE_BZIP2= yes USE_PERL5= yes @@ -26,4 +25,10 @@ CONFIGURE_ENV= CPPFLAGS=-I${LOCALBASE}/include LDFLAGS=-L${LOCALBASE}/lib MAN1= avarice.1 ice-gdb.1 ice-insight.1 -.include <bsd.port.mk> +.include <bsd.port.pre.mk> + +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb-0.1.8:${PORTSDIR}/devel/libusb +.endif + +.include <bsd.port.post.mk> diff --git a/devel/avrdude/Makefile b/devel/avrdude/Makefile index 08f4371e5b47..157d24df6af6 100644 --- a/devel/avrdude/Makefile +++ b/devel/avrdude/Makefile @@ -15,12 +15,16 @@ MASTER_SITE_SUBDIR= avrdude MAINTAINER= joerg@FreeBSD.org COMMENT= Program for programming the on-chip memory of Atmel AVR CPUs -LIB_DEPENDS= usb-0.1.8:${PORTSDIR}/devel/libusb - MAN1= avrdude.1 MANCOMPRESSED= no GNU_CONFIGURE= yes CONFIGURE_ENV= CFLAGS=-I${LOCALBASE}/include LDFLAGS=-L${LOCALBASE}/lib -.include <bsd.port.mk> +.include <bsd.port.pre.mk> + +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb-0.1.8:${PORTSDIR}/devel/libusb +.endif + +.include <bsd.port.post.mk> diff --git a/devel/libccid/Makefile b/devel/libccid/Makefile index 0f2b2455b28f..21b4ea0772a1 100644 --- a/devel/libccid/Makefile +++ b/devel/libccid/Makefile @@ -12,8 +12,7 @@ MASTER_SITES= http://alioth.debian.org/frs/download.php/2656/ MAINTAINER= arved@FreeBSD.org COMMENT= Generic USB CCID (Chip/Smart Card Interface Devices) driver -LIB_DEPENDS= usb-0.1.8:${PORTSDIR}/devel/libusb \ - pcsclite.1:${PORTSDIR}/devel/pcsc-lite +LIB_DEPENDS= pcsclite.1:${PORTSDIR}/devel/pcsc-lite USE_BZIP2= yes GNU_CONFIGURE= yes @@ -32,6 +31,10 @@ MAN8= Kobil_mIDentity_switch.8 .include <bsd.port.pre.mk> +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb-0.1.8:${PORTSDIR}/devel/libusb +.endif + post-patch: ${REINPLACE_CMD} -e "s,use warnings;,," ${WRKSRC}/src/create_Info_plist.pl ${REINPLACE_CMD} -e "s,ndef __APPLE__, !(__APPLE__ || __FreeBSD__)," ${WRKSRC}/contrib/Kobil_mIDentity_switch/Kobil_mIDentity_switch.c diff --git a/devel/libccid/files/patch-src_ccid_usb.c b/devel/libccid/files/patch-src_ccid_usb.c new file mode 100644 index 000000000000..58e515f48f8f --- /dev/null +++ b/devel/libccid/files/patch-src_ccid_usb.c @@ -0,0 +1,11 @@ +--- src/ccid_usb.c.orig 2009-03-07 20:05:04.000000000 +0300 ++++ src/ccid_usb.c 2009-03-07 20:09:14.000000000 +0300 +@@ -56,6 +56,8 @@ + + #define BUS_DEVICE_STRSIZE 32 + ++EXTERNAL struct usb_interface * get_ccid_usb_interface(struct usb_device *dev); ++ + typedef struct + { + usb_dev_handle *handle; diff --git a/devel/libccid/files/patch-src_parse.c b/devel/libccid/files/patch-src_parse.c new file mode 100644 index 000000000000..76ec2e613f89 --- /dev/null +++ b/devel/libccid/files/patch-src_parse.c @@ -0,0 +1,10 @@ +--- src/parse.c.orig 2009-03-07 20:07:07.000000000 +0300 ++++ src/parse.c 2009-03-07 20:09:07.000000000 +0300 +@@ -46,6 +46,7 @@ + + static int ccid_parse_interface_descriptor(usb_dev_handle *handle, + struct usb_device *dev); ++struct usb_interface * get_ccid_usb_interface(struct usb_device *dev); + + + /***************************************************************************** diff --git a/devel/libftdi/Makefile b/devel/libftdi/Makefile index 3ce3cd6edbcb..76f9b4d0fe3f 100644 --- a/devel/libftdi/Makefile +++ b/devel/libftdi/Makefile @@ -13,8 +13,6 @@ MASTER_SITES= http://www.intra2net.com/de/produkte/opensource/ftdi/TGZ/ MAINTAINER= o.davydenko@gmail.com COMMENT= A library (using libusb) to talk to FTDI chips -LIB_DEPENDS= usb-0.1:${PORTSDIR}/devel/libusb - USE_AUTOTOOLS= libtool:15 GNU_CONFIGURE= yes CONFIGURE_ENV= CFLAGS="${CFLAGS} -I${LOCALBASE}/include" @@ -23,10 +21,24 @@ USE_GNOME= pkgconfig gnomehack PORTDOCS= COPYING.LIB ChangeLog README +.include <bsd.port.pre.mk> + +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb-0.1:${PORTSDIR}/devel/libusb +.else +EXTRA_PATCHES= ${FILESDIR}/extra-patch-configure.in +USE_AUTOTOOLS+= autoconf:262 +.endif + +post-patch: +.if ${OSVERSION} >= 800069 + ${RM} -f ${WRKSRC}/configure +.endif + post-install: .if !defined(NOPORTDOCS) ${MKDIR} ${DOCSDIR} ${INSTALL_DATA} ${PORTDOCS:S,^,${WRKSRC}/,} ${DOCSDIR} .endif -.include <bsd.port.mk> +.include <bsd.port.post.mk> diff --git a/devel/libftdi/files/extra-patch-configure.in b/devel/libftdi/files/extra-patch-configure.in new file mode 100644 index 000000000000..d3a8a6f6635c --- /dev/null +++ b/devel/libftdi/files/extra-patch-configure.in @@ -0,0 +1,34 @@ +--- configure.in.orig 2009-03-07 20:14:41.000000000 +0300 ++++ configure.in 2009-03-07 20:15:29.000000000 +0300 +@@ -7,30 +7,7 @@ + AC_PROG_CC + AM_PROG_LIBTOOL + +-dnl check for libusb-config +-AC_PATH_PROG(HAVELIBUSB, libusb-config, $PATH) +- +-if test ! -z "$HAVELIBUSB"; then +- LIBUSB_CFLAGS=`$HAVELIBUSB --cflags` +- LIBUSB_LIBS=`$HAVELIBUSB --libs` +- +- CFLAGS="$CFLAGS $LIBUSB_CFLAGS" +- LIBS="$LIBS $LIBUSB_LIBS" +-else +- AC_MSG_ERROR([*** libusb-config not found. You need a working libusb installation.]) +-fi +- +-dnl check for version of libusb +-AC_MSG_CHECKING([if libusb version is >= 0.1.7]) +-libusb_version_needed="1007" +-libusb_version=`$HAVELIBUSB --version | sed -e "s/libusb //" | awk 'BEGIN { FS = "."; } { printf "%d", ($''1 * 1000 + $''2) * 1000 + $''3;}'` +- +-if test $libusb_version -lt $libusb_version_needed; then +- AC_MSG_RESULT(no) +- AC_MSG_ERROR([*** libusb is too old ($libusb_version). You need a libusb installation newer or equal to 0.1.7.]) +-else +- AC_MSG_RESULT(yes) +-fi ++LIBS="$LIBS -lusb" + + ENABLE_ASYNC_MODE=0 + AC_ARG_WITH(async-mode, diff --git a/devel/libftdi/files/patch-examples_find_all.c b/devel/libftdi/files/patch-examples_find_all.c new file mode 100644 index 000000000000..f4a15772d49e --- /dev/null +++ b/devel/libftdi/files/patch-examples_find_all.c @@ -0,0 +1,10 @@ +--- examples/find_all.c.orig 2009-03-07 20:18:06.000000000 +0300 ++++ examples/find_all.c 2009-03-07 20:18:52.000000000 +0300 +@@ -6,6 +6,7 @@ + */ + + #include <stdio.h> ++#include <stdlib.h> + #include <ftdi.h> + + int main(int argc, char **argv) diff --git a/devel/libftdi/files/patch-examples_simple.c b/devel/libftdi/files/patch-examples_simple.c new file mode 100644 index 000000000000..8aaf9e4a075e --- /dev/null +++ b/devel/libftdi/files/patch-examples_simple.c @@ -0,0 +1,10 @@ +--- examples/simple.c.orig 2009-03-07 20:12:44.000000000 +0300 ++++ examples/simple.c 2009-03-07 20:14:10.000000000 +0300 +@@ -6,6 +6,7 @@ + */ + + #include <stdio.h> ++#include <stdlib.h> + #include <ftdi.h> + + int main(int argc, char **argv) diff --git a/devel/libgamepad/Makefile b/devel/libgamepad/Makefile index d935f197c4fc..9342adec1781 100644 --- a/devel/libgamepad/Makefile +++ b/devel/libgamepad/Makefile @@ -19,4 +19,10 @@ pre-build: MAN3= libgamepad.3 -.include <bsd.port.mk> +.include <bsd.port.pre.mk> + +.if ${OSVERSION} >= 800069 +EXTRA_PATCHES= ${FILESDIR}/extra-patch-gamepad_usbhid.c +.endif + +.include <bsd.port.post.mk> diff --git a/devel/libgamepad/files/extra-patch-gamepad_usbhid.c b/devel/libgamepad/files/extra-patch-gamepad_usbhid.c new file mode 100644 index 000000000000..57de0a000c15 --- /dev/null +++ b/devel/libgamepad/files/extra-patch-gamepad_usbhid.c @@ -0,0 +1,10 @@ +--- gamepad_usbhid.c.orig 2009-03-08 12:35:35.000000000 +0300 ++++ gamepad_usbhid.c 2009-03-08 12:35:44.000000000 +0300 +@@ -3,6 +3,7 @@ + #include <string.h> + #include <sys/ioctl.h> + #include <dev/usb/usb.h> ++#include <dev/usb/usb_ioctl.h> + #include <errno.h> + #include <fcntl.h> + #include <unistd.h> diff --git a/devel/libhid/Makefile b/devel/libhid/Makefile index 43568e1d1d7f..e9b915dca0ef 100644 --- a/devel/libhid/Makefile +++ b/devel/libhid/Makefile @@ -20,7 +20,6 @@ USE_LDCONFIG= yes USE_GMAKE= yes USE_PYTHON= yes -LIB_DEPENDS+= usb-0.1.8:${PORTSDIR}/devel/libusb BUILD_DEPENDS+= ${LOCALBASE}/bin/xsltproc:${PORTSDIR}/textproc/libxslt \ ${LOCALBASE}/share/xsl/docbook/html:${PORTSDIR}/textproc/docbook-xsl \ ${LOCALBASE}/bin/swig1.3:${PORTSDIR}/devel/swig13 @@ -28,4 +27,12 @@ BUILD_DEPENDS+= ${LOCALBASE}/bin/xsltproc:${PORTSDIR}/textproc/libxslt \ HAS_CONFIGURE= yes CONFIGURE_ARGS+= --mandir=${MANPREFIX}/man --without-doxygen -.include <bsd.port.mk> +.include <bsd.port.pre.mk> + +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb-0.1.8:${PORTSDIR}/devel/libusb +.else +EXTRA_PATCHES= ${FILESDIR}/extra-patch-usb +.endif + +.include <bsd.port.post.mk> diff --git a/devel/libhid/files/extra-patch-usb b/devel/libhid/files/extra-patch-usb new file mode 100644 index 000000000000..af78de7e0e45 --- /dev/null +++ b/devel/libhid/files/extra-patch-usb @@ -0,0 +1,12 @@ +--- configure.orig 2007-04-26 04:25:25.000000000 +0400 ++++ configure 2009-03-07 20:26:02.000000000 +0300 +@@ -4846,8 +4846,8 @@ + done + + +- LIBUSB_CFLAGS="`libusb-config --cflags`" +- LIBUSB_LIBS="`libusb-config --libs`" ++ LIBUSB_CFLAGS="" ++ LIBUSB_LIBS="-lusb" + + diff --git a/devel/libhid/files/patch-src_hid_initialisation.c b/devel/libhid/files/patch-src_hid_initialisation.c new file mode 100644 index 000000000000..014adf4987dd --- /dev/null +++ b/devel/libhid/files/patch-src_hid_initialisation.c @@ -0,0 +1,10 @@ +--- src/hid_initialisation.c.orig 2009-03-07 20:27:43.000000000 +0300 ++++ src/hid_initialisation.c 2009-03-07 20:29:25.000000000 +0300 +@@ -4,6 +4,7 @@ + #define HID_INTERNAL + + #include "config.h" ++#include <stdlib.h> + #include <hid.h> + #include <hid_helpers.h> + diff --git a/devel/libhid/files/patch-src_hid_opening.c b/devel/libhid/files/patch-src_hid_opening.c new file mode 100644 index 000000000000..19b080d901ee --- /dev/null +++ b/devel/libhid/files/patch-src_hid_opening.c @@ -0,0 +1,9 @@ +--- src/hid_opening.c.orig 2009-03-07 20:28:09.000000000 +0300 ++++ src/hid_opening.c 2009-03-07 20:29:17.000000000 +0300 +@@ -1,5 +1,6 @@ + #define HID_INTERNAL + ++#include <stdlib.h> + #include <hid.h> + #include <hid_helpers.h> + #include <os.h> diff --git a/devel/libhid/files/patch-src_hid_parsing.c b/devel/libhid/files/patch-src_hid_parsing.c new file mode 100644 index 000000000000..3eccd4b712e1 --- /dev/null +++ b/devel/libhid/files/patch-src_hid_parsing.c @@ -0,0 +1,9 @@ +--- src/hid_parsing.c.orig 2009-03-07 20:29:35.000000000 +0300 ++++ src/hid_parsing.c 2009-03-07 20:29:43.000000000 +0300 +@@ -1,5 +1,6 @@ + #define HID_INTERNAL + ++#include <stdlib.h> + #include <hid.h> + #include <hid_helpers.h> + diff --git a/devel/libhid/files/patch-test_lshid.c b/devel/libhid/files/patch-test_lshid.c new file mode 100644 index 000000000000..2b107ca7b9a1 --- /dev/null +++ b/devel/libhid/files/patch-test_lshid.c @@ -0,0 +1,10 @@ +--- test/lshid.c.orig 2009-03-07 20:30:14.000000000 +0300 ++++ test/lshid.c 2009-03-07 20:30:20.000000000 +0300 +@@ -23,6 +23,7 @@ + + #include <hid.h> + #include <stdio.h> ++#include <stdlib.h> + #include <string.h> + + char *hid_id[32]; /* FIXME: 32 devices MAX */ diff --git a/devel/libhid/files/patch-test_test_libhid.c b/devel/libhid/files/patch-test_test_libhid.c new file mode 100644 index 000000000000..dbb18830a719 --- /dev/null +++ b/devel/libhid/files/patch-test_test_libhid.c @@ -0,0 +1,9 @@ +--- test/test_libhid.c.orig 2009-03-07 20:29:59.000000000 +0300 ++++ test/test_libhid.c 2009-03-07 20:30:05.000000000 +0300 +@@ -1,5 +1,6 @@ + #include <hid.h> + #include <stdio.h> ++#include <stdlib.h> + #include <string.h> + + bool match_serial_number(struct usb_dev_handle* usbdev, void* custom, unsigned int len) diff --git a/devel/libnxt/Makefile b/devel/libnxt/Makefile index 72f977d39857..216e33d9acf4 100644 --- a/devel/libnxt/Makefile +++ b/devel/libnxt/Makefile @@ -14,13 +14,18 @@ MASTER_SITES= ${MASTER_SITE_GOOGLE_CODE} \ MAINTAINER= bacon@smithers.neuro.mcw.edu COMMENT= Lego NXT library -LIB_DEPENDS= usb-0.1.8:${PORTSDIR}/devel/libusb BUILD_DEPENDS= scons:${PORTSDIR}/devel/scons \ python:${PORTSDIR}/lang/python SUB_FILES= pkg-message USE_LDCONFIG= yes +.include <bsd.port.pre.mk> + +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb-0.1.8:${PORTSDIR}/devel/libusb +.endif + do-build: (cd ${WRKSRC}; scons) @@ -37,4 +42,4 @@ do-install: post-install: @${CAT} ${WRKDIR}/pkg-message -.include <bsd.port.mk> +.include <bsd.port.post.mk> diff --git a/devel/libusb/Makefile b/devel/libusb/Makefile index dedc0dfb72e1..fef64e7d2fb4 100644 --- a/devel/libusb/Makefile +++ b/devel/libusb/Makefile @@ -19,6 +19,10 @@ OPTIONS= SGML "Install developer guide from SGML" off .include <bsd.port.pre.mk> +.if ${OSVERSION} >= 800069 +IGNORE= has been already included into base system +.endif + .if defined(WITH_SGML) BUILD_DEPENDS+= ${LOCALBASE}/share/sgml/jade/catalog:${PORTSDIR}/textproc/jade \ ${LOCALBASE}/share/sgml/docbook/dsssl/modular/catalog:${PORTSDIR}/textproc/dsssl-docbook-modular \ diff --git a/devel/p5-Device-USB/Makefile b/devel/p5-Device-USB/Makefile index 739116a227fa..085052a259b8 100644 --- a/devel/p5-Device-USB/Makefile +++ b/devel/p5-Device-USB/Makefile @@ -17,7 +17,6 @@ MAINTAINER= jwbacon@tds.net COMMENT= Perl wrapper for libusb BUILD_DEPENDS= ${SITE_PERL}/Inline.pm:${PORTSDIR}/devel/p5-Inline -LIB_DEPENDS= usb-0.1.8:${PORTSDIR}/devel/libusb WRKSRC= ${WRKDIR}/Device-USB-0.21 PERL_CONFIGURE= yes @@ -31,4 +30,10 @@ MAN3= Device::USB.3 \ Device::USB::FAQ.3 \ Device::dump_usb.3 -.include <bsd.port.mk> +.include <bsd.port.pre.mk> + +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb-0.1.8:${PORTSDIR}/devel/libusb +.endif + +.include <bsd.port.post.mk> diff --git a/devel/p5-usb/Makefile b/devel/p5-usb/Makefile index 739116a227fa..085052a259b8 100644 --- a/devel/p5-usb/Makefile +++ b/devel/p5-usb/Makefile @@ -17,7 +17,6 @@ MAINTAINER= jwbacon@tds.net COMMENT= Perl wrapper for libusb BUILD_DEPENDS= ${SITE_PERL}/Inline.pm:${PORTSDIR}/devel/p5-Inline -LIB_DEPENDS= usb-0.1.8:${PORTSDIR}/devel/libusb WRKSRC= ${WRKDIR}/Device-USB-0.21 PERL_CONFIGURE= yes @@ -31,4 +30,10 @@ MAN3= Device::USB.3 \ Device::USB::FAQ.3 \ Device::dump_usb.3 -.include <bsd.port.mk> +.include <bsd.port.pre.mk> + +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb-0.1.8:${PORTSDIR}/devel/libusb +.endif + +.include <bsd.port.post.mk> diff --git a/devel/pcsc-lite/Makefile b/devel/pcsc-lite/Makefile index a3f548df0cef..325002415630 100644 --- a/devel/pcsc-lite/Makefile +++ b/devel/pcsc-lite/Makefile @@ -38,8 +38,14 @@ MAN5= reader.conf.5 MAN8= pcscd.8 update-reader.conf.8 .if !defined(WITHOUT_USB) +. if ${OSVERSION} < 800069 LIB_DEPENDS+= usb-0.1.8:${PORTSDIR}/devel/libusb -CONFIGURE_ARGS+=--enable-libusb=${LOCALBASE} \ +USBBASE= ${LOCALBASE} +. else +USBBASE= /usr +CONFIGURE_ENV+= LIBUSB_LIBS="-lusb" +. endif +CONFIGURE_ARGS+=--enable-libusb=${USBBASE} \ --disable-libhal .else LIB_DEPENDS+= hal.1:${PORTSDIR}/sysutils/hal diff --git a/devel/piklab/Makefile b/devel/piklab/Makefile index 9cc48f92f066..ceb47d490fe6 100644 --- a/devel/piklab/Makefile +++ b/devel/piklab/Makefile @@ -15,8 +15,6 @@ MASTER_SITE_SUBDIR=piklab MAINTAINER= bms@FreeBSD.org COMMENT= KDE IDE for microcontroller development -LIB_DEPENDS= usb:${PORTSDIR}/devel/libusb - USE_AUTOTOOLS= libtool:15 GNU_CONFIGURE= yes USE_BZIP2= yes @@ -31,4 +29,10 @@ MAN1= piklab-hex.1 piklab-prog.1 piklab.1x BROKEN= Does not compile on sparc64 .endif +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb:${PORTSDIR}/devel/libusb +. else +CONFIGURE_ENV+= LIBUSB_LIBS="-lusb" +.endif + .include <bsd.port.post.mk> diff --git a/devel/py-usb/Makefile b/devel/py-usb/Makefile index 6b0925f5eaba..bc867a8b425a 100644 --- a/devel/py-usb/Makefile +++ b/devel/py-usb/Makefile @@ -16,11 +16,16 @@ PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} MAINTAINER= R.Mahmatkhanov@SKYLINK.ru COMMENT= Python wrapper around libusb -BUILD_DEPENDS= ${LOCALBASE}/lib/libusb.so:${PORTSDIR}/devel/libusb RUN_DEPENDS= ${BUILD_DEPENDS} USE_PYTHON= yes USE_PYDISTUTILS= yes PLIST_FILES= %%PYTHON_SITELIBDIR%%/usb.so -.include <bsd.port.mk> +.include <bsd.port.pre.mk> + +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= ${LOCALBASE}/lib/libusb.so:${PORTSDIR}/devel/libusb +.endif + +.include <bsd.port.post.mk> diff --git a/devel/roboctl/Makefile b/devel/roboctl/Makefile index cf65cc08653b..5cb3cfe947db 100644 --- a/devel/roboctl/Makefile +++ b/devel/roboctl/Makefile @@ -14,7 +14,6 @@ MASTER_SITES= http://personalpages.tds.net/~jwbacon/Ports/distfiles/ \ MAINTAINER= jwbacon@tds.net COMMENT= API for communications with Lego and Vex robot controllers -LIB_DEPENDS= usb-0.1:${PORTSDIR}/devel/libusb BUILD_DEPENDS= ${LOCALBASE}/lib/libgamepad.a:${PORTSDIR}/devel/libgamepad OPTIONS= CUTECOM "Install cutecom for Vex debugging" On @@ -24,10 +23,20 @@ MAN3= roboctl.3 .include <bsd.port.pre.mk> +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb-0.1:${PORTSDIR}/devel/libusb +.endif + .if defined(WITH_CUTECOM) RUN_DEPENDS+= cutecom:${PORTSDIR}/comms/cutecom .endif +post-patch: +.if ${OSVERSION} >= 800069 + @${REINPLACE_CMD} -E -e 's,/usr/local/include/usb.h,/usr/include/usb.h,g' \ + ${WRKSRC}/Libs/C/Makefile.depend +.endif + post-install: (cd ${WRKSRC}/Commands/NXTRemote; ${MAKE}) ${INSTALL_PROGRAM} ${WRKSRC}/Commands/NXTRemote/nxtremote ${PREFIX}/bin diff --git a/devel/urjtag/Makefile b/devel/urjtag/Makefile index 9ae946fa74a4..cff04993927c 100644 --- a/devel/urjtag/Makefile +++ b/devel/urjtag/Makefile @@ -39,7 +39,11 @@ CONFIGURE_ARGS+= --enable-jedec .if !defined(WITHOUT_USB) CONFIGURE_ARGS+= --with-libusb +.if ${OSVERSION} < 800069 LIB_DEPENDS+= usb:${PORTSDIR}/devel/libusb +.else +EXTRA_PATCHES= ${FILESDIR}/extra-patch-usb +. endif .endif .if !defined(WITHOUT_FTDI) diff --git a/devel/urjtag/files/extra-patch-usb b/devel/urjtag/files/extra-patch-usb new file mode 100644 index 000000000000..995df925a764 --- /dev/null +++ b/devel/urjtag/files/extra-patch-usb @@ -0,0 +1,14 @@ +--- configure.orig 2008-09-14 14:51:22.000000000 +0400 ++++ configure 2009-03-07 20:52:56.000000000 +0300 +@@ -8604,6 +8604,10 @@ + USBLIBS="-L$with_libusb/lib/gcc -lusb" + USBCLAGS="-I$with_libusb/include" + ;; ++ *-*-freebsd*) ++ USBLIBS="-lusb" ++ USBCLAGS="" ++ ;; + *) + USBLIBS="-Lwith_libusb -lusb" + USBCFLAGS="-I$with_libusb" + # check for lex/flex diff --git a/graphics/libgphoto2/Makefile b/graphics/libgphoto2/Makefile index b38512d23f2a..3e197226061b 100644 --- a/graphics/libgphoto2/Makefile +++ b/graphics/libgphoto2/Makefile @@ -39,9 +39,12 @@ PLIST_SUB+= NLS="" .if ${OSVERSION} < 800064 LIB_DEPENDS+= usb-0.1.8:${PORTSDIR}/devel/libusb -.else +.elif ${OSVERSION} < 800069 CONFIGURE_ENV+= LIBUSB_LIBS="-L/usr/lib -lusb20" LIBUSB_CFLAGS="-I/usr/include/dev/usb -I/usr/include" EXTRA_PATCHES= ${PATCHDIR}/extra-patch-usb20 +.else +CONFIGURE_ENV+= LIBUSB_LIBS="-lusb" LIBUSB_CFLAGS="-I/usr/include" +EXTRA_PATCHES= ${PATCHDIR}/extra-patch-usb20 .endif post-patch: diff --git a/graphics/lprof-devel/Makefile b/graphics/lprof-devel/Makefile index 058c66f7dc59..fba3ab1d1e5d 100644 --- a/graphics/lprof-devel/Makefile +++ b/graphics/lprof-devel/Makefile @@ -19,8 +19,7 @@ COMMENT= Open source color profiler LIB_DEPENDS= lcms.1:${PORTSDIR}/graphics/lcms \ jpeg.9:${PORTSDIR}/graphics/jpeg \ tiff.4:${PORTSDIR}/graphics/tiff \ - vigraimpex.2:${PORTSDIR}/graphics/vigra \ - usb-0.1.8:${PORTSDIR}/devel/libusb + vigraimpex.2:${PORTSDIR}/graphics/vigra USE_BZIP2= yes USE_XORG= x11 xext sm ice xxf86vm @@ -33,6 +32,12 @@ CMAKE_USE_PTHREAD= yes WRKSRC= ${WRKDIR}/${PORTNAME} +.include <bsd.port.pre.mk> + +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb-0.1.8:${PORTSDIR}/devel/libusb +.endif + post-patch: @${REINPLACE_CMD} -e '/asm\/types.h/ d' ${WRKSRC}/src/argyll/spectro/hidio.c @${REINPLACE_CMD} -e '/DESTINATION/ s|data/|share/${PORTNAME}/data/|' \ @@ -41,4 +46,4 @@ post-patch: post-install: ${INSTALL_DATA} ${WRKSRC}/data/icons/lprof.png ${PREFIX}/share/pixmaps -.include <bsd.port.mk> +.include <bsd.port.post.mk> diff --git a/graphics/lprof-devel/files/patch-src-argyll-spectro-unixio.c b/graphics/lprof-devel/files/patch-src-argyll-spectro-unixio.c index e3b36a617da4..0561d219f1ea 100644 --- a/graphics/lprof-devel/files/patch-src-argyll-spectro-unixio.c +++ b/graphics/lprof-devel/files/patch-src-argyll-spectro-unixio.c @@ -1,6 +1,14 @@ --- src/argyll/spectro/unixio.c.orig 2008-02-20 00:02:24.000000000 +0300 -+++ src/argyll/spectro/unixio.c 2008-08-03 21:47:17.000000000 +0400 -@@ -585,9 +585,8 @@ ++++ src/argyll/spectro/unixio.c 2009-03-07 21:19:48.000000000 +0300 +@@ -35,6 +35,7 @@ + #include "insttypes.h" + #include "icoms.h" + #include "usbio.h" ++#include <dirent.h> + + #undef DEBUG + +@@ -585,9 +586,8 @@ break; if (!( diff --git a/graphics/lprof-devel/files/patch-src_argyll_spectro_usbio.c b/graphics/lprof-devel/files/patch-src_argyll_spectro_usbio.c new file mode 100644 index 000000000000..9ee392c2e375 --- /dev/null +++ b/graphics/lprof-devel/files/patch-src_argyll_spectro_usbio.c @@ -0,0 +1,10 @@ +--- src/argyll/spectro/usbio.c.orig 2009-03-07 21:18:13.000000000 +0300 ++++ src/argyll/spectro/usbio.c 2009-03-07 21:18:41.000000000 +0300 +@@ -20,6 +20,7 @@ + + #include <stdio.h> + #include <stdlib.h> ++#include <unistd.h> + #include <time.h> + #include <signal.h> + #if defined(UNIX) diff --git a/graphics/s10sh/Makefile b/graphics/s10sh/Makefile index 3aed416d77d7..0ea05615bb5a 100644 --- a/graphics/s10sh/Makefile +++ b/graphics/s10sh/Makefile @@ -14,12 +14,6 @@ MASTER_SITES= http://www.reynoldsnet.org/s10sh/ \ MAINTAINER= ports@FreeBSD.org COMMENT= USB/serial userspace driver for the Canon PowerShot digital cameras -.if defined(NOUSB) || defined(WITHOUT_USB) -MAKE_ENV+= WITHOUT_USB=YES -.else -LIB_DEPENDS= usb-0.1.8:${PORTSDIR}/devel/libusb -.endif - # Don't extract the libusb bundled with s10sh: EXTRACT_AFTER_ARGS= | ${TAR} -xf - --exclude '*/libusb*' @@ -27,6 +21,14 @@ MAKEFILE= ${FILESDIR}/Makefile.bsd .include <bsd.port.pre.mk> +.if defined(NOUSB) || defined(WITHOUT_USB) +MAKE_ENV+= WITHOUT_USB=YES +.else +. if ${OSVERSION} < 800069 +LIB_DEPENDS= usb-0.1.8:${PORTSDIR}/devel/libusb +. endif +.endif + .if !defined(NOPORTDOCS) post-install: @${MKDIR} ${DOCSDIR} diff --git a/graphics/s10sh/files/Makefile.bsd b/graphics/s10sh/files/Makefile.bsd index d9b2f58516e2..8abbf4eb98b8 100644 --- a/graphics/s10sh/files/Makefile.bsd +++ b/graphics/s10sh/files/Makefile.bsd @@ -7,10 +7,14 @@ LDADD += -lreadline -ltermcap CFLAGS += -DHAVE_READLINE .if !defined(WITHOUT_USB) +. if ${OSVERSION} < 800069 USBLIB != ${LOCALBASE}/bin/libusb-config --libs LDADD += ${USBLIB} USBCF != ${LOCALBASE}/bin/libusb-config --cflags CFLAGS += ${USBCF} -DHAVE_USB_SUPPORT +. else +LDADD += -lusb +. endif SRCS += usb.c .endif diff --git a/graphics/sane-backends/Makefile b/graphics/sane-backends/Makefile index 7860e1c4360f..992fa09418e3 100644 --- a/graphics/sane-backends/Makefile +++ b/graphics/sane-backends/Makefile @@ -41,6 +41,10 @@ USE_LDCONFIG= yes .include "Makefile.man" .include <bsd.port.pre.mk> +.if ${OSVERSION} >= 800069 +BROKEN= does not compile due to changes in USB stack +.endif + .if defined(WITHOUT_USB) CONFIGURE_ARGS+= --disable-libusb .else diff --git a/misc/gplink/Makefile b/misc/gplink/Makefile index 69464fd924b5..33636aeb4372 100644 --- a/misc/gplink/Makefile +++ b/misc/gplink/Makefile @@ -13,14 +13,25 @@ MASTER_SITES= http://gp2x.org/gp32/gplink/ MAINTAINER= ports@FreeBSD.org COMMENT= A GP32 USB linker tool -LIB_DEPENDS= usb-0.1.8:${PORTSDIR}/devel/libusb - USE_GMAKE= yes WRKSRC= ${WRKDIR}/${DISTNAME}/src PLIST_FILES= bin/gplink +.include <bsd.port.pre.mk> + +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb-0.1.8:${PORTSDIR}/devel/libusb +.endif + +post-patch: +.if ${OSVERSION} >= 800069 + @${REINPLACE_CMD} -E -e 's,`libusb-config --cflags`,,g' \ + -e 's,`libusb-config --libs`,-lusb,g' \ + ${WRKSRC}/Makefile +.endif + do-install: ${INSTALL_PROGRAM} ${WRKSRC}/gplink ${PREFIX}/bin -.include <bsd.port.mk> +.include <bsd.port.post.mk> diff --git a/misc/kdeedu3/Makefile b/misc/kdeedu3/Makefile index 65c648d7541d..e6e6fd471619 100644 --- a/misc/kdeedu3/Makefile +++ b/misc/kdeedu3/Makefile @@ -15,8 +15,7 @@ DIST_SUBDIR= KDE MAINTAINER?= kde@FreeBSD.org COMMENT= Collection of entertaining, educational programs for KDE -LIB_DEPENDS= usb-0.1:${PORTSDIR}/devel/libusb \ - boost_python:${PORTSDIR}/devel/boost-python +LIB_DEPENDS= boost_python:${PORTSDIR}/devel/boost-python CONFLICTS+= kwordquiz-[0-9]* kgeography-[0-9]* @@ -36,9 +35,15 @@ LDCONFIG_DIRS+= %%PREFIX%%/lib %%PREFIX%%/lib/kde3 .include "${.CURDIR}/../../x11/kde3/Makefile.kde" +.include <bsd.port.pre.mk> + +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb-0.1:${PORTSDIR}/devel/libusb +.endif + pre-configure: ${REINPLACE_CMD} \ -e 's|pylibdir in.*|pylibdir in "${LOCALBASE}/lib" \\|g' \ ${WRKSRC}/configure -.include <bsd.port.mk> +.include <bsd.port.post.mk> diff --git a/misc/kdeedu4/Makefile b/misc/kdeedu4/Makefile index 6bf34c520e14..c88d61bd3d7d 100644 --- a/misc/kdeedu4/Makefile +++ b/misc/kdeedu4/Makefile @@ -46,7 +46,13 @@ CMAKE_ARGS+= -DCMAKE_REQUIRED_INCLUDES:STRING="${LOCALBASE}/include" \ -DBOOST_PYTHON_INCLUDES="${LOCALBASE}/include;${PYTHON_INCLUDEDIR}" \ -DBOOST_PYTHON_LIBS="-L${LOCALBASE}/lib -lboost_python -l${PYTHON_VERSION}" +.include <bsd.port.pre.mk> + +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb-0.1:${PORTSDIR}/devel/libusb +.endif + post-extract: ${MKDIR} ${WRKSRC} -.include <bsd.port.mk> +.include <bsd.port.post.mk> diff --git a/net-mgmt/spectools/Makefile b/net-mgmt/spectools/Makefile index 65aca75f8e64..471acece2e93 100644 --- a/net-mgmt/spectools/Makefile +++ b/net-mgmt/spectools/Makefile @@ -15,8 +15,6 @@ DISTNAME= spectools-2007-10-R2 MAINTAINER= brix@FreeBSD.org COMMENT= Tools for the 2.4GHz Wi-Spy spectrum analyzers from MetaGeek LLC -LIB_DEPENDS= usb-0.1:${PORTSDIR}/devel/libusb - GNU_CONFIGURE= yes CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include" \ LDFLAGS="-L${LOCALBASE}/lib" @@ -34,6 +32,10 @@ IGNORE= is unsupported on systems prior to FreeBSD v602101 IGNORE= is unsupported on systems prior to FreeBSD v700027 .endif +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb-0.1:${PORTSDIR}/devel/libusb +.endif + ALL_TARGET= spectool_net spectool_raw .if defined(WITH_GTK) diff --git a/palm/barry/Makefile b/palm/barry/Makefile index f663116bc4be..66a2727f4619 100644 --- a/palm/barry/Makefile +++ b/palm/barry/Makefile @@ -13,8 +13,7 @@ MASTER_SITES= SF MAINTAINER= meitolake@gmail.com COMMENT= C++ library for interfacing with the BlackBerry Handheld -LIB_DEPENDS= usb-0.1.8:${PORTSDIR}/devel/libusb \ - boost_thread.4:${PORTSDIR}/devel/boost +LIB_DEPENDS= boost_thread.4:${PORTSDIR}/devel/boost USE_BZIP2= yes USE_LDCONFIG= yes @@ -31,6 +30,10 @@ OPTIONS= GUI "Build the GUI" On \ .include <bsd.port.pre.mk> +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb-0.1.8:${PORTSDIR}/devel/libusb +.endif + .if defined(WITH_GUI) LIB_DEPENDS+= glademm-2.4.1:${PORTSDIR}/devel/libglademm24 \ tar.0:${PORTSDIR}/devel/libtar diff --git a/palm/pilot-link/Makefile b/palm/pilot-link/Makefile index 7677efae87cc..68b306f2f799 100644 --- a/palm/pilot-link/Makefile +++ b/palm/pilot-link/Makefile @@ -39,7 +39,9 @@ CONFIGURE_ENV+= PTHREAD_LIBS="${PTHREAD_LIBS}" PTHREAD_CFLAGS="${PTHREAD_CFLAGS .endif .if defined(WITH_USB) +. if ${OSVERSION} < 800069 LIB_DEPENDS+= usb-0.1.8:${PORTSDIR}/devel/libusb +. endif CONFIGURE_ARGS+=--enable-libusb CONFIGURE_ENV+=LDFLAGS="${LDFLAGS} -L${PREFIX}/lib -lusb" diff --git a/print/hplip/Makefile b/print/hplip/Makefile index 78f07fc5d5e3..6078d44e9e0b 100644 --- a/print/hplip/Makefile +++ b/print/hplip/Makefile @@ -18,7 +18,6 @@ COMMENT= Drivers and utilities for HP Printers and All-in-One devices LIB_DEPENDS= jpeg.9:${PORTSDIR}/graphics/jpeg \ sane.1:${PORTSDIR}/graphics/sane-backends \ cups.2:${PORTSDIR}/print/cups-base \ - usb:${PORTSDIR}/devel/libusb \ netsnmp.16:${PORTSDIR}/net-mgmt/net-snmp RUN_DEPENDS= ${PYTHON_SITELIBDIR}/reportlab/__init__.py:${PORTSDIR}/print/py-reportlab2 \ @@ -54,6 +53,10 @@ PLIST_SUB+= PORTVERSION=${PORTVERSION} IJSVER=2.7.4 .include <bsd.port.pre.mk> +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb:${PORTSDIR}/devel/libusb +.endif + .if !defined(WITHOUT_GUI) || exists(${LOCALBASE}/bin/pylupdate) RUN_DEPENDS+= pylupdate:${PORTSDIR}/x11-toolkits/py-qt CONFIGURE_ARGS+= --enable-gui-build diff --git a/print/hplip3/Makefile b/print/hplip3/Makefile index 78f07fc5d5e3..6078d44e9e0b 100644 --- a/print/hplip3/Makefile +++ b/print/hplip3/Makefile @@ -18,7 +18,6 @@ COMMENT= Drivers and utilities for HP Printers and All-in-One devices LIB_DEPENDS= jpeg.9:${PORTSDIR}/graphics/jpeg \ sane.1:${PORTSDIR}/graphics/sane-backends \ cups.2:${PORTSDIR}/print/cups-base \ - usb:${PORTSDIR}/devel/libusb \ netsnmp.16:${PORTSDIR}/net-mgmt/net-snmp RUN_DEPENDS= ${PYTHON_SITELIBDIR}/reportlab/__init__.py:${PORTSDIR}/print/py-reportlab2 \ @@ -54,6 +53,10 @@ PLIST_SUB+= PORTVERSION=${PORTVERSION} IJSVER=2.7.4 .include <bsd.port.pre.mk> +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb:${PORTSDIR}/devel/libusb +.endif + .if !defined(WITHOUT_GUI) || exists(${LOCALBASE}/bin/pylupdate) RUN_DEPENDS+= pylupdate:${PORTSDIR}/x11-toolkits/py-qt CONFIGURE_ARGS+= --enable-gui-build diff --git a/security/gnupg/Makefile b/security/gnupg/Makefile index e9cd1efa63b2..58b7661b0bec 100644 --- a/security/gnupg/Makefile +++ b/security/gnupg/Makefile @@ -93,7 +93,9 @@ PLIST_SUB+= NLS="@comment " .if defined(WITH_SCDAEMON) CONFIGURE_ARGS+=--enable-scdaemon +. if ${OSVERSION} < 800069 LIB_DEPENDS+= usb-0.1:${PORTSDIR}/devel/libusb +. endif PLIST_SUB+= SCDAEMON="" .else CONFIGURE_ARGS+=--disable-scdaemon diff --git a/security/gnupg1/Makefile b/security/gnupg1/Makefile index c28c477a1e44..5b1b7f82ba3a 100644 --- a/security/gnupg1/Makefile +++ b/security/gnupg1/Makefile @@ -49,7 +49,9 @@ CONFIGURE_ARGS+= --without-libiconv-prefix .if defined(WITH_LIBUSB) CONFIGURE_ARGS+= --with-libusb=${LOCALBASE} +. if ${OSVERSION} < 800069 LIB_DEPENDS+= usb-0.1.8:${PORTSDIR}/devel/libusb +. endif .else CONFIGURE_ARGS+= --without-libusb .endif diff --git a/security/libfprint/Makefile b/security/libfprint/Makefile index ae0cbee54b81..0b80daddb5dc 100644 --- a/security/libfprint/Makefile +++ b/security/libfprint/Makefile @@ -15,8 +15,7 @@ MASTER_SITE_SUBDIR= fprint MAINTAINER= barner@FreeBSD.org COMMENT= Library for fingerprint reader devices -LIB_DEPENDS+= Magick:${PORTSDIR}/graphics/ImageMagick \ - usb:${PORTSDIR}/devel/libusb +LIB_DEPENDS+= Magick:${PORTSDIR}/graphics/ImageMagick GNU_CONFIGURE= yes USE_BZIP2= yes @@ -28,4 +27,12 @@ CONFIGURE_ENV+= CRYPTO_CFLAGS=-I${OPENSSLINC} \ CRYPTO_LIBS=-lcrypto \ CFLAGS="${CFLAGS} -DHAVE_MEMMEM" -.include <bsd.port.mk> +.include <bsd.port.pre.mk> + +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb:${PORTSDIR}/devel/libusb +.else +EXTRA_PATCHES= ${FILESDIR}/extra-patch-usb +.endif + +.include <bsd.port.post.mk> diff --git a/security/libfprint/files/extra-patch-usb b/security/libfprint/files/extra-patch-usb new file mode 100644 index 000000000000..dc14e7864090 --- /dev/null +++ b/security/libfprint/files/extra-patch-usb @@ -0,0 +1,118 @@ +--- configure.orig 2008-03-20 16:57:56.000000000 +0300 ++++ configure 2009-03-07 23:40:53.000000000 +0300 +@@ -20182,113 +20182,10 @@ + { echo "$as_me:$LINENO: checking for LIBUSB" >&5 + echo $ECHO_N "checking for LIBUSB... $ECHO_C" >&6; } + +-if test -n "$PKG_CONFIG"; then +- if test -n "$LIBUSB_CFLAGS"; then +- pkg_cv_LIBUSB_CFLAGS="$LIBUSB_CFLAGS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"\"libusb\"\"") >&5 +- ($PKG_CONFIG --exists --print-errors ""libusb"") 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_LIBUSB_CFLAGS=`$PKG_CONFIG --cflags ""libusb"" 2>/dev/null` +-else +- pkg_failed=yes +-fi +- fi +-else +- pkg_failed=untried +-fi +-if test -n "$PKG_CONFIG"; then +- if test -n "$LIBUSB_LIBS"; then +- pkg_cv_LIBUSB_LIBS="$LIBUSB_LIBS" +- else +- if test -n "$PKG_CONFIG" && \ +- { (echo "$as_me:$LINENO: \$PKG_CONFIG --exists --print-errors \"\"libusb\"\"") >&5 +- ($PKG_CONFIG --exists --print-errors ""libusb"") 2>&5 +- ac_status=$? +- echo "$as_me:$LINENO: \$? = $ac_status" >&5 +- (exit $ac_status); }; then +- pkg_cv_LIBUSB_LIBS=`$PKG_CONFIG --libs ""libusb"" 2>/dev/null` +-else +- pkg_failed=yes +-fi +- fi +-else +- pkg_failed=untried +-fi +- +- +- +-if test $pkg_failed = yes; then +- +-if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then +- _pkg_short_errors_supported=yes +-else +- _pkg_short_errors_supported=no +-fi +- if test $_pkg_short_errors_supported = yes; then +- LIBUSB_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors ""libusb""` +- else +- LIBUSB_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors ""libusb""` +- fi +- # Put the nasty error message in config.log where it belongs +- echo "$LIBUSB_PKG_ERRORS" >&5 +- +- { { echo "$as_me:$LINENO: error: Package requirements (\"libusb\") were not met: +- +-$LIBUSB_PKG_ERRORS +- +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. +- +-Alternatively, you may set the environment variables LIBUSB_CFLAGS +-and LIBUSB_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&5 +-echo "$as_me: error: Package requirements (\"libusb\") were not met: +- +-$LIBUSB_PKG_ERRORS +- +-Consider adjusting the PKG_CONFIG_PATH environment variable if you +-installed software in a non-standard prefix. +- +-Alternatively, you may set the environment variables LIBUSB_CFLAGS +-and LIBUSB_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +-" >&2;} +- { (exit 1); exit 1; }; } +-elif test $pkg_failed = untried; then +- { { echo "$as_me:$LINENO: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. +- +-Alternatively, you may set the environment variables LIBUSB_CFLAGS +-and LIBUSB_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +- +-To get pkg-config, see <http://pkg-config.freedesktop.org/>. +-See \`config.log' for more details." >&5 +-echo "$as_me: error: The pkg-config script could not be found or is too old. Make sure it +-is in your PATH or set the PKG_CONFIG environment variable to the full +-path to pkg-config. +- +-Alternatively, you may set the environment variables LIBUSB_CFLAGS +-and LIBUSB_LIBS to avoid the need to call pkg-config. +-See the pkg-config man page for more details. +- +-To get pkg-config, see <http://pkg-config.freedesktop.org/>. +-See \`config.log' for more details." >&2;} +- { (exit 1); exit 1; }; } +-else +- LIBUSB_CFLAGS=$pkg_cv_LIBUSB_CFLAGS +- LIBUSB_LIBS=$pkg_cv_LIBUSB_LIBS ++ LIBUSB_CFLAGS="" ++ LIBUSB_LIBS="-lusb" + { echo "$as_me:$LINENO: result: yes" >&5 + echo "${ECHO_T}yes" >&6; } +- : +-fi +- + + + # check for OpenSSL's libcrypto diff --git a/security/libfprint/files/patch-libfprint_data.c b/security/libfprint/files/patch-libfprint_data.c new file mode 100644 index 000000000000..9fe490c7426d --- /dev/null +++ b/security/libfprint/files/patch-libfprint_data.c @@ -0,0 +1,10 @@ +--- libfprint/data.c.orig 2009-03-07 23:42:59.000000000 +0300 ++++ libfprint/data.c 2009-03-07 23:43:09.000000000 +0300 +@@ -19,6 +19,7 @@ + + #include <config.h> + #include <errno.h> ++#include <stdlib.h> + #include <string.h> + #include <sys/types.h> + #include <sys/stat.h> diff --git a/sysutils/asusoled/Makefile b/sysutils/asusoled/Makefile index 29be8076e83d..424d22d4870d 100644 --- a/sysutils/asusoled/Makefile +++ b/sysutils/asusoled/Makefile @@ -15,7 +15,6 @@ DISTNAME= ${PORTNAME}-${PORTVERSION} MAINTAINER= jkim@FreeBSD.org COMMENT= Utility for ASUS USB OLED Display -LIB_DEPENDS= usb-0.1.8:${PORTSDIR}/devel/libusb RUN_DEPENDS= ${FONTDIR}/TTF/luxisr.ttf:${PORTSDIR}/x11-fonts/font-bh-ttf USE_SDL= image sdl ttf @@ -30,6 +29,12 @@ MAKE_ARGS+= TTF_FONT=${FONTDIR}/TTF/luxisr.ttf FONTDIR?= ${LOCALBASE}/lib/X11/fonts +.include <bsd.port.pre.mk> + +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb-0.1.8:${PORTSDIR}/devel/libusb +.endif + post-install: .if !defined(NOPORTDATA) @${MKDIR} ${DATADIR} @@ -48,4 +53,4 @@ post-install: @${CAT} ${PKGMESSAGE} @${ECHO} -.include <bsd.port.mk> +.include <bsd.port.post.mk> diff --git a/sysutils/lcdproc/Makefile b/sysutils/lcdproc/Makefile index df32408bff54..8295ca912aba 100644 --- a/sysutils/lcdproc/Makefile +++ b/sysutils/lcdproc/Makefile @@ -65,7 +65,11 @@ LCDPROC_DRIVERS=bayrad \ .include <bsd.port.pre.mk> .if defined(WITH_USB) +. if ${OSVERSION} < 800069 LIB_DEPENDS+= usb-0.1.8:${PORTSDIR}/devel/libusb +. else +CONFIGURE_ARGS+= --with-libusb-libraries=/usr +. endif CONFIGURE_ARGS+= --enable-libusb PLIST_SUB+= USB="" LCDPROC_DRIVERS+= IOWarrior diff --git a/sysutils/nut/Makefile b/sysutils/nut/Makefile index b08f0277bb44..1ab9b2aa0621 100644 --- a/sysutils/nut/Makefile +++ b/sysutils/nut/Makefile @@ -96,7 +96,11 @@ PLIST_SUB+= NUT_SERIAL="@comment " .endif .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 diff --git a/sysutils/nut/files/extra-patch-m4_nut_check_libusb.m4 b/sysutils/nut/files/extra-patch-m4_nut_check_libusb.m4 new file mode 100644 index 000000000000..d6a89d6d8198 --- /dev/null +++ b/sysutils/nut/files/extra-patch-m4_nut_check_libusb.m4 @@ -0,0 +1,31 @@ +--- m4/nut_check_libusb.m4.orig 2009-03-07 23:56:24.000000000 +0300 ++++ m4/nut_check_libusb.m4 2009-03-07 23:57:04.000000000 +0300 +@@ -17,24 +17,12 @@ + + dnl Check for libusb libs and flags + AC_MSG_CHECKING(for libusb cflags) +- CFLAGS=`libusb-config --cflags 2>/dev/null` +- if (test "$?" != "0") +- then +- AC_MSG_RESULT(not found) +- nut_have_libusb=no +- else +- AC_MSG_RESULT(${CFLAGS}) +- fi ++ CFLAGS="" ++ AC_MSG_RESULT(${CFLAGS}) + + AC_MSG_CHECKING(for libusb libs) +- LDFLAGS=`libusb-config --libs 2>/dev/null` +- if (test "$?" != "0") +- then +- AC_MSG_RESULT(not found) +- nut_have_libusb=no +- else +- AC_MSG_RESULT(${LDFLAGS}) +- fi ++ LDFLAGS="-lusb" ++ AC_MSG_RESULT(${LDFLAGS}) + + if test "${nut_have_libusb}" = "yes"; then + LIBUSB_CFLAGS="${CFLAGS}" diff --git a/sysutils/nut22/Makefile b/sysutils/nut22/Makefile index b08f0277bb44..1ab9b2aa0621 100644 --- a/sysutils/nut22/Makefile +++ b/sysutils/nut22/Makefile @@ -96,7 +96,11 @@ PLIST_SUB+= NUT_SERIAL="@comment " .endif .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 diff --git a/sysutils/nut22/files/extra-patch-m4_nut_check_libusb.m4 b/sysutils/nut22/files/extra-patch-m4_nut_check_libusb.m4 new file mode 100644 index 000000000000..d6a89d6d8198 --- /dev/null +++ b/sysutils/nut22/files/extra-patch-m4_nut_check_libusb.m4 @@ -0,0 +1,31 @@ +--- m4/nut_check_libusb.m4.orig 2009-03-07 23:56:24.000000000 +0300 ++++ m4/nut_check_libusb.m4 2009-03-07 23:57:04.000000000 +0300 +@@ -17,24 +17,12 @@ + + dnl Check for libusb libs and flags + AC_MSG_CHECKING(for libusb cflags) +- CFLAGS=`libusb-config --cflags 2>/dev/null` +- if (test "$?" != "0") +- then +- AC_MSG_RESULT(not found) +- nut_have_libusb=no +- else +- AC_MSG_RESULT(${CFLAGS}) +- fi ++ CFLAGS="" ++ AC_MSG_RESULT(${CFLAGS}) + + AC_MSG_CHECKING(for libusb libs) +- LDFLAGS=`libusb-config --libs 2>/dev/null` +- if (test "$?" != "0") +- then +- AC_MSG_RESULT(not found) +- nut_have_libusb=no +- else +- AC_MSG_RESULT(${LDFLAGS}) +- fi ++ LDFLAGS="-lusb" ++ AC_MSG_RESULT(${LDFLAGS}) + + if test "${nut_have_libusb}" = "yes"; then + LIBUSB_CFLAGS="${CFLAGS}" diff --git a/sysutils/scanbuttond/Makefile b/sysutils/scanbuttond/Makefile index 8e773c233eac..960785bf580e 100644 --- a/sysutils/scanbuttond/Makefile +++ b/sysutils/scanbuttond/Makefile @@ -14,8 +14,6 @@ MASTER_SITE_SUBDIR= ${PORTNAME} MAINTAINER= dthiele@gmx.net COMMENT= A daemon to monitor and configure modern scanner's buttons -LIB_DEPENDS= usb-0.1.8:${PORTSDIR}/devel/libusb - GNU_CONFIGURE= yes CONFIGURE_ENV= CFLAGS="-I${LOCALBASE}/include" \ LDFLAGS="-L${LOCALBASE}/lib" @@ -23,10 +21,16 @@ USE_LDCONFIG= yes SUB_FILES+= pkg-message +.include <bsd.port.pre.mk> + +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb-0.1.8:${PORTSDIR}/devel/libusb +.endif + pre-configure: @${FIND} ${WRKSRC} -name Makefile.in | ${XARGS} \ ${REINPLACE_CMD} -e 's|-ldl||g' post-install: @${CAT} ${PKGMESSAGE} -.include <bsd.port.mk> +.include <bsd.port.post.mk> diff --git a/sysutils/usbutils/Makefile b/sysutils/usbutils/Makefile index ee636e9a5d99..c3538ffce15c 100644 --- a/sysutils/usbutils/Makefile +++ b/sysutils/usbutils/Makefile @@ -13,8 +13,6 @@ MASTER_SITE_SUBDIR= linux-usb MAINTAINER= brix@FreeBSD.org COMMENT= Utility for listing USB devices -LIB_DEPENDS= usb-0.1:${PORTSDIR}/devel/libusb - GNU_CONFIGURE= yes CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include" \ LDFLAGS="-L${LOCALBASE}/lib" @@ -25,6 +23,10 @@ PORTDOCS= AUTHORS ChangeLog NEWS README .include <bsd.port.pre.mk> +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb-0.1:${PORTSDIR}/devel/libusb +.endif + post-install: .if !defined(NOPORTDOCS) ${MKDIR} ${DOCSDIR} diff --git a/x11/kde4-workspace/Makefile b/x11/kde4-workspace/Makefile index 9380d226f5fb..84a6296334cc 100644 --- a/x11/kde4-workspace/Makefile +++ b/x11/kde4-workspace/Makefile @@ -16,8 +16,7 @@ DIST_SUBDIR= KDE MAINTAINER= kde@FreeBSD.org COMMENT= Basic applications for the KDE system -LIB_DEPENDS= usb-0.1.8:${PORTSDIR}/devel/libusb \ - qimageblitz.4:${PORTSDIR}/x11/qimageblitz\ +LIB_DEPENDS= qimageblitz.4:${PORTSDIR}/x11/qimageblitz\ dbus-1.3:${PORTSDIR}/devel/dbus \ hal.1:${PORTSDIR}/sysutils/hal \ xklavier.12:${PORTSDIR}/x11/libxklavier @@ -52,6 +51,12 @@ CMAKE_ARGS+= -DCMAKE_REQUIRED_FLAGS:STRING="-L${LOCALBASE}/lib" \ #Xmms and Googlegadgets could be enabled, #QEdje has not been ported yet. +.include <bsd.port.pre.mk> + +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb-0.1.8:${PORTSDIR}/devel/libusb +.endif + post-extract: ${MKDIR} ${WRKSRC} @@ -74,4 +79,4 @@ post-install: @${MV} ${PREFIX}/lib/kde4/libexec/kdm_greet ${PREFIX}/lib/kde4/libexec/kdm-bin_greet @${INSTALL_SCRIPT} ${WRKDIR}/kdm ${PREFIX}/bin -.include <bsd.port.mk> +.include <bsd.port.post.mk> diff --git a/x11/kdebase3/Makefile b/x11/kdebase3/Makefile index eb8b7f5785f8..7bf87dee6da4 100644 --- a/x11/kdebase3/Makefile +++ b/x11/kdebase3/Makefile @@ -23,8 +23,7 @@ BUILD_DEPENDS= imake:${PORTSDIR}/devel/imake \ bdftopcf:${PORTSDIR}/x11-fonts/bdftopcf \ mkfontdir:${PORTSDIR}/x11-fonts/mkfontdir LIB_DEPENDS= sasl2:${PORTSDIR}/security/cyrus-sasl2 \ - smbclient:${PORTSDIR}/net/samba-libsmbclient \ - usb-0.1:${PORTSDIR}/devel/libusb + smbclient:${PORTSDIR}/net/samba-libsmbclient CONFLICTS= kdeartwork-3.[2-3]* kdelibs-3.[0-4]* kdeutils-3.[0-2]* @@ -59,6 +58,10 @@ OPTIONS= ARTSWRAPPER "Suid wrapper for aRts, req'd for realtime prio" on \ .include "${.CURDIR}/../../x11/kde3/Makefile.kde" .include <bsd.port.pre.mk> +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb-0.1:${PORTSDIR}/devel/libusb +.endif + .if !defined(WITHOUT_ARTSWRAPPER) RUN_DEPENDS+= artswrapper:${PORTSDIR}/audio/artswrapper .endif diff --git a/x11/kdebase4-workspace/Makefile b/x11/kdebase4-workspace/Makefile index 9380d226f5fb..84a6296334cc 100644 --- a/x11/kdebase4-workspace/Makefile +++ b/x11/kdebase4-workspace/Makefile @@ -16,8 +16,7 @@ DIST_SUBDIR= KDE MAINTAINER= kde@FreeBSD.org COMMENT= Basic applications for the KDE system -LIB_DEPENDS= usb-0.1.8:${PORTSDIR}/devel/libusb \ - qimageblitz.4:${PORTSDIR}/x11/qimageblitz\ +LIB_DEPENDS= qimageblitz.4:${PORTSDIR}/x11/qimageblitz\ dbus-1.3:${PORTSDIR}/devel/dbus \ hal.1:${PORTSDIR}/sysutils/hal \ xklavier.12:${PORTSDIR}/x11/libxklavier @@ -52,6 +51,12 @@ CMAKE_ARGS+= -DCMAKE_REQUIRED_FLAGS:STRING="-L${LOCALBASE}/lib" \ #Xmms and Googlegadgets could be enabled, #QEdje has not been ported yet. +.include <bsd.port.pre.mk> + +.if ${OSVERSION} < 800069 +LIB_DEPENDS+= usb-0.1.8:${PORTSDIR}/devel/libusb +.endif + post-extract: ${MKDIR} ${WRKSRC} @@ -74,4 +79,4 @@ post-install: @${MV} ${PREFIX}/lib/kde4/libexec/kdm_greet ${PREFIX}/lib/kde4/libexec/kdm-bin_greet @${INSTALL_SCRIPT} ${WRKDIR}/kdm ${PREFIX}/bin -.include <bsd.port.mk> +.include <bsd.port.post.mk> |