summaryrefslogtreecommitdiffstats
path: root/bin/ebuild-helpers/prepman
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2011-11-01 19:17:19 -0700
committerZac Medico <zmedico@gentoo.org>2011-11-01 19:17:19 -0700
commit1af0c40b1300651ca03a7509f49f152c1e595736 (patch)
tree6d967ae665bf98c9ba8219fb812a9678a127a57e /bin/ebuild-helpers/prepman
parent889853171246ab1063bb5015caf41a41761f5424 (diff)
downloadportage-1af0c40b1300651ca03a7509f49f152c1e595736.tar.gz
portage-1af0c40b1300651ca03a7509f49f152c1e595736.tar.bz2
portage-1af0c40b1300651ca03a7509f49f152c1e595736.zip
Add EPREFIX and ED support in all ebuild helpers.
This allows our prefix tests to use helpers like insinto, doins, and dosym.
Diffstat (limited to 'bin/ebuild-helpers/prepman')
-rwxr-xr-xbin/ebuild-helpers/prepman10
1 files changed, 6 insertions, 4 deletions
diff --git a/bin/ebuild-helpers/prepman b/bin/ebuild-helpers/prepman
index c9add8a30..8ea7607df 100755
--- a/bin/ebuild-helpers/prepman
+++ b/bin/ebuild-helpers/prepman
@@ -4,14 +4,16 @@
source "${PORTAGE_BIN_PATH:-/usr/lib/portage/bin}"/isolated-functions.sh
+case "$EAPI" in 0|1|2) ED=${D} ;; esac
+
if [[ -z $1 ]] ; then
- mandir="${D}usr/share/man"
+ mandir="${ED}usr/share/man"
else
- mandir="${D}$1/man"
+ mandir="${ED}$1/man"
fi
if [[ ! -d ${mandir} ]] ; then
- eqawarn "QA Notice: prepman called with non-existent dir '${mandir#${D}}'"
+ eqawarn "QA Notice: prepman called with non-existent dir '${mandir#${ED}}'"
exit 0
fi
@@ -27,6 +29,6 @@ for subdir in "${mandir}"/man* "${mandir}"/*/man* ; do
[[ -d ${subdir} ]] && really_is_mandir=1 && break
done
-[[ ${really_is_mandir} == 1 ]] && exec ecompressdir --queue "${mandir#${D}}"
+[[ ${really_is_mandir} == 1 ]] && exec ecompressdir --queue "${mandir#${ED}}"
exit 0