From 4645b6f17f0da81e9fe84081fb126a37102ba153 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Tue, 8 May 2018 14:01:34 +0100 Subject: gentoo resync : 08.05.2018 --- eclass/Manifest.gz | Bin 38915 -> 38891 bytes eclass/bash-completion-r1.eclass | 4 ++-- eclass/cron.eclass | 4 ++-- eclass/distutils-r1.eclass | 25 ++++++++++++++--------- eclass/fcaps.eclass | 2 +- eclass/git-r3.eclass | 39 ++++++++++++++++++++++++----------- eclass/mercurial.eclass | 9 ++++++-- eclass/multibuild.eclass | 4 ++-- eclass/multilib-build.eclass | 22 ++++++++++---------- eclass/multilib-minimal.eclass | 4 ++-- eclass/ninja-utils.eclass | 4 ++-- eclass/out-of-source.eclass | 4 ++-- eclass/python-any-r1.eclass | 4 ++-- eclass/python-r1.eclass | 4 ++-- eclass/python-single-r1.eclass | 4 ++-- eclass/python-utils-r1.eclass | 43 ++++++++++++++++++++++++--------------- eclass/ruby-fakegem.eclass | 10 ++++++++- eclass/scons-utils.eclass | 13 ++++++++---- 18 files changed, 124 insertions(+), 75 deletions(-) (limited to 'eclass') diff --git a/eclass/Manifest.gz b/eclass/Manifest.gz index 3674221406d4..49abf87ea2de 100644 Binary files a/eclass/Manifest.gz and b/eclass/Manifest.gz differ diff --git a/eclass/bash-completion-r1.eclass b/eclass/bash-completion-r1.eclass index eb2dfce4c7fe..eff5e68c437e 100644 --- a/eclass/bash-completion-r1.eclass +++ b/eclass/bash-completion-r1.eclass @@ -1,4 +1,4 @@ -# Copyright 1999-2014 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # @ECLASS: bash-completion-r1.eclass @@ -25,7 +25,7 @@ inherit toolchain-funcs case ${EAPI:-0} in - 0|1|2|3|4|5|6) ;; + 0|1|2|3|4|5|6|7) ;; *) die "EAPI ${EAPI} unsupported (yet)." esac diff --git a/eclass/cron.eclass b/eclass/cron.eclass index 3ff996609b7f..d40bc62cdfe4 100644 --- a/eclass/cron.eclass +++ b/eclass/cron.eclass @@ -1,4 +1,4 @@ -# Copyright 1999-2011 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # @ECLASS: cron.eclass @@ -155,6 +155,6 @@ cron_pkg_postinst() { einfo "You may wish to read the Gentoo Linux Cron Guide, which can be" einfo "found online at:" - einfo " https://www.gentoo.org/doc/en/cron-guide.xml" + einfo " https://wiki.gentoo.org/wiki/Cron" echo } diff --git a/eclass/distutils-r1.eclass b/eclass/distutils-r1.eclass index dd0c429d50fc..975383acc09b 100644 --- a/eclass/distutils-r1.eclass +++ b/eclass/distutils-r1.eclass @@ -1,4 +1,4 @@ -# Copyright 1999-2017 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # @ECLASS: distutils-r1.eclass @@ -46,7 +46,7 @@ case "${EAPI:-0}" in 0|1|2|3|4) die "Unsupported EAPI=${EAPI:-0} (too old) for ${ECLASS}" ;; - 5|6) + 5|6|7) ;; *) die "Unsupported EAPI=${EAPI} (unknown) for ${ECLASS}" @@ -79,7 +79,8 @@ esac if [[ ! ${_DISTUTILS_R1} ]]; then [[ ${EAPI} == [45] ]] && inherit eutils -inherit toolchain-funcs xdg-utils +[[ ${EAPI} == [56] ]] && inherit xdg-utils +inherit toolchain-funcs if [[ ! ${DISTUTILS_SINGLE_IMPL} ]]; then inherit multiprocessing python-r1 @@ -97,7 +98,11 @@ if [[ ! ${_DISTUTILS_R1} ]]; then if [[ ! ${DISTUTILS_OPTIONAL} ]]; then RDEPEND=${PYTHON_DEPS} - DEPEND=${PYTHON_DEPS} + if [[ ${EAPI} != [56] ]]; then + BDEPEND=${PYTHON_DEPS} + else + DEPEND=${PYTHON_DEPS} + fi REQUIRED_USE=${PYTHON_REQUIRED_USE} fi @@ -230,7 +235,7 @@ fi # @USAGE: [...] # @DESCRIPTION: # Run setup.py using currently selected Python interpreter -# (if ${PYTHON} is set; fallback 'python' otherwise). +# (if ${EPYTHON} is set; fallback 'python' otherwise). # # setup.py will be passed the following, in order: # 1. ${mydistutilsargs[@]} @@ -249,7 +254,7 @@ esetup.py() { [[ ${BUILD_DIR} ]] && _distutils-r1_create_setup_cfg - set -- "${PYTHON:-python}" setup.py "${mydistutilsargs[@]}" "${@}" + set -- "${EPYTHON:-python}" setup.py "${mydistutilsargs[@]}" "${@}" echo "${@}" >&2 "${@}" || die "${die_args[@]}" @@ -412,7 +417,7 @@ _distutils-r1_create_setup_cfg() { [install] compile = True optimize = 2 - root = ${D} + root = ${D%/} _EOF_ if [[ ! ${DISTUTILS_SINGLE_IMPL} ]]; then @@ -582,7 +587,7 @@ distutils-r1_python_install() { if [[ ! ${DISTUTILS_SINGLE_IMPL} ]]; then _distutils-r1_wrap_scripts "${root}" "${scriptdir}" - multibuild_merge_root "${root}" "${D}" + multibuild_merge_root "${root}" "${D%/}" fi } @@ -739,7 +744,7 @@ distutils-r1_src_prepare() { distutils-r1_src_configure() { python_export_utf8_locale - xdg_environment_reset # Bug 577704 + [[ ${EAPI} == [56] ]] && xdg_environment_reset # Bug 577704 if declare -f python_configure >/dev/null; then _distutils-r1_run_foreach_impl python_configure @@ -797,7 +802,7 @@ _distutils-r1_check_namespace_pth() { while IFS= read -r -d '' f; do pth+=( "${f}" ) - done < <(find "${ED}" -name '*-nspkg.pth' -print0) + done < <(find "${ED%/}" -name '*-nspkg.pth' -print0) if [[ ${pth[@]} ]]; then ewarn "The following *-nspkg.pth files were found installed:" diff --git a/eclass/fcaps.eclass b/eclass/fcaps.eclass index a8b9c1f1b816..7b388849df60 100644 --- a/eclass/fcaps.eclass +++ b/eclass/fcaps.eclass @@ -11,7 +11,7 @@ # often via packages like libcap. # # Due to probable capability-loss on moving or copying, this happens in -# pkg_postinst-phase (at least for now). +# pkg_postinst phase (at least for now). # # @EXAMPLE: # You can manually set the caps on ping and ping6 by doing: diff --git a/eclass/git-r3.eclass b/eclass/git-r3.eclass index 75a589d0168d..279f03269314 100644 --- a/eclass/git-r3.eclass +++ b/eclass/git-r3.eclass @@ -1,4 +1,4 @@ -# Copyright 1999-2017 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # @ECLASS: git-r3.eclass @@ -10,7 +10,7 @@ # git as remote repository. case "${EAPI:-0}" in - 0|1|2|3|4|5|6) + 0|1|2|3|4|5|6|7) ;; *) die "Unsupported EAPI=${EAPI} (unknown) for ${ECLASS}" @@ -22,7 +22,11 @@ EXPORT_FUNCTIONS src_unpack if [[ ! ${_GIT_R3} ]]; then if [[ ! ${_INHERITED_BY_GIT_2} ]]; then - DEPEND=">=dev-vcs/git-1.8.2.1" + if [[ ${EAPI:-0} != [0123456] ]]; then + BDEPEND=">=dev-vcs/git-1.8.2.1" + else + DEPEND=">=dev-vcs/git-1.8.2.1" + fi fi # @ECLASS-VARIABLE: EGIT_CLONE_TYPE @@ -648,16 +652,27 @@ git-r3_fetch() { local clone_type=${EGIT_CLONE_TYPE} if [[ ${r} == http://* || ${r} == https://* ]] && - [[ ! ${EGIT_CURL_WARNED} ]] && - ! ROOT=/ has_version 'dev-vcs/git[curl]' + [[ ! ${EGIT_CURL_WARNED} ]] then - ewarn "git-r3: fetching from HTTP(S) requested. In order to support HTTP(S)," - ewarn "dev-vcs/git needs to be built with USE=curl. Example solution:" - ewarn - ewarn " echo dev-vcs/git curl >> /etc/portage/package.use" - ewarn " emerge -1v dev-vcs/git" - ewarn - ewarn "HTTP(S) URIs will be skipped." + case ${EAPI:-0} in + 0|1|2|3|4) + ROOT=/ has_version 'dev-vcs/git[curl]';; + 5|6) + has_version --host-root 'dev-vcs/git[curl]';; + *) + has_version -b 'dev-vcs/git[curl]';; + esac + + if [[ ${?} -ne 0 ]]; then + ewarn "git-r3: fetching from HTTP(S) requested. In order to support HTTP(S)," + ewarn "dev-vcs/git needs to be built with USE=curl. Example solution:" + ewarn + ewarn " echo dev-vcs/git curl >> /etc/portage/package.use" + ewarn " emerge -1v dev-vcs/git" + ewarn + ewarn "HTTP(S) URIs will be skipped." + fi + EGIT_CURL_WARNED=1 fi diff --git a/eclass/mercurial.eclass b/eclass/mercurial.eclass index ad3102b7590d..9a5bd191c231 100644 --- a/eclass/mercurial.eclass +++ b/eclass/mercurial.eclass @@ -57,15 +57,19 @@ DEPEND="dev-vcs/mercurial" : ${EHG_QUIET:="OFF"} [[ "${EHG_QUIET}" == "ON" ]] && EHG_QUIET_CMD_OPT="--quiet" +# @ECLASS-VARIABLE: EHG_CONFIG +# @DESCRIPTION: +# Extra config option to hand to hg clone/pull + # @ECLASS-VARIABLE: EHG_CLONE_CMD # @DESCRIPTION: # Command used to perform initial repository clone. -[[ -z "${EHG_CLONE_CMD}" ]] && EHG_CLONE_CMD="hg clone ${EHG_QUIET_CMD_OPT} --pull --noupdate" +[[ -z "${EHG_CLONE_CMD}" ]] && EHG_CLONE_CMD="hg clone ${EHG_CONFIG:+--config ${EHG_CONFIG}} ${EHG_QUIET_CMD_OPT} --pull --noupdate" # @ECLASS-VARIABLE: EHG_PULL_CMD # @DESCRIPTION: # Command used to update repository. -[[ -z "${EHG_PULL_CMD}" ]] && EHG_PULL_CMD="hg pull ${EHG_QUIET_CMD_OPT}" +[[ -z "${EHG_PULL_CMD}" ]] && EHG_PULL_CMD="hg pull ${EHG_CONFIG:+--config ${EHG_CONFIG}} ${EHG_QUIET_CMD_OPT}" # @ECLASS-VARIABLE: EHG_OFFLINE # @DESCRIPTION: @@ -134,6 +138,7 @@ mercurial_fetch() { hg clone \ ${EHG_QUIET_CMD_OPT} \ --updaterev="${EHG_REVISION}" \ + ${EHG_CONFIG:+--config ${EHG_CONFIG}} \ "${EHG_STORE_DIR}/${EHG_PROJECT}/${module}" \ "${sourcedir}" || die "hg clone failed" # An exact revision helps a lot for testing purposes, so have some output... diff --git a/eclass/multibuild.eclass b/eclass/multibuild.eclass index 0f89e4ec0b83..9574e3debadb 100644 --- a/eclass/multibuild.eclass +++ b/eclass/multibuild.eclass @@ -1,4 +1,4 @@ -# Copyright 1999-2014 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # @ECLASS: multibuild.eclass @@ -16,7 +16,7 @@ case "${EAPI:-0}" in 0|1|2|3) die "Unsupported EAPI=${EAPI:-0} (too old) for ${ECLASS}" ;; - 4|5|6) + 4|5|6|7) ;; *) die "Unsupported EAPI=${EAPI} (unknown) for ${ECLASS}" diff --git a/eclass/multilib-build.eclass b/eclass/multilib-build.eclass index 6356350c43b3..261f0f4a170b 100644 --- a/eclass/multilib-build.eclass +++ b/eclass/multilib-build.eclass @@ -1,4 +1,4 @@ -# Copyright 1999-2015 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # @ECLASS: multilib-build.eclass @@ -20,7 +20,7 @@ if [[ ! ${_MULTILIB_BUILD} ]]; then # EAPI=4 is required for meaningful MULTILIB_USEDEP. case ${EAPI:-0} in - 4|5|6) ;; + 4|5|6|7) ;; *) die "EAPI=${EAPI} is not supported" ;; esac @@ -269,8 +269,8 @@ multilib_check_headers() { _multilib_header_cksum() { set -o pipefail - if [[ -d ${ED}usr/include ]]; then - find "${ED}"usr/include -type f \ + if [[ -d ${ED%/}/usr/include ]]; then + find "${ED%/}"/usr/include -type f \ -exec cksum {} + | sort -k2 fi } @@ -390,7 +390,7 @@ multilib_prepare_wrappers() { [[ ${#} -le 1 ]] || die "${FUNCNAME}: too many arguments" - local root=${1:-${ED}} + local root=${1:-${ED%/}} local f if [[ ${COMPLETE_MULTILIB} == yes ]]; then @@ -458,9 +458,9 @@ multilib_prepare_wrappers() { # Some ABIs may have install less files than others. if [[ -f ${root}/usr/include${f} ]]; then - local wrapper=${ED}/tmp/multilib-include${f} + local wrapper=${ED%/}/tmp/multilib-include${f} - if [[ ! -f ${ED}/tmp/multilib-include${f} ]]; then + if [[ ! -f ${ED%/}/tmp/multilib-include${f} ]]; then dodir "/tmp/multilib-include${dir}" # a generic template cat > "${wrapper}" <<_EOF_ || die @@ -518,7 +518,7 @@ _EOF_ # $CHOST shall be set by multilib_toolchain_setup dodir "/tmp/multilib-include/${CHOST}${dir}" - mv "${root}/usr/include${f}" "${ED}/tmp/multilib-include/${CHOST}${dir}/" || die + mv "${root}/usr/include${f}" "${ED%/}/tmp/multilib-include/${CHOST}${dir}/" || die # Note: match a space afterwards to avoid collision potential. sed -e "/${MULTILIB_ABI_FLAG} /s&error.*&include <${CHOST}${f}>&" \ @@ -558,11 +558,11 @@ multilib_install_wrappers() { local root=${1:-${ED}} - if [[ -d "${ED}"/tmp/multilib-include ]]; then + if [[ -d ${ED%/}/tmp/multilib-include ]]; then multibuild_merge_root \ - "${ED}"/tmp/multilib-include "${root}"/usr/include + "${ED%/}"/tmp/multilib-include "${root}"/usr/include # it can fail if something else uses /tmp - rmdir "${ED}"/tmp &>/dev/null + rmdir "${ED%/}"/tmp &>/dev/null fi } diff --git a/eclass/multilib-minimal.eclass b/eclass/multilib-minimal.eclass index de46762ca61a..ae40eeb25895 100644 --- a/eclass/multilib-minimal.eclass +++ b/eclass/multilib-minimal.eclass @@ -1,4 +1,4 @@ -# Copyright 1999-2014 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # @ECLASS: multilib-minimal.eclass @@ -24,7 +24,7 @@ # EAPI=4 is required for meaningful MULTILIB_USEDEP. case ${EAPI:-0} in - 4|5|6) ;; + 4|5|6|7) ;; *) die "EAPI=${EAPI} is not supported" ;; esac diff --git a/eclass/ninja-utils.eclass b/eclass/ninja-utils.eclass index 69216176ba61..0a390ed89612 100644 --- a/eclass/ninja-utils.eclass +++ b/eclass/ninja-utils.eclass @@ -1,4 +1,4 @@ -# Copyright 1999-2017 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # @ECLASS: ninja-utils.eclass @@ -22,7 +22,7 @@ if [[ -z ${_NINJA_UTILS_ECLASS} ]]; then case ${EAPI:-0} in 0|1|3) die "EAPI=${EAPI:-0} is not supported (too old)";; # copied from cmake-utils - 2|4|5|6) ;; + 2|4|5|6|7) ;; *) die "EAPI=${EAPI} is not yet supported" ;; esac diff --git a/eclass/out-of-source.eclass b/eclass/out-of-source.eclass index 4d9c8d05fd64..951a20adaca4 100644 --- a/eclass/out-of-source.eclass +++ b/eclass/out-of-source.eclass @@ -1,4 +1,4 @@ -# Copyright 1999-2017 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # @ECLASS: out-of-source.eclass @@ -32,7 +32,7 @@ # @CODE case ${EAPI} in - 6);; + 6|7);; *) die "EAPI ${EAPI:-0} unsupported (too old)";; esac diff --git a/eclass/python-any-r1.eclass b/eclass/python-any-r1.eclass index e4d2d46bc706..6f23109cf8d7 100644 --- a/eclass/python-any-r1.eclass +++ b/eclass/python-any-r1.eclass @@ -1,4 +1,4 @@ -# Copyright 1999-2017 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # @ECLASS: python-any-r1.eclass @@ -36,7 +36,7 @@ # https://wiki.gentoo.org/wiki/Project:Python/python-any-r1 case "${EAPI:-0}" in - 0|1|2|3|4|5|6) + 0|1|2|3|4|5|6|7) ;; *) die "Unsupported EAPI=${EAPI} (unknown) for ${ECLASS}" diff --git a/eclass/python-r1.eclass b/eclass/python-r1.eclass index 5ec23d23d8cc..8a8adb449cc3 100644 --- a/eclass/python-r1.eclass +++ b/eclass/python-r1.eclass @@ -1,4 +1,4 @@ -# Copyright 1999-2017 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # @ECLASS: python-r1.eclass @@ -32,7 +32,7 @@ case "${EAPI:-0}" in 0|1|2|3|4) die "Unsupported EAPI=${EAPI:-0} (too old) for ${ECLASS}" ;; - 5|6) + 5|6|7) # EAPI=5 is required for sane USE_EXPAND dependencies ;; *) diff --git a/eclass/python-single-r1.eclass b/eclass/python-single-r1.eclass index 3762d3d6e990..8c45c391ebb0 100644 --- a/eclass/python-single-r1.eclass +++ b/eclass/python-single-r1.eclass @@ -1,4 +1,4 @@ -# Copyright 1999-2017 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # @ECLASS: python-single-r1.eclass @@ -34,7 +34,7 @@ case "${EAPI:-0}" in 0|1|2|3|4) die "Unsupported EAPI=${EAPI:-0} (too old) for ${ECLASS}" ;; - 5|6) + 5|6|7) # EAPI=5 is required for sane USE_EXPAND dependencies ;; *) diff --git a/eclass/python-utils-r1.eclass b/eclass/python-utils-r1.eclass index 68fb9ba2578d..3a462e34614a 100644 --- a/eclass/python-utils-r1.eclass +++ b/eclass/python-utils-r1.eclass @@ -1,4 +1,4 @@ -# Copyright 1999-2017 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # @ECLASS: python-utils-r1.eclass @@ -19,7 +19,7 @@ # https://wiki.gentoo.org/wiki/Project:Python/python-utils-r1 case "${EAPI:-0}" in - 0|1|2|3|4|5|6) + 0|1|2|3|4|5|6|7) ;; *) die "Unsupported EAPI=${EAPI} (unknown) for ${ECLASS}" @@ -688,8 +688,8 @@ python_optimize() { # 2) skip paths which do not exist # (python2.6 complains about them verbosely) - if [[ ${f} == /* && -d ${D}${f} ]]; then - set -- "${D}${f}" "${@}" + if [[ ${f} == /* && -d ${D%/}${f} ]]; then + set -- "${D%/}${f}" "${@}" fi done < <("${PYTHON}" -c 'import sys; print("\0".join(sys.path))' || die) @@ -699,7 +699,7 @@ python_optimize() { local d for d; do # make sure to get a nice path without // - local instpath=${d#${D}} + local instpath=${d#${D%/}} instpath=/${instpath##/} case "${EPYTHON}" in @@ -924,7 +924,7 @@ python_domodule() { doins -r "${@}" || return ${?} ) - python_optimize "${ED}/${d}" + python_optimize "${ED%/}/${d}" } # @FUNCTION: python_doheader @@ -1086,9 +1086,20 @@ python_is_python3() { python_is_installed() { local impl=${1:-${EPYTHON}} [[ ${impl} ]] || die "${FUNCNAME}: no impl nor EPYTHON" + local hasv_args=() + + case ${EAPI:-0} in + 0|1|2|3|4) + local -x ROOT=/ + ;; + 5|6) + hasv_args+=( --host-root ) + ;; + *) + hasv_args+=( -b ) + ;; + esac - # for has_version - local -x ROOT=/ case "${impl}" in pypy|pypy3) local append= @@ -1097,13 +1108,13 @@ python_is_installed() { fi # be happy with just the interpeter, no need for the virtual - has_version "dev-python/${impl}${append}" \ - || has_version "dev-python/${impl}-bin${append}" + has_version "${hasv_args[@]}" "dev-python/${impl}${append}" \ + || has_version "${hasv_args[@]}" "dev-python/${impl}-bin${append}" ;; *) local PYTHON_PKG_DEP python_export "${impl}" PYTHON_PKG_DEP - has_version "${PYTHON_PKG_DEP}" + has_version "${hasv_args[@]}" "${PYTHON_PKG_DEP}" ;; esac } @@ -1167,7 +1178,7 @@ python_fix_shebang() { for i in "${split_shebang[@]}"; do case "${i}" in *"${EPYTHON}") - debug-print "${FUNCNAME}: in file ${f#${D}}" + debug-print "${FUNCNAME}: in file ${f#${D%/}}" debug-print "${FUNCNAME}: shebang matches EPYTHON: ${shebang}" # Nothing to do, move along. @@ -1176,7 +1187,7 @@ python_fix_shebang() { break ;; *python|*python[23]) - debug-print "${FUNCNAME}: in file ${f#${D}}" + debug-print "${FUNCNAME}: in file ${f#${D%/}}" debug-print "${FUNCNAME}: rewriting shebang: ${shebang}" if [[ ${i} == *python2 ]]; then @@ -1226,7 +1237,7 @@ python_fix_shebang() { fi if [[ ! ${quiet} ]]; then - einfo "Fixing shebang in ${f#${D}}." + einfo "Fixing shebang in ${f#${D%/}}." fi if [[ ! ${error} ]]; then @@ -1240,7 +1251,7 @@ python_fix_shebang() { any_fixed=1 else eerror "The file has incompatible shebang:" - eerror " file: ${f#${D}}" + eerror " file: ${f#${D%/}}" eerror " current shebang: ${shebang}" eerror " requested impl: ${EPYTHON}" die "${FUNCNAME}: conversion of incompatible shebang requested" @@ -1251,7 +1262,7 @@ python_fix_shebang() { local cmd=eerror [[ ${EAPI:-0} == [012345] ]] && cmd=eqawarn - "${cmd}" "QA warning: ${FUNCNAME}, ${path#${D}} did not match any fixable files." + "${cmd}" "QA warning: ${FUNCNAME}, ${path#${D%/}} did not match any fixable files." if [[ ${any_correct} ]]; then "${cmd}" "All files have ${EPYTHON} shebang already." else diff --git a/eclass/ruby-fakegem.eclass b/eclass/ruby-fakegem.eclass index c606ccfdb7b3..b66d57d2d573 100644 --- a/eclass/ruby-fakegem.eclass +++ b/eclass/ruby-fakegem.eclass @@ -1,4 +1,4 @@ -# Copyright 1999-2017 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # @ECLASS: ruby-fakegem.eclass @@ -104,6 +104,14 @@ RUBY_FAKEGEM_BINDIR="${RUBY_FAKEGEM_BINDIR-bin}" # get installed. Some gems provide extra files such as version information, # Rails generators, or data that needs to be installed as well. +case "${EAPI:-0}" in + 0|1|2|3|4|5|6) + ;; + *) + die "Unsupported EAPI=${EAPI} (unknown) for ${ECLASS}" + ;; +esac + RUBY_FAKEGEM_SUFFIX="${RUBY_FAKEGEM_SUFFIX:-}" diff --git a/eclass/scons-utils.eclass b/eclass/scons-utils.eclass index 41a86adfa14a..02c9061ba95d 100644 --- a/eclass/scons-utils.eclass +++ b/eclass/scons-utils.eclass @@ -1,4 +1,4 @@ -# Copyright 1999-2015 Gentoo Foundation +# Copyright 1999-2018 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # @ECLASS: scons-utils.eclass @@ -93,7 +93,7 @@ # -- EAPI support check -- case ${EAPI:-0} in - 0|1|2|3|4|5|6) ;; + 0|1|2|3|4|5|6|7) ;; *) die "EAPI ${EAPI} unsupported." esac @@ -102,9 +102,14 @@ inherit multiprocessing # -- ebuild variables setup -- if [[ -n ${SCONS_MIN_VERSION} ]]; then - DEPEND=">=dev-util/scons-${SCONS_MIN_VERSION}" + BDEPEND=">=dev-util/scons-${SCONS_MIN_VERSION}" else - DEPEND="dev-util/scons" + BDEPEND="dev-util/scons" +fi + +if [[ ${EAPI:-0} == [0123456] ]]; then + DEPEND=${BDEPEND} + unset BDEPEND fi # -- public functions -- -- cgit v1.2.3