summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGuilherme Amadio <amadio@gentoo.org>2018-03-19 23:09:28 +0100
committerGuilherme Amadio <amadio@gentoo.org>2018-03-22 15:23:28 +0100
commitbcec6d270db805b7a0dce828090e52b6df106f3e (patch)
treeb05408bcc6fef9d4f9b2a8975f7613928e36e50a /sys-apps/man
parentsci-libs/gdal: find json-c from EPREFIX (diff)
downloadgentoo-bcec6d270db805b7a0dce828090e52b6df106f3e.tar.gz
gentoo-bcec6d270db805b7a0dce828090e52b6df106f3e.tar.bz2
gentoo-bcec6d270db805b7a0dce828090e52b6df106f3e.zip
sys-apps/man: prefix support
Package-Manager: Portage-2.3.24, Repoman-2.3.6
Diffstat (limited to 'sys-apps/man')
-rw-r--r--sys-apps/man/man-1.6g-r1.ebuild23
1 files changed, 17 insertions, 6 deletions
diff --git a/sys-apps/man/man-1.6g-r1.ebuild b/sys-apps/man/man-1.6g-r1.ebuild
index 7d91bb1345a0..1a296cf7f7f5 100644
--- a/sys-apps/man/man-1.6g-r1.ebuild
+++ b/sys-apps/man/man-1.6g-r1.ebuild
@@ -3,7 +3,7 @@
EAPI="4"
-inherit eutils toolchain-funcs user
+inherit eutils prefix toolchain-funcs user
DESCRIPTION="Standard commands to read man pages"
HOMEPAGE="http://primates.ximian.com/~flucifredi/man/"
@@ -64,13 +64,24 @@ src_configure() {
fi
export COMPRESS
if use lzma ; then
- COMPRESS=/usr/bin/xz
+ COMPRESS="${EPREFIX}"/usr/bin/xz
else
- COMPRESS=/bin/bzip2
+ COMPRESS="${EPREFIX}"/bin/bzip2
fi
+
+ if [[ -n ${EPREFIX} ]]; then
+ hprefixify configure || die
+ sed -i \
+ -e "s/man_user=root/man_user=$(id -u)/" \
+ -e "s/man_group=man/man_group=$(id -g)/" \
+ configure || die "Failed to disable suid/sgid options for man"
+ sed -i -e 's:/usr/bin:@bindir@:' man2html/Makefile.in || die
+ fi
+
echoit \
./configure \
- -confdir=/etc \
+ -bindir="${EPREFIX}"/usr/bin \
+ -confdir="${EPREFIX}"/etc \
+sgid +fhs \
+lang ${mylang} \
|| die "configure failed"
@@ -89,8 +100,8 @@ src_install() {
newexe "${FILESDIR}"/makewhatis.cron makewhatis
keepdir /var/cache/man
- diropts -m0775 -g man
- local mansects=$(grep ^MANSECT "${D}"/etc/man.conf | cut -f2-)
+ [[ -z ${EPREFIX} ]] && diropts -m0775 -g man
+ local mansects=$(grep ^MANSECT "${ED}"/etc/man.conf | cut -f2-)
for x in ${mansects//:/ } ; do
keepdir /var/cache/man/cat${x}
done