diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2021-06-15 14:57:03 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2021-06-15 14:57:03 +0100 |
commit | d18bf1e01b65ee4bf0c804e2843b282d3d4e5d7c (patch) | |
tree | 4a95cbc6ffdf13bad6ecbc7f8d5af99631984123 /sys-apps/ppc64-diag/ppc64-diag-2.7.7.ebuild | |
parent | e748ba9741f6540f4675c23e3e37b73e822c13a4 (diff) |
gentoo resync : 15.06.2021
Diffstat (limited to 'sys-apps/ppc64-diag/ppc64-diag-2.7.7.ebuild')
-rw-r--r-- | sys-apps/ppc64-diag/ppc64-diag-2.7.7.ebuild | 73 |
1 files changed, 73 insertions, 0 deletions
diff --git a/sys-apps/ppc64-diag/ppc64-diag-2.7.7.ebuild b/sys-apps/ppc64-diag/ppc64-diag-2.7.7.ebuild new file mode 100644 index 000000000000..9c94baecc1f4 --- /dev/null +++ b/sys-apps/ppc64-diag/ppc64-diag-2.7.7.ebuild @@ -0,0 +1,73 @@ +# Copyright 2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit autotools toolchain-funcs + +DESCRIPTION="Diagnostic tools for PowerLinux" +HOMEPAGE="https://github.com/power-ras/ppc64-diag" +SRC_URI="https://github.com/power-ras/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" + +LICENSE="GPL-2+" +SLOT="0" +KEYWORDS="~ppc64" +IUSE="rtas" + +DEPEND="virtual/libudev:= + rtas? ( + sys-libs/ncurses:0= + sys-libs/librtas + sys-libs/libservicelog + sys-libs/libvpd + ) +" + +RDEPEND="${DEPEND}" + +BDEPEND=" + sys-devel/bison + sys-devel/flex + virtual/pkgconfig +" + +PATCHES=( + "${FILESDIR}"/fix-systemd-unit-path.patch +) + +src_prepare() { + default + eautoreconf +} + +src_configure() { + econf $(use_with rtas librtas) + # handle ncurses[tinfo] + sed -e "s:-lncurses:$($(tc-getPKG_CONFIG) --libs ncurses):g" \ + -i Makefile || die +} + +src_install() { + default + newinitd "${FILESDIR}/opal_errd.initd" opal_errd + + if use rtas; then + newinitd "${FILESDIR}/rtas_errd.initd" rtas_errd + keepdir /var/log/ppc64-diag/diag_disk + else + # makefile installs it unconditionally + rm -rf "${ED}/lib/systemd/system/rtas_errd.service" || die + rm -rf "${ED}/usr/lib/systemd/system/rtas_errd.service" || die + fi + + keepdir /var/log/opal-elog + keepdir /var/log/dump +} + +src_test() { + # it assumes MKTEMP created dir in /tmp, add /var to the string. + # /varplatform.0x01 becomes platform.0x01, just as test expects + # so we sed a sed expression, don't judge me + sed -i 's%\/tmp/%\/var\/tmp\/%' opal_errd/tests/test-extract_opal_dump-000 || die + emake check +} |