diff --git a/sdk_container/src/third_party/portage-stable/eclass/multilib-build.eclass b/sdk_container/src/third_party/portage-stable/eclass/multilib-build.eclass index 00f02df98f..17cd7da0d1 100644 --- a/sdk_container/src/third_party/portage-stable/eclass/multilib-build.eclass +++ b/sdk_container/src/third_party/portage-stable/eclass/multilib-build.eclass @@ -1,12 +1,13 @@ -# Copyright 2013-2019 Gentoo Authors +# Copyright 2013-2021 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 # @ECLASS: multilib-build.eclass # @MAINTAINER: -# gx86-multilib team +# Michał Górny # @AUTHOR: # Author: Michał Górny -# @SUPPORTED_EAPIS: 4 5 6 7 +# @SUPPORTED_EAPIS: 5 6 7 8 +# @PROVIDES: multibuild # @BLURB: flags and utility functions for building multilib packages # @DESCRIPTION: # The multilib-build.eclass exports USE flags and utility functions @@ -17,15 +18,15 @@ # dependencies shall use the USE dependency string in ${MULTILIB_USEDEP} # to properly request multilib enabled. -if [[ ! ${_MULTILIB_BUILD} ]]; then - -# EAPI=4 is required for meaningful MULTILIB_USEDEP. -case ${EAPI:-0} in - 4|5|6|7) ;; - *) die "EAPI=${EAPI} is not supported" ;; +case ${EAPI} in + 5|6|7|8) ;; + *) die "${ECLASS}: EAPI ${EAPI:-0} not supported" ;; esac -[[ ${EAPI} == [45] ]] && inherit eutils +if [[ -z ${_MULTILIB_BUILD} ]]; then +_MULTILIB_BUILD=1 + +[[ ${EAPI} == 5 ]] && inherit eutils inherit multibuild multilib # @ECLASS-VARIABLE: _MULTILIB_FLAGS @@ -47,8 +48,6 @@ _MULTILIB_FLAGS=( abi_mips_o32:o32 # abi_ppc_32:ppc,ppc_aix,ppc_macos # abi_ppc_64:ppc64 - abi_riscv_lp64d:lp64d - abi_riscv_lp64:lp64 abi_s390_32:s390 abi_s390_64:s390x ) @@ -79,6 +78,7 @@ readonly _MULTILIB_FLAGS # @CODE # @ECLASS-VARIABLE: MULTILIB_USEDEP +# @OUTPUT_VARIABLE # @DESCRIPTION: # The USE-dependency to be used on dependencies (libraries) needing # to support multilib as well. @@ -90,7 +90,7 @@ readonly _MULTILIB_FLAGS # @CODE # @ECLASS-VARIABLE: MULTILIB_ABI_FLAG -# @DEFAULT_UNSET +# @OUTPUT_VARIABLE # @DESCRIPTION: # The complete ABI name. Resembles the USE flag name. # @@ -251,7 +251,7 @@ multilib_parallel_foreach_abi() { multilib_for_best_abi() { debug-print-function ${FUNCNAME} "${@}" - [[ ${EAPI} == [45] ]] || die "${FUNCNAME} is banned in EAPI ${EAPI}, use multilib_is_native_abi() instead" + [[ ${EAPI} == 5 ]] || die "${FUNCNAME} is banned in EAPI ${EAPI}, use multilib_is_native_abi() instead" eqawarn "QA warning: multilib_for_best_abi() function is deprecated and should" eqawarn "not be used. The multilib_is_native_abi() check may be used instead." @@ -320,6 +320,7 @@ multilib_copy_sources() { } # @ECLASS-VARIABLE: MULTILIB_WRAPPED_HEADERS +# @DEFAULT_UNSET # @DESCRIPTION: # A list of headers to wrap for multilib support. The listed headers # will be moved to a non-standard location and replaced with a file @@ -342,6 +343,7 @@ multilib_copy_sources() { # @CODE # @ECLASS-VARIABLE: MULTILIB_CHOST_TOOLS +# @DEFAULT_UNSET # @DESCRIPTION: # A list of tool executables to preserve for each multilib ABI. # The listed executables will be renamed to ${CHOST}-${basename}, @@ -369,8 +371,8 @@ multilib_copy_sources() { # MULTILIB_CHOST_TOOLS=( # /usr/bin/foo-config # ) - # @CODE + # @FUNCTION: multilib_prepare_wrappers # @USAGE: [] # @DESCRIPTION: @@ -488,14 +490,6 @@ multilib_prepare_wrappers() { # elif(_MIPS_SIM == _ABIO32) /* o32 */ # error "abi_mips_o32 not supported by the package." # endif -#elif defined(__riscv) -# if defined(__riscv_float_abi_double) -# error "abi_riscv_lp64d not supported by the package." -# elif defined(__riscv_float_abi_single) -# error "abi_riscv_lp64f not supported by the package." -# else -# error "abi_riscv_lp64 not supported by the package." -# endif #elif defined(__sparc__) # if defined(__arch64__) # error "abi_sparc_64 not supported by the package." @@ -595,7 +589,7 @@ multilib_is_native_abi() { multilib_build_binaries() { debug-print-function ${FUNCNAME} "${@}" - [[ ${EAPI} == [45] ]] || die "${FUNCNAME} is banned in EAPI ${EAPI}, use multilib_is_native_abi() instead" + [[ ${EAPI} == 5 ]] || die "${FUNCNAME} is banned in EAPI ${EAPI}, use multilib_is_native_abi() instead" eqawarn "QA warning: multilib_build_binaries is deprecated. Please use the equivalent" eqawarn "multilib_is_native_abi function instead." @@ -670,7 +664,6 @@ multilib_native_with() { # of (or 'no' if unspecified) and . Arguments # are the same as for usex in the EAPI. # -# Note: in EAPI 4 you need to inherit eutils to use this function. multilib_native_usex() { if multilib_is_native_abi; then usex "${@}" @@ -679,5 +672,4 @@ multilib_native_usex() { fi } -_MULTILIB_BUILD=1 fi