+++ /dev/null
-#!/bin/bash
-# Copyright 2009 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-die "'${0##*/}' has been banned for EAPI '$EAPI'"
-exit 1
+++ /dev/null
-../doins
\ No newline at end of file
+++ /dev/null
-../../banned-helper
\ No newline at end of file
+++ /dev/null
-../../banned-helper
\ No newline at end of file
+++ /dev/null
-../../banned-helper
\ No newline at end of file
#!/bin/bash
-# Copyright 1999-2011 Gentoo Foundation
+# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
+case "${EAPI}" in
+ 0|1|2|3)
+ ;;
+ *)
+ exec \
+ env \
+ __PORTAGE_HELPER="dodoc" \
+ doins "$@"
+ ;;
+esac
+
source "${PORTAGE_BIN_PATH:-/usr/lib/portage/bin}"/isolated-functions.sh
if [ $# -lt 1 ] ; then
#!/bin/bash
-# Copyright 1999-2011 Gentoo Foundation
+# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
+case "${EAPI}" in
+ 0|1|2|3)
+ ;;
+ *)
+ die "'${0##*/}' has been banned for EAPI '$EAPI'"
+ exit 1
+ ;;
+esac
+
if [[ $# -ne 2 ]] ; then
echo "$0: two arguments needed" 1>&2
exit 1
source "${PORTAGE_BIN_PATH:-/usr/lib/portage/bin}"/isolated-functions.sh
-if [[ ${0##*/} == dodoc ]] ; then
+helper=${__PORTAGE_HELPER:-${0##*/}}
+
+if [[ ${helper} == dodoc ]] ; then
if [ $# -eq 0 ] ; then
# default_src_install may call dodoc with no arguments
# when DOC is defined but empty, so simply return
fi
if [ $# -lt 1 ] ; then
- helpers_die "${0##*/}: at least one argument needed"
+ helpers_die "${helper}: at least one argument needed"
exit 1
fi
vecho "You should not use \${D} or \${ED} with helpers." 1>&2
vecho " --> ${INSDESTTREE}" 1>&2
vecho "-------------------------------------------------------" 1>&2
- helpers_die "${0##*/} used with \${D} or \${ED}"
+ helpers_die "${helper} used with \${D} or \${ED}"
exit 1
fi
install ${INSOPTIONS} "${mysrc}" "${ED}${INSDESTTREE}/${mydir}"
rval=$?
[[ -n ${cleanup} ]] && rm -f "${cleanup}"
- [ $rval -ne 0 ] && echo "!!! ${0##*/}: $mysrc does not exist" 1>&2
+ [ $rval -ne 0 ] && echo "!!! ${helper}: $mysrc does not exist" 1>&2
return $rval
}
if [[ $PRESERVE_SYMLINKS = n && -d $x ]] || \
[[ $PRESERVE_SYMLINKS = y && -d $x && ! -L $x ]] ; then
if [ "${DOINSRECUR}" == "n" ] ; then
- if [[ ${0##*/} == dodoc ]] ; then
- echo "!!! ${0##*/}: $x is a directory" 1>&2
+ if [[ ${helper} == dodoc ]] ; then
+ echo "!!! ${helper}: $x is a directory" 1>&2
((failed|=1))
fi
continue
fi
done
rm -rf "$TMP"
-[[ $failed -ne 0 || $success -eq 0 ]] && { helpers_die "${0##*/} failed"; exit 1; } || exit 0
+[[ $failed -ne 0 || $success -eq 0 ]] && { helpers_die "${helper} failed"; exit 1; } || exit 0
#!/bin/bash
-# Copyright 1999-2011 Gentoo Foundation
+# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
+case "${EAPI}" in
+ 0|1|2|3)
+ ;;
+ *)
+ die "'${0##*/}' has been banned for EAPI '$EAPI'"
+ exit 1
+ ;;
+esac
+
if [[ $# -lt 1 ]] ; then
echo "!!! ${0##*/}: at least one argument needed" >&2
exit 1
#!/bin/bash
-# Copyright 1999-2011 Gentoo Foundation
+# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
source "${PORTAGE_BIN_PATH:-/usr/lib/portage/bin}"/isolated-functions.sh
+case "${EAPI}" in
+ 0|1|2|3)
+ ;;
+ *)
+ die "'${0##*/}' has been banned for EAPI '$EAPI'"
+ exit 1
+ ;;
+esac
+
if [[ -n $1 ]] ; then
vecho "${0##*/}: invalid usage; takes no arguments" 1>&2
fi
PORTAGE_TMPDIR PORTAGE_UPDATE_ENV PORTAGE_USERNAME \
PORTAGE_VERBOSE PORTAGE_WORKDIR_MODE PORTDIR PORTDIR_OVERLAY \
PROFILE_PATHS REPLACING_VERSIONS REPLACED_BY_VERSION T WORKDIR \
- __PORTAGE_TEST_HARDLINK_LOCKS"
+ __PORTAGE_HELPER __PORTAGE_TEST_HARDLINK_LOCKS"
PORTAGE_SAVED_READONLY_VARS="A CATEGORY P PF PN PR PV PVR"
"RESUMECOMMAND_HTTP", "RESUMECOMMAND_HTTPS",
"RESUMECOMMAND_RSYNC", "RESUMECOMMAND_SFTP",
"SYNC", "UNINSTALL_IGNORE", "USE_EXPAND_HIDDEN", "USE_ORDER",
+ "__PORTAGE_HELPER"
]
environ_filter = frozenset(environ_filter)
path = []
- if eapi not in (None, "0", "1", "2", "3"):
- path.append(os.path.join(portage_bin_path, "ebuild-helpers", "4"))
-
path.append(os.path.join(portage_bin_path, "ebuild-helpers"))
path.extend(prerootpath)