summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Gilbert <floppym@gentoo.org>2016-11-03 21:47:59 -0400
committerMike Gilbert <floppym@gentoo.org>2016-11-03 21:48:13 -0400
commit2257d1f32b6301fd4f232e6c8e7667aa81169c24 (patch)
tree15e6c0bc5e9ea36fb38538bc09fba05a1f5604d6 /sys-apps/hwids/hwids-20161103.ebuild
parentdev-games/openscenegraph: stabilize 3.2.1-r2, fixed bug 589168 (diff)
downloadgentoo-2257d1f32b6301fd4f232e6c8e7667aa81169c24.tar.gz
gentoo-2257d1f32b6301fd4f232e6c8e7667aa81169c24.tar.bz2
gentoo-2257d1f32b6301fd4f232e6c8e7667aa81169c24.zip
sys-apps/hwids: bump to 20161103
Package-Manager: portage-2.3.2_p4
Diffstat (limited to 'sys-apps/hwids/hwids-20161103.ebuild')
-rw-r--r--sys-apps/hwids/hwids-20161103.ebuild74
1 files changed, 74 insertions, 0 deletions
diff --git a/sys-apps/hwids/hwids-20161103.ebuild b/sys-apps/hwids/hwids-20161103.ebuild
new file mode 100644
index 000000000000..2b7cac3cf656
--- /dev/null
+++ b/sys-apps/hwids/hwids-20161103.ebuild
@@ -0,0 +1,74 @@
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="6"
+
+inherit udev eutils
+
+DESCRIPTION="Hardware (PCI, USB, OUI, IAB) IDs databases"
+HOMEPAGE="https://github.com/gentoo/hwids"
+if [[ ${PV} == "99999999" ]]; then
+ inherit git-r3
+ EGIT_REPO_URI="${HOMEPAGE}.git"
+else
+ SRC_URI="${HOMEPAGE}/archive/${P}.tar.gz"
+ KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~x64-freebsd ~amd64-linux ~arm-linux ~x86-linux"
+fi
+
+LICENSE="|| ( GPL-2 BSD ) public-domain"
+SLOT="0"
+IUSE="+net +pci +udev +usb"
+
+DEPEND="udev? (
+ dev-lang/perl
+ >=virtual/udev-206
+)"
+[[ ${PV} == "99999999" ]] && DEPEND+=" udev? ( net-misc/curl )"
+RDEPEND="!<sys-apps/pciutils-3.1.9-r2
+ !<sys-apps/usbutils-005-r1"
+
+if [[ ${PV} != 99999999 ]]; then
+ S=${WORKDIR}/hwids-${P}
+fi
+
+src_unpack() {
+ if [[ ${PV} == 99999999 ]]; then
+ git-r3_src_unpack
+ cd "${S}" || die
+ emake fetch
+ else
+ default
+ fi
+}
+
+src_prepare() {
+ default
+ sed -i -e '/udevadm hwdb/d' Makefile || die
+}
+
+_emake() {
+ emake \
+ NET=$(usex net) \
+ PCI=$(usex pci) \
+ UDEV=$(usex udev) \
+ USB=$(usex usb) \
+ "$@"
+}
+
+src_compile() {
+ _emake
+}
+
+src_install() {
+ _emake install \
+ DOCDIR="${EPREFIX}/usr/share/doc/${PF}" \
+ MISCDIR="${EPREFIX}/usr/share/misc" \
+ HWDBDIR="${EPREFIX}$(get_udevdir)/hwdb.d" \
+ DESTDIR="${D}"
+}
+
+pkg_postinst() {
+ if use udev; then
+ udevadm hwdb --update --root="${ROOT%/}"
+ fi
+}