From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id B14B8138010 for ; Fri, 14 Sep 2012 17:17:47 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id C3D20E030B; Fri, 14 Sep 2012 17:17:39 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id 8434CE030B for ; Fri, 14 Sep 2012 17:17:39 +0000 (UTC) Received: from hornbill.gentoo.org (hornbill.gentoo.org [94.100.119.163]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id CB2B733D71B for ; Fri, 14 Sep 2012 17:17:38 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by hornbill.gentoo.org (Postfix) with ESMTP id 8B523E543F for ; Fri, 14 Sep 2012 17:17:37 +0000 (UTC) From: "Zac Medico" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Zac Medico" Message-ID: <1347643042.7fdef103bb0ece06310d322456bb138f935bfbd0.zmedico@gentoo> Subject: [gentoo-commits] proj/portage:master commit in: bin/ X-VCS-Repository: proj/portage X-VCS-Files: bin/phase-helpers.sh bin/save-ebuild-env.sh X-VCS-Directories: bin/ X-VCS-Committer: zmedico X-VCS-Committer-Name: Zac Medico X-VCS-Revision: 7fdef103bb0ece06310d322456bb138f935bfbd0 X-VCS-Branch: master Date: Fri, 14 Sep 2012 17:17:37 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 62c52f9a-3ff0-4755-8de3-d1a84581e775 X-Archives-Hash: 8187c87519463369b6b623ba7ae203a6 commit: 7fdef103bb0ece06310d322456bb138f935bfbd0 Author: Zac Medico gentoo org> AuthorDate: Fri Sep 14 17:17:22 2012 +0000 Commit: Zac Medico gentoo org> CommitDate: Fri Sep 14 17:17:22 2012 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/portage.git;a=commit;h=7fdef103 Use __ prefix for _hasg, _hasgq, and _unpack_tar. --- bin/phase-helpers.sh | 20 ++++++++++---------- bin/save-ebuild-env.sh | 4 ++-- 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/bin/phase-helpers.sh b/bin/phase-helpers.sh index 6a249e1..ddc96ed 100644 --- a/bin/phase-helpers.sh +++ b/bin/phase-helpers.sh @@ -294,7 +294,7 @@ unpack() { fi [[ ! -s ${srcdir}${x} ]] && die "${x} does not exist" - _unpack_tar() { + __unpack_tar() { if [ "${y}" == "tar" ]; then $1 -c -- "$srcdir$x" | tar xof - __assert_sigpipe_ok "$myfail" @@ -324,10 +324,10 @@ unpack() { unzip -qo "${srcdir}${x}" || die "$myfail" ;; gz|Z|z) - _unpack_tar "gzip -d" + __unpack_tar "gzip -d" ;; bz2|bz) - _unpack_tar "${PORTAGE_BUNZIP2_COMMAND:-${PORTAGE_BZIP2_COMMAND} -d}" + __unpack_tar "${PORTAGE_BUNZIP2_COMMAND:-${PORTAGE_BZIP2_COMMAND} -d}" ;; 7Z|7z) local my_output @@ -374,13 +374,13 @@ unpack() { fi ;; lzma) - _unpack_tar "lzma -d" + __unpack_tar "lzma -d" ;; xz) if has $eapi 0 1 2 ; then __vecho "unpack ${x}: file format not recognized. Ignoring." else - _unpack_tar "xz -d" + __unpack_tar "xz -d" fi ;; *) @@ -400,14 +400,14 @@ econf() { [[ " ${FEATURES} " == *" force-prefix "* ]] || \ case "$EAPI" in 0|1|2) local EPREFIX= ;; esac - _hasg() { + __hasg() { local x s=$1 shift for x ; do [[ ${x} == ${s} ]] && echo "${x}" && return 0 ; done return 1 } - _hasgq() { _hasg "$@" >/dev/null ; } + __hasgq() { __hasg "$@" >/dev/null ; } local phase_func=$(__ebuild_arg_to_phase "$EAPI" "$EBUILD_PHASE") if [[ -n $phase_func ]] ; then @@ -469,9 +469,9 @@ econf() { if [[ -n ${ABI} && -n ${!LIBDIR_VAR} ]] ; then CONF_LIBDIR=${!LIBDIR_VAR} fi - if [[ -n ${CONF_LIBDIR} ]] && ! _hasgq --libdir=\* "$@" ; then - export CONF_PREFIX=$(_hasg --exec-prefix=\* "$@") - [[ -z ${CONF_PREFIX} ]] && CONF_PREFIX=$(_hasg --prefix=\* "$@") + if [[ -n ${CONF_LIBDIR} ]] && ! __hasgq --libdir=\* "$@" ; then + export CONF_PREFIX=$(__hasg --exec-prefix=\* "$@") + [[ -z ${CONF_PREFIX} ]] && CONF_PREFIX=$(__hasg --prefix=\* "$@") : ${CONF_PREFIX:=${EPREFIX}/usr} CONF_PREFIX=${CONF_PREFIX#*=} [[ ${CONF_PREFIX} != /* ]] && CONF_PREFIX="/${CONF_PREFIX}" diff --git a/bin/save-ebuild-env.sh b/bin/save-ebuild-env.sh index 3b1a1da..de8e1fb 100644 --- a/bin/save-ebuild-env.sh +++ b/bin/save-ebuild-env.sh @@ -67,13 +67,13 @@ __save_ebuild_env() { debug-print debug-print-function \ debug-print-section __helpers_die inherit EXPORT_FUNCTIONS \ nonfatal register_success_hook \ + __hasg __hasgq \ __save_ebuild_env __set_colors __filter_readonly_variables \ __preprocess_ebuild_env \ __source_all_bashrcs \ __ebuild_main __ebuild_phase __ebuild_phase_with_hooks \ __ebuild_arg_to_phase __ebuild_phase_funcs default \ - __unset_colors \ - _hasg _hasgq _unpack_tar \ + __unpack_tar __unset_colors \ ${QA_INTERCEPTORS} case "${EAPI}" in