diff options
author | Samuli Suominen <ssuominen@gentoo.org> | 2013-03-10 16:43:18 +0000 |
---|---|---|
committer | Samuli Suominen <ssuominen@gentoo.org> | 2013-03-10 16:43:18 +0000 |
commit | 83098941949c68b2e7cf1ba6facf5c8577de0fff (patch) | |
tree | 8e52bae3c0794c3b09e960cd60c496082862520a /sys-apps/hwids | |
parent | Stable for x86, wrt bug #461278 (diff) | |
download | gentoo-2-83098941949c68b2e7cf1ba6facf5c8577de0fff.tar.gz gentoo-2-83098941949c68b2e7cf1ba6facf5c8577de0fff.tar.bz2 gentoo-2-83098941949c68b2e7cf1ba6facf5c8577de0fff.zip |
Fix /etc/udev/hwdb.bin generation with >=sys-fs/udev-198 (by moving hwdb.bin out from $(DESTDIR) and updating it from pkg_postinst())
(Portage version: 2.2.0_alpha166/cvs/Linux x86_64, signed Manifest commit with key 4868F14D)
Diffstat (limited to 'sys-apps/hwids')
-rw-r--r-- | sys-apps/hwids/ChangeLog | 9 | ||||
-rw-r--r-- | sys-apps/hwids/hwids-20130309-r1.ebuild | 44 | ||||
-rw-r--r-- | sys-apps/hwids/hwids-99999999.ebuild | 8 |
3 files changed, 59 insertions, 2 deletions
diff --git a/sys-apps/hwids/ChangeLog b/sys-apps/hwids/ChangeLog index ac2c3e41714a..7d03967992a1 100644 --- a/sys-apps/hwids/ChangeLog +++ b/sys-apps/hwids/ChangeLog @@ -1,6 +1,13 @@ # ChangeLog for sys-apps/hwids # Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/sys-apps/hwids/ChangeLog,v 1.91 2013/03/10 16:03:10 ssuominen Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-apps/hwids/ChangeLog,v 1.92 2013/03/10 16:43:18 ssuominen Exp $ + +*hwids-20130309-r1 (10 Mar 2013) + + 10 Mar 2013; Samuli Suominen <ssuominen@gentoo.org> + +hwids-20130309-r1.ebuild, hwids-99999999.ebuild: + Fix /etc/udev/hwdb.bin generation with >=sys-fs/udev-198 (by moving hwdb.bin + out from $(DESTDIR) and updating it from pkg_postinst()) 10 Mar 2013; Samuli Suominen <ssuominen@gentoo.org> hwids-20130309.ebuild, hwids-99999999.ebuild: diff --git a/sys-apps/hwids/hwids-20130309-r1.ebuild b/sys-apps/hwids/hwids-20130309-r1.ebuild new file mode 100644 index 000000000000..247561fae40c --- /dev/null +++ b/sys-apps/hwids/hwids-20130309-r1.ebuild @@ -0,0 +1,44 @@ +# Copyright 1999-2013 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/sys-apps/hwids/hwids-20130309-r1.ebuild,v 1.1 2013/03/10 16:43:18 ssuominen Exp $ + +EAPI=5 +inherit udev eutils + +DESCRIPTION="Hardware (PCI, USB, OUI, IAB) IDs databases" +HOMEPAGE="https://github.com/gentoo/hwids" +SRC_URI="https://github.com/gentoo/hwids/archive/${P}.tar.gz" + +LICENSE="|| ( GPL-2 BSD ) public-domain" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~x64-freebsd ~amd64-linux ~arm-linux ~x86-linux" +IUSE="+udev" + +DEPEND="udev? ( + dev-lang/perl + >=virtual/udev-197-r1 +)" +RDEPEND="!<sys-apps/pciutils-3.1.9-r2 + !<sys-apps/usbutils-005-r1" + +S=${WORKDIR}/hwids-${P} + +src_prepare() { + sed -i -e '/udevadm hwdb/d' Makefile || die +} + +src_compile() { + emake UDEV=$(usex udev) +} + +src_install() { + emake UDEV=$(usex udev) install \ + DOCDIR="${EPREFIX}/usr/share/doc/${PF}" \ + MISCDIR="${EPREFIX}/usr/share/misc" \ + HWDBDIR="${EPREFIX}$(get_udevdir)/hwdb.d" \ + DESTDIR="${D}" +} + +pkg_postinst() { + use udev && udevadm hwdb --update --root="${ROOT%/}" +} diff --git a/sys-apps/hwids/hwids-99999999.ebuild b/sys-apps/hwids/hwids-99999999.ebuild index 57efca120972..b1563ab6fcf8 100644 --- a/sys-apps/hwids/hwids-99999999.ebuild +++ b/sys-apps/hwids/hwids-99999999.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2013 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/sys-apps/hwids/hwids-99999999.ebuild,v 1.19 2013/03/10 16:03:10 ssuominen Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-apps/hwids/hwids-99999999.ebuild,v 1.20 2013/03/10 16:43:18 ssuominen Exp $ EAPI=5 inherit udev eutils git-2 @@ -24,6 +24,8 @@ RDEPEND="!<sys-apps/pciutils-3.1.9-r2 src_prepare() { emake fetch + + sed -i -e '/udevadm hwdb/d' Makefile || die } src_compile() { @@ -37,3 +39,7 @@ src_install() { HWDBDIR="${EPREFIX}$(get_udevdir)/hwdb.d" \ DESTDIR="${D}" } + +pkg_postinst() { + use udev && udevadm hwdb --update --root="${ROOT%/}" +} |