diff options
Diffstat (limited to 'dev-libs/libhid')
-rw-r--r-- | dev-libs/libhid/Manifest | 8 | ||||
-rw-r--r-- | dev-libs/libhid/files/libhid-0.2.16-gentoo.patch | 21 | ||||
-rw-r--r-- | dev-libs/libhid/files/libhid-0.2.16-libusb.patch | 25 | ||||
-rw-r--r-- | dev-libs/libhid/files/libhid-0.2.16-swig.patch | 45 | ||||
-rw-r--r-- | dev-libs/libhid/libhid-0.2.16-r4.ebuild | 56 | ||||
-rw-r--r-- | dev-libs/libhid/metadata.xml | 11 |
6 files changed, 166 insertions, 0 deletions
diff --git a/dev-libs/libhid/Manifest b/dev-libs/libhid/Manifest new file mode 100644 index 000000000000..6485d22a7363 --- /dev/null +++ b/dev-libs/libhid/Manifest @@ -0,0 +1,8 @@ +AUX libhid-0.2.16-gentoo.patch 628 SHA256 8e1b2de09cd20ad82dfc344f5bd7900e4c2e9597d6b8fa1ebc5df2593cc11753 SHA512 a756d99b115e1903ff633e511c8b9c2de1743b9d8c5050ba422281aea6c4d330b70632e45f688177d8d06ba4077574193e7e378f0e0a79924d2463f5e1584d40 WHIRLPOOL a68a7bf477a55afcb15b22f56bbe1b2f790927a8ad11062ab2963388d28e5838a65e58c402993db8f494b925f9be19750d7a1a225349d2a702ea57c92b6775ff +AUX libhid-0.2.16-libusb.patch 421 SHA256 cf9afdad56296622811feee908f506adcaa17aed6cd0f5f82f2fe7227fdb2a32 SHA512 0fa3be119d1ab3efa428c81b96709a0cee4fd40fa4515d255a64be095a4e26f68a2c8175beda6615c720aaa593edc5aaaa2909bfc5ab9e7f9b818d8c507b9fde WHIRLPOOL 40c91f44ca567417b4499047ffac83acb06dc9455cdc1dbef2bcd849b31974b140646ebd910832ca1171ef49122951bb7b2009f5fd8539eb8c2059ba208cf052 +AUX libhid-0.2.16-swig.patch 1424 SHA256 3994c73ecc8bc2faac6a2e26a9f574bee05b2340d5b87f8516afd714de79eb61 SHA512 62ff58921aa99947f8b33b0d1c02cf30f19fd3f75393cbb681846266b67af49bf6a2e70a995c9a7252b27c67e573e2c198b366830c15ca3c5e87a93325a849cb WHIRLPOOL 6cf22a0e2915d1cd643357a8846397484456d08a05321f58a6ad094c18a86b79183c18ee5cc7af70671fb7c4bee94088fd51194c08c4116a2776db3b8cd7fcb4 +DIST libhid-0.2.16.tar.gz 435245 SHA256 f6809ab3b9c907cbb05ceba9ee6ca23a705f85fd71588518e14b3a7d9f2550e5 SHA512 3c9348f9d63e0e1577e983c65ff8e6acbaee0d5f43ecb29b7004654a7e9d14a94176aa029f259e0b8576fc30e8a9af6d1df34912dd582bfadc2b29f9b87eb52b WHIRLPOOL 76edaf3a22f015d16fe2583102c9ee9a839ff17b8172309d3595f3054a22e3f8b119b3560a621490fac7a47966f2519b9b31824e91958012f767387adaa8871c +EBUILD libhid-0.2.16-r4.ebuild 1209 SHA256 0f683ad6a5c065472ef7b76233ee53cecbdbcb5e6a79ca96bb5e04558d21394b SHA512 d16cfc49ff2239d253c801e51043a1c5600779cf8c534e736b3c367ffcb114f6a92663ab067043eb47cde2479cd487b084c8f6d4c405a703fc95b0ea6e8b3e9d WHIRLPOOL d286b80d70425eb8e5852de98c54157cbb0ff0e2e0283f8f2bdc5154efb855e0c75a048d3eea2331000e3a1468249b0d441e5af7e35579b6a79876ae16a45b58 +MISC ChangeLog 3025 SHA256 11c975d21b98500a2c5704ab417779ac389817934f78cfcfaa078939b0b69de9 SHA512 bf23bbe01c2f9672bc364357ba19e0aec943497ba8a140f252d1834df92ad9034ee05cd470039ca30bdaedee3fabb10d5474dcca5a0db07428a5a85fe08dee81 WHIRLPOOL 700cd64a139f39db62c82138b7612fd98322301062eaf025875753433c949d8df025c4e168f9f2bb44e8bb1edced9d287f066ce83b2abaa634b027e31e8e2215 +MISC ChangeLog-2015 2433 SHA256 33b4a20764ddfc1677e83c0f0972882afef50b9e214f8adfd2caca3339bb48dc SHA512 4d9b5fe693d079a4731f544a3a3751bb82ae0b7544b79e7da26014eea038588430bf90d89886a7878b1982ea4ab24c5f8a06d0db2ed0a39950ca5c8766d46fa6 WHIRLPOOL 9845e170d4be4531f0b35045295394f6bfeadc2d0fdaf77249ec9daaa16d76a767b2ef8d83df4f43a750971e846bcf3e7c32bd3e20758152a26dd9e97c937e27 +MISC metadata.xml 495 SHA256 0b8bcaf0f3960dd351fed4106c241376527b6f7958d9da16c4b27f136e343faf SHA512 e465b7596e61565aa21ce9c32d7d76b099ee21c471c341677604f5816f2b7547c57f8a065f2bb9df2356c3e6d5fd26efb303884117096e8178127490a14ca268 WHIRLPOOL 9afba98ac9519cf36c8d859d7baa5c090cbf1893cadb6dc324f8a31a13c8d8a8b0c46f7dcf91b05ca4e5b304f409add9abb32907de45bd84f4f1a7ae6564bdfc diff --git a/dev-libs/libhid/files/libhid-0.2.16-gentoo.patch b/dev-libs/libhid/files/libhid-0.2.16-gentoo.patch new file mode 100644 index 000000000000..b5960af5d7d6 --- /dev/null +++ b/dev-libs/libhid/files/libhid-0.2.16-gentoo.patch @@ -0,0 +1,21 @@ +--- a/configure.ac ++++ b/configure.ac +@@ -78,7 +78,6 @@ + AC_C_BIGENDIAN + AC_C_STRINGIZE + +-MD_CONF_DEBUGGING + MD_CONF_COMPILER + AM_CONDITIONAL(OS_LINUX, test "$MD_OS" = "linux") + AM_CONDITIONAL(OS_BSD, test "$MD_OS" = "bsd") +--- a/m4/md_check_gcc3.m4 ++++ b/m4/md_check_gcc3.m4 +@@ -1,7 +1,7 @@ + AC_DEFUN([MD_CHECK_GCC3], + [ + if [[ "$GCC" = "yes" ]]; then +- ver=$(gcc -dD -E - < /dev/null | sed -ne 's,.*__GNUC__ ,,p') ++ ver=$(${CC} -dD -E - < /dev/null | sed -ne 's,.*__GNUC__ ,,p') + case $ver in + *[[^[:digit:]]]*) + AC_MSG_WARN([Could not determine compiler version. Trying our luck...]) diff --git a/dev-libs/libhid/files/libhid-0.2.16-libusb.patch b/dev-libs/libhid/files/libhid-0.2.16-libusb.patch new file mode 100644 index 000000000000..aa49205ec75d --- /dev/null +++ b/dev-libs/libhid/files/libhid-0.2.16-libusb.patch @@ -0,0 +1,25 @@ +--- a/configure.ac ++++ b/configure.ac +@@ -59,6 +59,8 @@ + MD_CHECK_OS + + MD_CHECK_LIBUSB018B ++LIBS="$LIBS $LIBUSB_LIBS" ++INCLUDES="$INCLUDES $LIBUSB_CFLAGS" + + AC_PROG_CC + MD_CHECK_GCC3 +@@ -97,13 +99,6 @@ + + MD_CHECK_DOXYGEN + +-MD_CONF_FLAGS( +- [], +- [$OS_CFLAGS $LIBUSB_CFLAGS], +- [], +- [$OS_LDFLAGS $LIBUSB_LIBS] +-) +- + MD_CONF_DB2MAN + + ##### OUTPUT ################################################################# diff --git a/dev-libs/libhid/files/libhid-0.2.16-swig.patch b/dev-libs/libhid/files/libhid-0.2.16-swig.patch new file mode 100644 index 000000000000..ce5dae7481b9 --- /dev/null +++ b/dev-libs/libhid/files/libhid-0.2.16-swig.patch @@ -0,0 +1,45 @@ +--- a/configure.ac ++++ b/configure.ac +@@ -88,8 +87,8 @@ + if test "${ac_cv_enable_swig}" = "no" ; then + AM_CONDITIONAL(HAVE_SWIG, false) + else +- AC_PROG_SWIG(1.3) +- AM_CONDITIONAL(HAVE_SWIG, "$SWIG" -version) ++ AC_CHECK_PROG(SWIG,swig,swig,false) ++ AM_CONDITIONAL(HAVE_SWIG, "$ac_cv_prog_SWIG" -version) + if test -z "${HAVE_SWIG_TRUE}" ; then + AM_PATH_PYTHON + SWIG_PYTHON +--- a/swig/Makefile.am ++++ b/swig/Makefile.am +@@ -1,7 +1,7 @@ + # AM_MAKEFLAGS = @MAKEFLAGS@ + ACLOCAL_AMFLAGS = -I m4 + +-AM_CPPFLAGS = $(SWIG_PYTHON_CPPFLAGS) -I$(top_srcdir)/include -I$(top_srcdir)/hidparser -DHID_INTERNAL -DSWIG ++AM_CPPFLAGS = $(SWIG_PYTHON_CPPFLAGS) -iquote$(top_srcdir)/include -I$(top_srcdir)/hidparser -DHID_INTERNAL -DSWIG + AM_CFLAGS = -fPIC -fno-strict-aliasing + AM_LDFLAGS = -shared ../src/libhid.la -lusb + +@@ -29,7 +29,7 @@ __init__.py: hid.py + + %_wrap.c %.py: %.i $(top_srcdir)/include/hid.h + $(SWIG) $(SWIG_PYTHON_OPT) $(SWIG_INC) -o $@ $< +- echo '#include <compiler.h>' > tmp.c ++ echo '#include "compiler.h"' > tmp.c + sed -e 's/PyObject \*self/& UNUSED/' \ + -e 's/int flags)/int flags UNUSED)/' < $@ >> tmp.c \ + && mv tmp.c $@ +--- a/swig/hid.i ++++ b/swig/hid.i +@@ -1,7 +1,7 @@ + %module(docstring="libhid is a user-space USB HID access library built on libusb.", "threads"=1) hid + %{ +-#include <compiler.h> +-#include <hid.h> ++#include "compiler.h" ++#include "hid.h" + %} + + %feature("autodoc","0"); diff --git a/dev-libs/libhid/libhid-0.2.16-r4.ebuild b/dev-libs/libhid/libhid-0.2.16-r4.ebuild new file mode 100644 index 000000000000..d082da46f04a --- /dev/null +++ b/dev-libs/libhid/libhid-0.2.16-r4.ebuild @@ -0,0 +1,56 @@ +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=5 +PYTHON_COMPAT=( python2_7 ) +inherit autotools eutils python-single-r1 + +DESCRIPTION="Provides a generic and flexible way to access and interact with USB HID devices" +HOMEPAGE="http://libhid.alioth.debian.org/" +SRC_URI="http://beta.magicaltux.net/${P}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~ppc ~ppc64 ~x86" +IUSE="doc python static-libs" + +RDEPEND=" + python? ( ${PYTHON_DEPS} ) + virtual/libusb:0 +" +DEPEND=" + ${RDEPEND} + doc? ( app-doc/doxygen ) + python? ( dev-lang/swig ) +" +REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )" + +src_prepare() { + epatch "${FILESDIR}"/${P}-gentoo.patch + epatch "${FILESDIR}"/${P}-swig.patch + epatch "${FILESDIR}"/${P}-libusb.patch + + eautoreconf +} + +src_configure() { + export OS_LDFLAGS="${LDFLAGS}" + use python && export PYTHON_LDFLAGS=$(${EPYTHON}-config --ldflags) + + econf \ + $(use_enable python swig) \ + $(use_enable static-libs static) \ + $(use_with doc doxygen) \ + --disable-debug \ + --disable-werror +} + +DOCS=( AUTHORS ChangeLog NEWS README README.licence TODO ) + +src_install() { + default + + use doc && dohtml -r doc/html/* + + prune_libtool_files +} diff --git a/dev-libs/libhid/metadata.xml b/dev-libs/libhid/metadata.xml new file mode 100644 index 000000000000..8ab798976991 --- /dev/null +++ b/dev-libs/libhid/metadata.xml @@ -0,0 +1,11 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> +<!-- maintainer-needed --> +<longdescription lang="en"> +libhid provides a generic and flexible way to access and interact with USB +HID devices, much like libusb does for plain USB devices. It is based on +libusb, thus it requires no HID support in the kernel and provides means to +take control over a device even if the kernel governs it. +</longdescription> +</pkgmetadata> |