summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlastair Tse <liquidx@gentoo.org>2006-04-24 21:29:30 +0000
committerAlastair Tse <liquidx@gentoo.org>2006-04-24 21:29:30 +0000
commitfdfacb2b39b687065e57f34b61aa3625e30f48f1 (patch)
treeea7e051a2a195ad1d98b23f3e71d084e1a9c4b33 /dev-libs
parentversion bump (bug #129798) (diff)
downloadgentoo-2-fdfacb2b39b687065e57f34b61aa3625e30f48f1.tar.gz
gentoo-2-fdfacb2b39b687065e57f34b61aa3625e30f48f1.tar.bz2
gentoo-2-fdfacb2b39b687065e57f34b61aa3625e30f48f1.zip
added freebsd patches (#128937) and possible solution to doc generation bug (#66172)
(Portage version: 2.1_pre9)
Diffstat (limited to 'dev-libs')
-rw-r--r--dev-libs/libusb/ChangeLog9
-rw-r--r--dev-libs/libusb/files/0.1.12-fbsd.patch97
-rw-r--r--dev-libs/libusb/files/digest-libusb-0.1.123
-rw-r--r--dev-libs/libusb/libusb-0.1.12.ebuild52
4 files changed, 160 insertions, 1 deletions
diff --git a/dev-libs/libusb/ChangeLog b/dev-libs/libusb/ChangeLog
index c9f051cd9839..d1e75cb4d298 100644
--- a/dev-libs/libusb/ChangeLog
+++ b/dev-libs/libusb/ChangeLog
@@ -1,6 +1,13 @@
# ChangeLog for dev-libs/libusb
# Copyright 2002-2006 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/dev-libs/libusb/ChangeLog,v 1.43 2006/04/04 09:26:36 flameeyes Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-libs/libusb/ChangeLog,v 1.44 2006/04/24 21:29:30 liquidx Exp $
+
+*libusb-0.1.12 (24 Apr 2006)
+
+ 24 Apr 2006; Alastair Tse <liquidx@gentoo.org> +files/0.1.12-fbsd.patch,
+ +libusb-0.1.12.ebuild:
+ added freebsd patches (#128937) and possible solution to doc generation bug
+ (#66172)
04 Apr 2006; Diego Pettenò <flameeyes@gentoo.org> libusb-0.1.11.ebuild:
Add ~x86-fbsd keyword.
diff --git a/dev-libs/libusb/files/0.1.12-fbsd.patch b/dev-libs/libusb/files/0.1.12-fbsd.patch
new file mode 100644
index 000000000000..57fd2ee4cd26
--- /dev/null
+++ b/dev-libs/libusb/files/0.1.12-fbsd.patch
@@ -0,0 +1,97 @@
+Index: libusb-0.1.12/configure.in
+===================================================================
+--- libusb-0.1.12.orig/configure.in
++++ libusb-0.1.12/configure.in
+@@ -90,6 +90,8 @@ LINUX_API=0
+ DARWIN_API=0
+ BSD_API=0
+
++DEFINE_USB_HID_DESCRIPTOR=1
++
+ AC_MSG_CHECKING(for what USB OS support)
+ case $host in
+ *-linux*)
+@@ -101,13 +103,40 @@ case $host in
+ AC_MSG_RESULT(Linux)
+ OSLIBS=""
+ ;;
+- *-freebsd*|*-kfreebsd*-gnu|*-openbsd*|*-netbsd*)
++ *-freebsd*)
++ AC_DEFINE(BSD_API, 1)
++ AC_DEFINE(LINUX_API, 0)
++ AC_DEFINE(DARWIN_API, 0)
++ BSD_API=1
++ os_support=bsd
++ AC_MSG_RESULT(FreeBSD)
++ OSLIBS=""
++ AC_CHECK_HEADERS([dev/usb/usbhid.h])
++ if test "x$ac_cv_header_dev_usb_hisbhid_h" = "xyes"; then
++ AC_MSG_CHECKING([for usb_hid_descriptor])
++ have_usb_hid_descriptor=no
++ AC_TRY_COMPILE([
++ #include <sys/types.h>
++ #include <dev/usb/usb.h>
++ #include <dev/usb/usbhid.h>
++ ], [
++ struct usb_hid_descriptor descr;
++ ], [
++ have_usb_hid_descriptor=yes
++ ])
++ AC_MSG_RESULT([$have_usb_hid_descriptor])
++ if test "x$have_usb_hid_descriptor" = "xyes"; then
++ DEFINE_USB_HID_DESCRIPTOR=0
++ fi
++ fi
++ ;;
++ *-dragonfly*|*-kfreebsd*-gnu|*-openbsd*|*-netbsd*)
+ AC_DEFINE(BSD_API, 1)
+ AC_DEFINE(LINUX_API, 0)
+ AC_DEFINE(DARWIN_API, 0)
+ BSD_API=1
+ os_support=bsd
+- AC_MSG_RESULT(FreeBSD, OpenBSD and/or NetBSD)
++ AC_MSG_RESULT(DragonFly, OpenBSD and/or NetBSD)
+ OSLIBS=""
+ ;;
+ *-darwin*)
+@@ -128,6 +157,7 @@ esac
+ AC_SUBST(DARWIN_API)
+ AC_SUBST(LINUX_API)
+ AC_SUBST(BSD_API)
++AC_SUBST(DEFINE_USB_HID_DESCRIPTOR)
+
+ AM_CONDITIONAL(LINUX_API, test "$os_support" = "linux")
+ AM_CONDITIONAL(BSD_API, test "$os_support" = "bsd")
+Index: libusb-0.1.12/usb.h.in
+===================================================================
+--- libusb-0.1.12.orig/usb.h.in
++++ libusb-0.1.12/usb.h.in
+@@ -17,6 +17,12 @@
+
+ #include <dirent.h>
+
++#if ! @DEFINE_USB_HID_DESCRIPTOR@ && defined(__FreeBSD__)
++#include <sys/types.h>
++#include <dev/usb/usb.h>
++#include <dev/usb/usbhid.h>
++#endif
++
+ /*
+ * USB spec information
+ *
+@@ -75,6 +81,7 @@ struct usb_string_descriptor {
+ u_int16_t wData[1];
+ };
+
++#if ! @DEFINE_USB_HID_DESCRIPTOR@ && defined(__FreeBSD__)
+ /* HID descriptor */
+ struct usb_hid_descriptor {
+ u_int8_t bLength;
+@@ -86,6 +93,7 @@ struct usb_hid_descriptor {
+ /* u_int16_t wDescriptorLength; */
+ /* ... */
+ };
++#endif
+
+ /* Endpoint descriptor */
+ #define USB_MAXENDPOINTS 32
diff --git a/dev-libs/libusb/files/digest-libusb-0.1.12 b/dev-libs/libusb/files/digest-libusb-0.1.12
new file mode 100644
index 000000000000..7b884d146b0f
--- /dev/null
+++ b/dev-libs/libusb/files/digest-libusb-0.1.12
@@ -0,0 +1,3 @@
+MD5 caf182cbc7565dac0fd72155919672e6 libusb-0.1.12.tar.gz 389343
+RMD160 63848df717e00fff67ab30ba86a85466370d4e8e libusb-0.1.12.tar.gz 389343
+SHA256 37f6f7d9de74196eb5fc0bbe0aea9b5c939de7f500acba3af6fd643f3b538b44 libusb-0.1.12.tar.gz 389343
diff --git a/dev-libs/libusb/libusb-0.1.12.ebuild b/dev-libs/libusb/libusb-0.1.12.ebuild
new file mode 100644
index 000000000000..69f9b0f03094
--- /dev/null
+++ b/dev-libs/libusb/libusb-0.1.12.ebuild
@@ -0,0 +1,52 @@
+# Copyright 1999-2006 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/dev-libs/libusb/libusb-0.1.12.ebuild,v 1.1 2006/04/24 21:29:30 liquidx Exp $
+
+inherit eutils libtool autotools
+
+DESCRIPTION="Userspace access to USB devices"
+HOMEPAGE="http://libusb.sourceforge.net/"
+SRC_URI="mirror://sourceforge/libusb/${P}.tar.gz"
+
+LICENSE="LGPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc-macos ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd"
+IUSE="debug doc"
+
+RDEPEND=""
+
+DEPEND="doc? ( app-text/openjade
+ app-text/docbook-dsssl-stylesheets
+ ~app-text/docbook-sgml-dtd-4.2 )"
+
+src_unpack() {
+ unpack ${A}
+ cd ${S}
+ sed -i -e 's:-Werror::' Makefile.am
+
+ epatch "${FILESDIR}/${PV}-fbsd.patch"
+
+ eautoreconf
+
+ elibtoolize
+}
+
+src_compile() {
+ econf \
+ $(use_enable debug debug all) \
+ $(use_enable doc build-docs) \
+ || die "econf failed"
+ emake || die "emake failed"
+}
+
+src_install() {
+ make DESTDIR=${D} install || die "make install failed"
+ dodoc AUTHORS NEWS README || die "dodoc failed"
+ if use doc; then
+ dohtml doc/html/*.html || die "dohtml failed"
+ fi
+}
+
+src_test() {
+ return
+}