aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2009-10-02 20:58:33 +0100
committerAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2009-10-02 20:58:33 +0100
commit22704059e8bd02b958981d642d43f561315f39ce (patch)
treec9453d7623dc7375f43d32de49e692141ed8ec7c
parent70d3c637576ef388d35376f17030b37cf4b7767f (diff)
downloadpaludis-22704059e8bd02b958981d642d43f561315f39ce.tar.gz
paludis-22704059e8bd02b958981d642d43f561315f39ce.tar.xz
strip is only bad in install (thanks gcc...)
-rwxr-xr-xpaludis/repositories/e/ebuild/utils/exheres-0/strip15
1 files changed, 14 insertions, 1 deletions
diff --git a/paludis/repositories/e/ebuild/utils/exheres-0/strip b/paludis/repositories/e/ebuild/utils/exheres-0/strip
index c516514..8686b47 100755
--- a/paludis/repositories/e/ebuild/utils/exheres-0/strip
+++ b/paludis/repositories/e/ebuild/utils/exheres-0/strip
@@ -19,5 +19,18 @@
source "${PALUDIS_EBUILD_DIR}"/die_functions.bash
-paludis_die_or_error "caught a naughty build system doing 'strip $@'"
+if [[ "${!PALUDIS_EBUILD_PHASE_VAR}" == "install" ]] ; then
+ # autoconf likes to call 'strip' even if it won't use it
+ paludis_die_or_error "caught a naughty build system doing 'strip $@'"
+fi
+
+new_path=
+IFS=':'
+for p in ${PATH} ; do
+ [[ "$(canonicalise $(dirname ${0} ) )" == "$(canonicalise ${p} )" ]] && continue
+ new_path="${new_path:+${new_path}:}${p}"
+done
+
+export PATH="${new_path}"
+exec install "$@"