Index: head/comms/hidapi/Makefile =================================================================== --- head/comms/hidapi/Makefile (revision 568636) +++ head/comms/hidapi/Makefile (revision 568637) @@ -1,32 +1,29 @@ # $FreeBSD$ PORTNAME= hidapi DISTVERSIONPREFIX= ${PORTNAME}- -DISTVERSION= 0.8.0-rc1 -PORTREVISION= 3 +DISTVERSION= 0.10.1 CATEGORIES= comms -MAINTAINER= tijl@FreeBSD.org +MAINTAINER= ehaupt@FreeBSD.org COMMENT= Library to access USB HID-class devices LICENSE= BSD3CLAUSE GPLv3 LICENSE_COMB= dual +USES= autoreconf gettext-tools iconv:wchar_t libtool localbase \ + pkgconfig + USE_GITHUB= yes -GH_ACCOUNT= signal11 +GH_ACCOUNT= libusb -USES= autoreconf gettext-tools iconv:wchar_t libtool GNU_CONFIGURE= yes -USE_LDCONFIG= yes INSTALL_TARGET= install-strip -PORTDOCS= * - -CPPFLAGS+= -I${LOCALBASE}/include -LIBS+= -L${LOCALBASE}/lib +USE_LDCONFIG= yes OPTIONS_DEFINE= DOCS pre-configure: @${CP} ${LOCALBASE}/share/gettext/config.rpath ${WRKSRC} .include Index: head/comms/hidapi/distinfo =================================================================== --- head/comms/hidapi/distinfo (revision 568636) +++ head/comms/hidapi/distinfo (revision 568637) @@ -1,2 +1,3 @@ -SHA256 (signal11-hidapi-hidapi-0.8.0-rc1_GH0.tar.gz) = 3c147200bf48a04c1e927cd81589c5ddceff61e6dac137a605f6ac9793f4af61 -SIZE (signal11-hidapi-hidapi-0.8.0-rc1_GH0.tar.gz) = 101833 +TIMESTAMP = 1615890404 +SHA256 (libusb-hidapi-hidapi-0.10.1_GH0.tar.gz) = f71dd8a1f46979c17ee521bc2117573872bbf040f8a4750e492271fc141f2644 +SIZE (libusb-hidapi-hidapi-0.10.1_GH0.tar.gz) = 119581 Index: head/comms/hidapi/files/patch-libusb-hid.c =================================================================== --- head/comms/hidapi/files/patch-libusb-hid.c (revision 568636) +++ head/comms/hidapi/files/patch-libusb-hid.c (nonexistent) @@ -1,45 +0,0 @@ ---- libusb/hid.c.orig 2013-10-06 22:43:37 UTC -+++ libusb/hid.c -@@ -25,6 +25,8 @@ - - #define _GNU_SOURCE /* needed for wcsdup() before glibc 2.10 */ - -+#include -+ - /* C */ - #include - #include -@@ -250,7 +252,7 @@ static int get_usage(uint8_t *report_des - } - #endif /* INVASIVE_GET_USAGE */ - --#ifdef __FreeBSD__ -+#if ! HAVE_DECL_LIBUSB_GET_STRING_DESCRIPTOR - /* The FreeBSD version of libusb doesn't have this funciton. In mainline - libusb, it's inlined in libusb.h. This function will bear a striking - resemblence to that one, because there's about one way to code it. -@@ -333,11 +335,7 @@ static wchar_t *get_usb_string(libusb_de - size_t inbytes; - size_t outbytes; - size_t res; --#ifdef __FreeBSD__ -- const char *inptr; --#else -- char *inptr; --#endif -+ ICONV_CONST char *inptr; - char *outptr; - - /* Determine which language to use. */ -@@ -757,7 +755,11 @@ static void *read_thread(void *param) - libusb_cancel_transfer(dev->transfer); - - while (!dev->cancelled) -+#if HAVE_DECL_LIBUSB_HANDLE_EVENTS_COMPLETED - libusb_handle_events_completed(usb_context, &dev->cancelled); -+#else -+ libusb_handle_events(usb_context); -+#endif - - /* Now that the read thread is stopping, Wake any threads which are - waiting on data (in hid_read_timeout()). Do this under a mutex to Property changes on: head/comms/hidapi/files/patch-libusb-hid.c ___________________________________________________________________ Deleted: fbsd:nokeywords ## -1 +0,0 ## -yes \ No newline at end of property Deleted: svn:eol-style ## -1 +0,0 ## -native \ No newline at end of property Deleted: svn:mime-type ## -1 +0,0 ## -text/plain \ No newline at end of property Index: head/comms/hidapi/files/patch-configure.ac =================================================================== --- head/comms/hidapi/files/patch-configure.ac (revision 568636) +++ head/comms/hidapi/files/patch-configure.ac (revision 568637) @@ -1,18 +1,18 @@ ---- configure.ac.orig 2013-10-06 22:43:37 UTC +--- configure.ac.orig 2020-11-24 11:39:27 UTC +++ configure.ac -@@ -89,11 +89,11 @@ case $host in +@@ -82,13 +82,11 @@ case $host in os="freebsd" threads="pthreads" - CFLAGS="$CFLAGS -I/usr/local/include" - LDFLAGS="$LDFLAGS -L/usr/local/lib" - LIBS="${LIBS}" - AC_CHECK_LIB([usb], [libusb_init], [LIBS_LIBUSB_PRIVATE="${LIBS_LIBUSB_PRIVATE} -lusb"], [hidapi_lib_error libusb]) + PKG_CHECK_MODULES([libusb], [libusb-1.0 >= 1.0.9], true, [hidapi_lib_error libusb-1.0]) + LIBS_LIBUSB_PRIVATE="${LIBS_LIBUSB_PRIVATE} $libusb_LIBS" + CFLAGS_LIBUSB="${CFLAGS_LIBUSB} $libusb_CFLAGS" - AC_CHECK_LIB([iconv], [iconv_open], [LIBS_LIBUSB_PRIVATE="${LIBS_LIBUSB_PRIVATE} -liconv"], [hidapi_lib_error libiconv]) -+ AC_CHECK_DECLS([libusb_get_string_descriptor], [], [], [[#include ]]) -+ AC_CHECK_DECLS([libusb_handle_events_completed], [], [], [[#include ]]) + AM_ICONV + LIBS_LIBUSB_PRIVATE="${LIBS_LIBUSB_PRIVATE} ${LTLIBICONV}" - echo libs_priv: $LIBS_LIBUSB_PRIVATE ;; - *-mingw*) + *-kfreebsd*) + AC_MSG_RESULT([ (kFreeBSD back-end)]) Index: head/comms/hidapi/pkg-descr =================================================================== --- head/comms/hidapi/pkg-descr (revision 568636) +++ head/comms/hidapi/pkg-descr (revision 568637) @@ -1,6 +1,6 @@ HIDAPI is a platform independent library that allows applications to work with USB HID-Class devices. While it can be used to communicate with standard HID devices like keyboards, mice, and joysticks, it is most useful when used with custom (Vendor-Defined) HID devices. -WWW: http://www.signal11.us/oss/hidapi/ +WWW: https://github.com/libusb/hidapi Index: head/comms/hidapi/pkg-plist =================================================================== --- head/comms/hidapi/pkg-plist (revision 568636) +++ head/comms/hidapi/pkg-plist (revision 568637) @@ -1,6 +1,12 @@ include/hidapi/hidapi.h lib/libhidapi.a lib/libhidapi.so lib/libhidapi.so.0 lib/libhidapi.so.0.0.0 libdata/pkgconfig/hidapi.pc +%%PORTDOCS%%%%DOCSDIR%%/AUTHORS.txt +%%PORTDOCS%%%%DOCSDIR%%/LICENSE-bsd.txt +%%PORTDOCS%%%%DOCSDIR%%/LICENSE-gpl3.txt +%%PORTDOCS%%%%DOCSDIR%%/LICENSE-orig.txt +%%PORTDOCS%%%%DOCSDIR%%/LICENSE.txt +%%PORTDOCS%%%%DOCSDIR%%/README.md Index: head/comms/py-hidapi/Makefile =================================================================== --- head/comms/py-hidapi/Makefile (revision 568636) +++ head/comms/py-hidapi/Makefile (revision 568637) @@ -1,26 +1,27 @@ # Created by: Emanuel Haupt # $FreeBSD$ PORTNAME= hidapi PORTVERSION= 0.10.1 +PORTREVISION= 1 CATEGORIES= comms python MASTER_SITES= CHEESESHOP PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} MAINTAINER= ehaupt@FreeBSD.org COMMENT= Cython interface to comms/hidapi LICENSE= GPLv3 LIB_DEPENDS= libhidapi.so:comms/hidapi USES= python:3.6+ USE_PYTHON= autoplist cython distutils post-patch: @${REINPLACE_CMD} -e 's|usb-1.0|usb|g' ${WRKSRC}/setup.py post-install: @${STRIP_CMD} ${STAGEDIR}${PYTHON_SITELIBDIR}/hid*.so .include