diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2017-12-03 16:17:22 +0000 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2017-12-03 16:17:22 +0000 |
commit | 4cd2370bed609c118b6edfde5d3f116e5c35b897 (patch) | |
tree | ec58f2c41f49754e41521d5ebc9dce4597ddd0a5 /sys-apps/x86info/x86info-1.30.ebuild | |
parent | f443475c824b4b5c086e6d040961cb35ad81bc60 (diff) |
gentoo resync : 03.12.2017
Diffstat (limited to 'sys-apps/x86info/x86info-1.30.ebuild')
-rw-r--r-- | sys-apps/x86info/x86info-1.30.ebuild | 61 |
1 files changed, 36 insertions, 25 deletions
diff --git a/sys-apps/x86info/x86info-1.30.ebuild b/sys-apps/x86info/x86info-1.30.ebuild index 7ef0bfa3f20b..358f453ebbbe 100644 --- a/sys-apps/x86info/x86info-1.30.ebuild +++ b/sys-apps/x86info/x86info-1.30.ebuild @@ -1,9 +1,11 @@ -# Copyright 1999-2012 Gentoo Foundation +# Copyright 1999-2017 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -EAPI=2 +EAPI=6 -inherit eutils flag-o-matic linux-info toolchain-funcs +PYTHON_COMPAT=( python2_7 ) + +inherit flag-o-matic linux-info python-any-r1 toolchain-funcs DESCRIPTION="Dave Jones' handy, informative x86 CPU diagnostic utility" HOMEPAGE="http://www.codemonkey.org.uk/projects/x86info/" @@ -14,48 +16,57 @@ SLOT="0" KEYWORDS="-* amd64 x86" IUSE="" -RDEPEND="sys-apps/pciutils" -DEPEND="${RDEPEND}" +RDEPEND="sys-apps/pciutils:=" +DEPEND=" + ${PYTHON_DEPS} + ${RDEPEND}" CONFIG_CHECK="~MTRR ~X86_CPUID" -src_prepare() { - epatch "${FILESDIR}"/1.21-pic.patch - epatch "${FILESDIR}"/${PN}-1.24-pic.patch #270388 - epatch "${FILESDIR}"/${PN}-1.29-parallel-make-cleanup.patch +PATCHES=( + "${FILESDIR}"/1.21-pic.patch + "${FILESDIR}"/${PN}-1.24-pic.patch #270388 + "${FILESDIR}"/${PN}-1.29-parallel-make-cleanup.patch + "${FILESDIR}"/${PN}-1.30-fix-build-system.patch +) + +pkg_setup() { + linux-info_pkg_setup + python-any-r1_pkg_setup } -src_compile() { +src_configure() { # These flags taken from the 1.29 ebuild - append-flags -Wall -Wshadow -Wextra -Wmissing-declarations -Wdeclaration-after-statement -Wredundant-decls + append-flags -Wall -Wshadow -Wextra -Wmissing-declarations \ + -Wdeclaration-after-statement -Wredundant-decls append-ldflags -Wl,-z,relro,-z,now - emake x86info lsmsr \ - CC="$(tc-getCC)" \ - CFLAGS="${CFLAGS} ${CPPFLAGS}" \ - LDFLAGS="${LDFLAGS}" \ - || die "emake failed" + + tc-export CC +} + +src_compile() { + emake x86info lsmsr } src_install() { - dobin x86info lsmsr || die + dobin x86info lsmsr insinto /etc/modprobe.d newins "${FILESDIR}"/x86info-modules.conf-rc x86info.conf - dodoc TODO README + einstalldocs doman x86info.1 lsmsr.8 - insinto /usr/share/doc/${PF} - doins -r results - prepalldocs + + dodoc -r results } pkg_preinst() { - if [ -a "${ROOT}"/etc/modules.d/x86info ] && [ ! -a "${ROOT}"/etc/modprobe.d/x86info ] ; then + if [[ -a "${EROOT%/}"/etc/modules.d/x86info ]] && [[ ! -a "${EROOT%/}"/etc/modprobe.d/x86info ]]; then elog "Moving x86info from /etc/modules.d/ to /etc/modprobe.d/" - mv "${ROOT}"/etc/{modules,modprobe}.d/x86info + mv "${EROOT%/}"/etc/{modules,modprobe}.d/x86info fi - if [ -a "${ROOT}"/etc/modprobe.d/x86info ] && [ ! -a "${ROOT}"/etc/modprobe.d/x86info.conf ] ; then + if [[ -a "${EROOT%/}"/etc/modprobe.d/x86info ]] && [[ ! -a "${EROOT%/}"/etc/modprobe.d/x86info.conf ]]; then elog "Adding .conf suffix to x86info in /etc/modprobe.d/" - mv "${ROOT}"/etc/modprobe.d/x86info{,.conf} + mv "${EROOT%/}"/etc/modprobe.d/x86info{,.conf} fi } |