diff options
author | Michał Górny <mgorny@gentoo.org> | 2018-05-03 11:56:43 +0200 |
---|---|---|
committer | Michał Górny <mgorny@gentoo.org> | 2018-05-07 09:43:26 +0200 |
commit | 1d5f376f8d4b3c6b249452f4242ac2bde10a6a02 (patch) | |
tree | 08fcb8134d4610bad583cea147cbef16d90a8bae /eclass | |
parent | multibuild.eclass: Enable EAPI 7 (no changes) (diff) | |
download | gentoo-1d5f376f8d4b3c6b249452f4242ac2bde10a6a02.tar.gz gentoo-1d5f376f8d4b3c6b249452f4242ac2bde10a6a02.tar.bz2 gentoo-1d5f376f8d4b3c6b249452f4242ac2bde10a6a02.zip |
multilib-build.eclass: Enable EAPI 7 support
Enable EAPI 7. Correct all ${ED} references to account both for
trailing slash being present and absent.
Diffstat (limited to 'eclass')
-rw-r--r-- | eclass/multilib-build.eclass | 22 |
1 files changed, 11 insertions, 11 deletions
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 } |