Code: Select all
declare -x ABI="amd64"
declare -x ABI_MIPS=""
declare -x ABI_PPC=""
declare -x ABI_RISCV=""
declare -x ABI_S390=""
declare -x ABI_X86="64"
declare -x ALSA_CARDS=""
declare -x APACHE2_MODULES=""
declare -x APACHE2_MPMS=""
declare -x ARCH="amd64"
declare BDEPEND="python_targets_pypy? ( >=virtual/pypy-5:0=[xml(+)] ) python_targets_pypy3? ( >=virtual/pypy3-5:0=[xml(+)] ) python_targets_python2_7? ( >=dev-lang/python-2.7.5-r2:2.7[xml(+)] ) python_targets_python3_5? ( dev-lang/python:3.5[xml(+)] ) python_targets_python3_6? ( dev-lang/python:3.6[xml(+)] ) python_targets_python3_7? ( dev-lang/python:3.7[xml(+)] ) >=dev-lang/python-exec-2:=[python_targets_pypy(-)?,python_targets_pypy3(-)?,python_targets_python2_7(-)?,python_targets_python3_5(-)?,python_targets_python3_6(-)?,python_targets_python3_7(-)?,-python_single_target_pypy(-),-python_single_target_pypy3(-),-python_single_target_python2_7(-),-python_single_target_python3_5(-),-python_single_target_python3_6(-),-python_single_target_python3_7(-)]"
declare -x BOOTSTRAP_USE="unicode internal-glib pkg-config split-usr python_targets_python3_6 python_targets_python2_7 multilib"
declare -x CALLIGRA_FEATURES=""
declare -x CAMERAS=""
declare -x CBUILD="x86_64-pc-linux-gnu"
declare -x CFLAGS="-march=core2 -O2 -pipe"
declare -x CFLAGS_amd64="-m64"
declare -x CFLAGS_default
declare -x CFLAGS_x32="-mx32"
declare -x CFLAGS_x86="-m32"
declare -x CHOST="x86_64-pc-linux-gnu"
declare -x CHOST_amd64="x86_64-pc-linux-gnu"
declare -x CHOST_default="x86_64-pc-linux-gnu"
declare -x CHOST_x32="x86_64-pc-linux-gnux32"
declare -x CHOST_x86="i686-pc-linux-gnu"
declare -x COLLECTD_PLUGINS=""
declare -x COMMON_FLAGS="-march=core2 -O2 -pipe"
declare -x CPU_FLAGS_ARM=""
declare -x CPU_FLAGS_X86=""
declare -x CTARGET_default="x86_64-pc-linux-gnu"
declare -x CURL_SSL=""
declare -x CXXFLAGS="-march=core2 -O2 -pipe"
declare -x DEFAULT_ABI="amd64"
declare -x DEFINED_PHASES=" compile configure install prepare test"
declare DEPEND="
app-arch/unzip
test? (
dev-python/mock[python_targets_pypy(-)?,python_targets_pypy3(-)?,python_targets_python2_7(-)?,python_targets_python3_5(-)?,python_targets_python3_6(-)?,python_targets_python3_7(-)?,-python_single_target_pypy(-),-python_single_target_pypy3(-),-python_single_target_python2_7(-),-python_single_target_python3_5(-),-python_single_target_python3_6(-),-python_single_target_python3_7(-)]
dev-python/pip[python_targets_pypy(-)?,python_targets_pypy3(-)?,python_targets_python2_7(-)?,python_targets_python3_5(-)?,python_targets_python3_6(-)?,python_targets_python3_7(-)?,-python_single_target_pypy(-),-python_single_target_pypy3(-),-python_single_target_python2_7(-),-python_single_target_python3_5(-),-python_single_target_python3_6(-),-python_single_target_python3_7(-)]
>=dev-python/pytest-3.7.0[python_targets_pypy(-)?,python_targets_pypy3(-)?,python_targets_python2_7(-)?,python_targets_python3_5(-)?,python_targets_python3_6(-)?,python_targets_python3_7(-)?,-python_single_target_pypy(-),-python_single_target_pypy3(-),-python_single_target_python2_7(-),-python_single_target_python3_5(-),-python_single_target_python3_6(-),-python_single_target_python3_7(-)]
<dev-python/pytest-4
dev-python/pytest-fixture-config[python_targets_pypy(-)?,python_targets_pypy3(-)?,python_targets_python2_7(-)?,python_targets_python3_5(-)?,python_targets_python3_6(-)?,python_targets_python3_7(-)?,-python_single_target_pypy(-),-python_single_target_pypy3(-),-python_single_target_python2_7(-),-python_single_target_python3_5(-),-python_single_target_python3_6(-),-python_single_target_python3_7(-)]
dev-python/pytest-virtualenv[python_targets_pypy(-)?,python_targets_pypy3(-)?,python_targets_python2_7(-)?,python_targets_python3_5(-)?,python_targets_python3_6(-)?,python_targets_python3_7(-)?,-python_single_target_pypy(-),-python_single_target_pypy3(-),-python_single_target_python2_7(-),-python_single_target_python3_5(-),-python_single_target_python3_6(-),-python_single_target_python3_7(-)]
dev-python/wheel[python_targets_pypy(-)?,python_targets_pypy3(-)?,python_targets_python2_7(-)?,python_targets_python3_5(-)?,python_targets_python3_6(-)?,python_targets_python3_7(-)?,-python_single_target_pypy(-),-python_single_target_pypy3(-),-python_single_target_python2_7(-),-python_single_target_python3_5(-),-python_single_target_python3_6(-),-python_single_target_python3_7(-)]
virtual/python-futures[python_targets_pypy(-)?,python_targets_pypy3(-)?,python_targets_python2_7(-)?,python_targets_python3_5(-)?,python_targets_python3_6(-)?,python_targets_python3_7(-)?,-python_single_target_pypy(-),-python_single_target_pypy3(-),-python_single_target_python2_7(-),-python_single_target_python3_5(-),-python_single_target_python3_6(-),-python_single_target_python3_7(-)]
)
"
declare DESCRIPTION="Collection of extensions to Distutils"
declare -x DIROPTIONS="-m0755"
declare -- DISTUTILS_IN_SOURCE_BUILD="1"
declare -a DOCS=([0]="CHANGES.rst" [1]="README.rst" [2]="docs/easy_install.txt" [3]="docs/pkg_resources.txt" [4]="docs/setuptools.txt")
declare -x EAPI="7"
declare -x ELIBC="glibc"
declare -x ENLIGHTENMENT_MODULES=""
declare -x ENV_UNSET="DBUS_SESSION_BUS_ADDRESS DISPLAY GOBIN PERL5LIB PERL5OPT PERLPREFIX PERL_CORE PERL_MB_OPT PERL_MM_OPT XAUTHORITY XDG_CACHE_HOME XDG_CONFIG_HOME XDG_DATA_HOME XDG_RUNTIME_DIR"
declare -- EPOCHREALTIME="1567033522,898043"
declare -- EPOCHSECONDS="1567033522"
declare -x EXEOPTIONS="-m0755"
declare -x FCFLAGS="-march=core2 -O2 -pipe"
declare -x FETCHCOMMAND_SSH="bash -c \"x=\\\${2#ssh://} ; host=\\\${x%%/*} ; port=\\\${host##*:} ; host=\\\${host%:*} ; [[ \\\${host} = \\\${port} ]] && port= ; exec rsync --rsh=\\\"ssh \\\${port:+-p\\\${port}} \\\${3}\\\" -avP \\\"\\\${host}:/\\\${x#*/}\\\" \\\"\\\$1\\\"\" rsync \"\${DISTDIR}/\${FILE}\" \"\${URI}\" \"\${PORTAGE_SSH_OPTS}\""
declare -x FFLAGS="-march=core2 -O2 -pipe"
declare -x FFTOOLS=""
declare -x FLTK_DOCDIR="/usr/share/doc/fltk-1.3.5-r2/html"
declare -x GCC_SPECS=""
declare -x GPSD_PROTOCOLS=""
declare -x GRUB_PLATFORMS=""
declare -x GSETTINGS_BACKEND="dconf"
declare HDEPEND=""
declare HOMEPAGE="https://github.com/pypa/setuptools https://pypi.org/project/setuptools/"
declare -x INHERITED=" multiprocessing toolchain-funcs multilib multibuild python-utils-r1 python-r1 distutils-r1"
declare -x INPUT_DEVICES=""
declare -x INSOPTIONS="-m0644"
declare IUSE="test python_targets_pypy python_targets_pypy3 python_targets_python2_7 python_targets_python3_5 python_targets_python3_6 python_targets_python3_7"
declare -x IUSE_EFFECTIVE="abi_x86_64 alpha amd64 amd64-fbsd amd64-linux arm arm64 elibc_AIX elibc_Cygwin elibc_Darwin elibc_DragonFly elibc_FreeBSD elibc_HPUX elibc_Interix elibc_NetBSD elibc_OpenBSD elibc_SunOS elibc_Winnt elibc_bionic elibc_glibc elibc_mingw elibc_mintlib elibc_musl elibc_uclibc hppa ia64 kernel_AIX kernel_Darwin kernel_FreeBSD kernel_HPUX kernel_NetBSD kernel_OpenBSD kernel_SunOS kernel_Winnt kernel_freemint kernel_linux m68k m68k-mint mips ppc ppc-aix ppc-macos ppc64 ppc64-linux prefix prefix-guest prefix-stack python_targets_pypy python_targets_pypy3 python_targets_python2_7 python_targets_python3_5 python_targets_python3_6 python_targets_python3_7 riscv s390 sh sparc sparc-solaris sparc64-solaris test userland_BSD userland_GNU x64-cygwin x64-macos x64-solaris x86 x86-cygwin x86-fbsd x86-linux x86-macos x86-solaris x86-winnt"
declare -x IUSE_IMPLICIT="abi_x86_64 prefix prefix-guest prefix-stack"
declare -x KERNEL="linux"
declare -x KERNEL_ABI="amd64"
declare -x KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sh ~sparc ~x86 ~x64-cygwin ~amd64-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
declare -x L10N=""
declare -x LADSPA_PATH="/usr/lib64/ladspa"
declare -x LANG="es_ES.utf8"
declare -x LANGUAGE="es_ES.UTF-8"
declare -x LCD_DEVICES=""
declare -x LC_ADDRESS=""
declare -x LC_COLLATE="C"
declare -x LC_CTYPE=""
declare -x LC_IDENTIFICATION=""
declare -x LC_MEASUREMENT=""
declare -x LC_MESSAGES=""
declare -x LC_MONETARY=""
declare -x LC_NAME=""
declare -x LC_NUMERIC=""
declare -x LC_PAPER=""
declare -x LC_TELEPHONE=""
declare -x LC_TIME=""
declare -x LDFLAGS="-Wl,-O1 -Wl,--as-needed"
declare -x LDFLAGS_amd64="-m elf_x86_64"
declare -x LDFLAGS_default
declare -x LDFLAGS_x32="-m elf32_x86_64"
declare -x LDFLAGS_x86="-m elf_i386"
declare -x LIBDIR_amd64="lib64"
declare -x LIBDIR_default="lib"
declare -x LIBDIR_x32="libx32"
declare -x LIBDIR_x86="lib32"
declare -x LIBOPTIONS="-m0644"
declare -x LIBREOFFICE_EXTENSIONS=""
declare -x LICENSE="MIT"
declare -x LINGUAS="es"
declare -x LIRC_DEVICES=""
declare -x LLVM_TARGETS=""
declare -x LV2_PATH="/usr/lib64/lv2"
declare -x MAIL="/var/mail/root"
declare -x MAKEOPTS="-j3"
declare -x MANPAGER="manpager"
declare -x MONKEYD_PLUGINS=""
declare -x MULTILIB_ABIS="amd64 x86"
declare -x MULTILIB_STRICT_DENY="64-bit.*shared object"
declare -x MULTILIB_STRICT_DIRS="/lib32 /lib /usr/lib32 /usr/lib /usr/kde/*/lib32 /usr/kde/*/lib /usr/qt/*/lib32 /usr/qt/*/lib /usr/X11R6/lib32 /usr/X11R6/lib"
declare -x MULTILIB_STRICT_EXEMPT="(perl5|gcc|gcc-lib|binutils|eclipse-3|debug|portage|udev|systemd|clang|python-exec|llvm)"
declare -x NETBEANS_MODULES=""
declare -x NGINX_MODULES_HTTP=""
declare -x NGINX_MODULES_MAIL=""
declare -x NGINX_MODULES_STREAM=""
declare -x OFED_DRIVERS=""
declare -x OFFICE_IMPLEMENTATION=""
declare -x OPENGL_PROFILE="xorg-x11"
declare -x OPENMPI_FABRICS=""
declare -x OPENMPI_OFED_FEATURES=""
declare -x OPENMPI_RM=""
declare -x PATH="/usr/lib/portage/python3.6/ebuild-helpers/xattr:/usr/lib/portage/python3.6/ebuild-helpers:/usr/lib/llvm/8/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/opt/bin"
declare PDEPEND="
>=dev-python/certifi-2016.9.26[python_targets_pypy(-)?,python_targets_pypy3(-)?,python_targets_python2_7(-)?,python_targets_python3_5(-)?,python_targets_python3_6(-)?,python_targets_python3_7(-)?,-python_single_target_pypy(-),-python_single_target_pypy3(-),-python_single_target_python2_7(-),-python_single_target_python3_5(-),-python_single_target_python3_6(-),-python_single_target_python3_7(-)] "
declare -x PHP_TARGETS=""
declare -x PKG_CONFIG_PATH="/usr/lib64/pkgconfig"
declare -x PORTAGE_COMPRESSION_COMMAND="bzip2"
declare -a PORTAGE_DOCOMPRESS=([0]="/usr/share/doc" [1]="/usr/share/info" [2]="/usr/share/man")
declare -x PORTAGE_DOCOMPRESS_SIZE_LIMIT="128"
declare -a PORTAGE_DOCOMPRESS_SKIP=([0]="/usr/share/doc/setuptools-41.2.0/html")
declare -a PORTAGE_DOSTRIP=([0]="/")
declare -a PORTAGE_DOSTRIP_SKIP=()
declare -x POSTGRES_TARGETS=""
declare -x PRELINK_PATH_MASK="/opt"
declare -x PROFILE_ONLY_VARIABLES="ARCH ELIBC IUSE_IMPLICIT KERNEL USERLAND USE_EXPAND_IMPLICIT USE_EXPAND_UNPREFIXED USE_EXPAND_VALUES_ARCH USE_EXPAND_VALUES_ELIBC USE_EXPAND_VALUES_KERNEL USE_EXPAND_VALUES_USERLAND"
declare -x PROPERTIES=""
declare -x PYTHONDONTWRITEBYTECODE="1"
declare -a PYTHON_COMPAT=([0]="python2_7" [1]="python3_5" [2]="python3_6" [3]="python3_7" [4]="pypy" [5]="pypy3")
declare -- PYTHON_DEPS="python_targets_pypy? ( >=virtual/pypy-5:0=[xml(+)] ) python_targets_pypy3? ( >=virtual/pypy3-5:0=[xml(+)] ) python_targets_python2_7? ( >=dev-lang/python-2.7.5-r2:2.7[xml(+)] ) python_targets_python3_5? ( dev-lang/python:3.5[xml(+)] ) python_targets_python3_6? ( dev-lang/python:3.6[xml(+)] ) python_targets_python3_7? ( dev-lang/python:3.7[xml(+)] ) >=dev-lang/python-exec-2:=[python_targets_pypy(-)?,python_targets_pypy3(-)?,python_targets_python2_7(-)?,python_targets_python3_5(-)?,python_targets_python3_6(-)?,python_targets_python3_7(-)?,-python_single_target_pypy(-),-python_single_target_pypy3(-),-python_single_target_python2_7(-),-python_single_target_python3_5(-),-python_single_target_python3_6(-),-python_single_target_python3_7(-)]"
declare -- PYTHON_REQUIRED_USE="|| ( python_targets_pypy python_targets_pypy3 python_targets_python2_7 python_targets_python3_5 python_targets_python3_6 python_targets_python3_7 )"
declare -- PYTHON_REQ_USE="xml(+)"
declare -x PYTHON_SINGLE_TARGET=""
declare -x PYTHON_TARGETS="python2_7 python3_6"
declare -- PYTHON_USEDEP="python_targets_pypy(-)?,python_targets_pypy3(-)?,python_targets_python2_7(-)?,python_targets_python3_5(-)?,python_targets_python3_6(-)?,python_targets_python3_7(-)?,-python_single_target_pypy(-),-python_single_target_pypy3(-),-python_single_target_python2_7(-),-python_single_target_python3_5(-),-python_single_target_python3_6(-),-python_single_target_python3_7(-)"
declare -x QEMU_SOFTMMU_TARGETS=""
declare -x QEMU_USER_TARGETS=""
declare RDEPEND="
python_targets_pypy? ( >=virtual/pypy-5:0=[xml(+)] ) python_targets_pypy3? ( >=virtual/pypy3-5:0=[xml(+)] ) python_targets_python2_7? ( >=dev-lang/python-2.7.5-r2:2.7[xml(+)] ) python_targets_python3_5? ( dev-lang/python:3.5[xml(+)] ) python_targets_python3_6? ( dev-lang/python:3.6[xml(+)] ) python_targets_python3_7? ( dev-lang/python:3.7[xml(+)] ) >=dev-lang/python-exec-2:=[python_targets_pypy(-)?,python_targets_pypy3(-)?,python_targets_python2_7(-)?,python_targets_python3_5(-)?,python_targets_python3_6(-)?,python_targets_python3_7(-)?,-python_single_target_pypy(-),-python_single_target_pypy3(-),-python_single_target_python2_7(-),-python_single_target_python3_5(-),-python_single_target_python3_6(-),-python_single_target_python3_7(-)]"
declare REPOSITORY
declare REQUIRED_USE="|| ( python_targets_pypy python_targets_pypy3 python_targets_python2_7 python_targets_python3_5 python_targets_python3_6 python_targets_python3_7 )"
declare -x RESTRICT="test"
declare -x RESUMECOMMAND_SSH="bash -c \"x=\\\${2#ssh://} ; host=\\\${x%%/*} ; port=\\\${host##*:} ; host=\\\${host%:*} ; [[ \\\${host} = \\\${port} ]] && port= ; exec rsync --rsh=\\\"ssh \\\${port:+-p\\\${port}} \\\${3}\\\" -avP \\\"\\\${host}:/\\\${x#*/}\\\" \\\"\\\$1\\\"\" rsync \"\${DISTDIR}/\${FILE}\" \"\${URI}\" \"\${PORTAGE_SSH_OPTS}\""
declare -x ROS_MESSAGES=""
declare -x RUBY_TARGETS=""
declare -x S="/var/tmp/portage/dev-python/setuptools-41.2.0/work/setuptools-41.2.0"
declare -x SANDBOX_DEBUG="0"
declare -x SANDBOX_DENY=""
declare -x SANDBOX_PREDICT="/var/tmp/portage/dev-python/setuptools-41.2.0/homedir:/dev/crypto:/var/cache/man:/proc/self/coredump_filter:/var/cache/fontconfig"
declare -x SANDBOX_READ="/:/var/tmp/portage"
declare -x SANDBOX_VERBOSE="1"
declare -x SANDBOX_WRITE=":/dev/console:/dev/fd:/dev/full:/dev/null:/dev/ptmx:/dev/pts/:/dev/pty:/dev/shm:/dev/tts:/dev/tty:/dev/vc/:/dev/zero:/proc/self/fd:/tmp/:/usr/lib/cf:/usr/lib/conftest:/usr/lib32/cf:/usr/lib32/conftest:/usr/lib64/cf:/usr/lib64/conftest:/usr/tmp/cf:/usr/tmp/conftest:/var/tmp/:/var/tmp/portage:/var/tmp/portage/dev-python/setuptools-41.2.0/homedir/.bash_history"
declare -x SANE_BACKENDS=""
declare -x SHELL="/bin/bash"
declare -x SLOT="0"
declare SRC_URI="mirror://pypi/s/setuptools/setuptools-41.2.0.zip"
declare -x SUDO_COMMAND="/usr/bin/emerge glib"
declare -x SUDO_GID="1001"
declare -x SUDO_UID="1001"
declare -x SUDO_USER="anneiris"
declare -x SYMLINK_LIB="yes"
declare -x TWISTED_DISABLE_WRITING_OF_PLUGIN_CACHE="1"
declare -x USE="abi_x86_64 amd64 elibc_glibc kernel_linux python_targets_python2_7 python_targets_python3_6 userland_GNU"
declare -x USERLAND="GNU"
declare -x USE_EXPAND_IMPLICIT="ARCH ELIBC KERNEL USERLAND"
declare -x USE_EXPAND_UNPREFIXED="ARCH"
declare -x USE_EXPAND_VALUES_ARCH="alpha amd64 amd64-fbsd amd64-linux arm arm64 hppa ia64 m68k m68k-mint mips ppc ppc64 ppc64-linux ppc-aix ppc-macos riscv s390 sh sparc sparc64-solaris sparc-solaris x64-cygwin x64-macos x64-solaris x86 x86-cygwin x86-fbsd x86-linux x86-macos x86-solaris x86-winnt"
declare -x USE_EXPAND_VALUES_ELIBC="AIX bionic Cygwin Darwin DragonFly FreeBSD glibc HPUX Interix mingw mintlib musl NetBSD OpenBSD SunOS uclibc Winnt"
declare -x USE_EXPAND_VALUES_KERNEL="AIX Darwin FreeBSD freemint HPUX linux NetBSD OpenBSD SunOS Winnt"
declare -x USE_EXPAND_VALUES_USERLAND="BSD GNU"
declare -x UWSGI_PLUGINS=""
declare -x VIDEO_CARDS=""
declare -x VOICEMAIL_STORAGE=""
declare -x XDG_CONFIG_DIRS="/etc/xdg:/usr/share"
declare -x XDG_DATA_DIRS="/usr/local/share:/usr/share"
declare -x XFCE_PLUGINS=""
declare -x XTABLES_ADDONS=""
declare -- _DISTUTILS_R1="1"
declare -x _E_DESTTREE_="/usr"
declare -x _E_DOCDESTTREE_=""
declare -x _E_EXEDESTTREE_=""
declare -x _E_INSDESTTREE_=""
declare -- _MULTIBUILD="1"
declare -- _MULTILIB_ECLASS="1"
declare -- _MULTIPROCESSING_ECLASS="1"
declare -a _PYTHON_ALL_IMPLS=([0]="jython2_7" [1]="pypy" [2]="pypy3" [3]="python2_7" [4]="python3_5" [5]="python3_6" [6]="python3_7")
declare -- _PYTHON_R1="1"
declare -a _PYTHON_SUPPORTED_IMPLS=([0]="pypy" [1]="pypy3" [2]="python2_7" [3]="python3_5" [4]="python3_6" [5]="python3_7")
declare -a _PYTHON_UNSUPPORTED_IMPLS=([0]="jython2_7")
declare -- _PYTHON_UTILS_R1="1"
declare -- _TOOLCHAIN_FUNCS_ECLASS="1"
declare -- phase_func
PYTHON ()
{
die "${FUNCNAME}() is invalid for python-r1 suite, please take a look @ https://wiki.gentoo.org/wiki/Project:Python/Python.eclass_conversion#.24.28PYTHON.29.2C_.24.7BEPYTHON.7D"
}
__eapi6_src_install ()
{
if [[ -f Makefile || -f GNUmakefile || -f makefile ]]; then
emake DESTDIR="${D}" install;
fi;
einstalldocs
}
__eapi6_src_prepare ()
{
if ___is_indexed_array_var PATCHES; then
[[ ${#PATCHES[@]} -gt 0 ]] && eapply "${PATCHES[@]}";
else
if [[ -n ${PATCHES} ]]; then
eapply ${PATCHES};
fi;
fi;
eapply_user
}
__eapi7_ver_compare ()
{
local va=${1} vb=${2} a an al as ar b bn bl bs br re LC_ALL=C;
re="^([0-9]+(\.[0-9]+)*)([a-z]?)((_(alpha|beta|pre|rc|p)[0-9]*)*)(-r[0-9]+)?$";
[[ ${va} =~ ${re} ]] || die "${FUNCNAME}: invalid version: ${va}";
an=${BASH_REMATCH[1]};
al=${BASH_REMATCH[3]};
as=${BASH_REMATCH[4]};
ar=${BASH_REMATCH[7]};
[[ ${vb} =~ ${re} ]] || die "${FUNCNAME}: invalid version: ${vb}";
bn=${BASH_REMATCH[1]};
bl=${BASH_REMATCH[3]};
bs=${BASH_REMATCH[4]};
br=${BASH_REMATCH[7]};
__eapi7_ver_compare_int "${an%%.*}" "${bn%%.*}" || return;
while [[ ${an} == *.* && ${bn} == *.* ]]; do
an=${an#*.};
bn=${bn#*.};
a=${an%%.*};
b=${bn%%.*};
if [[ ${a} == 0* || ${b} == 0* ]]; then
[[ ${a} =~ 0+$ ]] && a=${a%"${BASH_REMATCH[0]}"};
[[ ${b} =~ 0+$ ]] && b=${b%"${BASH_REMATCH[0]}"};
[[ ${a} > ${b} ]] && return 3;
[[ ${a} < ${b} ]] && return 1;
else
__eapi7_ver_compare_int "${a}" "${b}" || return;
fi;
done;
[[ ${an} == *.* ]] && return 3;
[[ ${bn} == *.* ]] && return 1;
[[ ${al} > ${bl} ]] && return 3;
[[ ${al} < ${bl} ]] && return 1;
as=${as#_}${as:+_};
bs=${bs#_}${bs:+_};
while [[ -n ${as} && -n ${bs} ]]; do
a=${as%%_*};
b=${bs%%_*};
if [[ ${a%%[0-9]*} == "${b%%[0-9]*}" ]]; then
__eapi7_ver_compare_int "${a##*[a-z]}" "${b##*[a-z]}" || return;
else
[[ ${a%%[0-9]*} == p ]] && return 3;
[[ ${b%%[0-9]*} == p ]] && return 1;
[[ ${a} > ${b} ]] && return 3 || return 1;
fi;
as=${as#*_};
bs=${bs#*_};
done;
if [[ -n ${as} ]]; then
[[ ${as} == p[_0-9]* ]] && return 3 || return 1;
else
if [[ -n ${bs} ]]; then
[[ ${bs} == p[_0-9]* ]] && return 1 || return 3;
fi;
fi;
__eapi7_ver_compare_int "${ar#-r}" "${br#-r}" || return;
return 2
}
__eapi7_ver_compare_int ()
{
local a=$1 b=$2 d=$(( ${#1}-${#2} ));
if [[ ${d} -gt 0 ]]; then
printf -v b "%0${d}d%s" 0 "${b}";
else
if [[ ${d} -lt 0 ]]; then
printf -v a "%0$(( -d ))d%s" 0 "${a}";
fi;
fi;
[[ ${a} > ${b} ]] && return 3;
[[ ${a} == "${b}" ]]
}
__eapi7_ver_parse_range ()
{
local range=${1};
local max=${2};
[[ ${range} == [0-9]* ]] || die "${FUNCNAME}: range must start with a number";
start=${range%-*};
[[ ${range} == *-* ]] && end=${range#*-} || end=${start};
if [[ -n ${end} ]]; then
[[ ${start} -le ${end} ]] || die "${FUNCNAME}: end of range must be >= start";
[[ ${end} -le ${max} ]] || end=${max};
else
end=${max};
fi
}
__eapi7_ver_split ()
{
local v=${1} LC_ALL=C;
comp=();
local s c;
while [[ -n ${v} ]]; do
s=${v%%[a-zA-Z0-9]*};
v=${v:${#s}};
[[ ${v} == [0-9]* ]] && c=${v%%[^0-9]*} || c=${v%%[^a-zA-Z]*};
v=${v:${#c}};
comp+=("${s}" "${c}");
done
}
_clang_fullversion ()
{
local ver="$1";
shift;
set -- $($(tc-getCPP "$@") -E -P - <<<"__clang_major__ __clang_minor__ __clang_patchlevel__");
eval echo "$ver"
}
_distutils-r1_check_namespace_pth ()
{
local f pth=();
while IFS= read -r -d '' f; do
pth+=("${f}");
done < <(find "${ED%/}" -name '*-nspkg.pth' -print0);
if [[ -n ${pth[@]} ]]; then
ewarn "The following *-nspkg.pth files were found installed:";
ewarn;
for f in "${pth[@]}";
do
ewarn " ${f#${ED%/}}";
done;
ewarn;
ewarn "The presence of those files may break namespaces in Python 3.5+. Please";
ewarn "read our documentation on reliable handling of namespaces and update";
ewarn "the ebuild accordingly:";
ewarn;
ewarn " https://wiki.gentoo.org/wiki/Project:Python/Namespace_packages";
fi
}
_distutils-r1_clean_egg_info ()
{
rm -rf "${BUILD_DIR}"/lib/*.egg-info || die
}
_distutils-r1_copy_egg_info ()
{
mkdir -p "${BUILD_DIR}" || die;
find -name '*.egg-info' -type d -exec cp -R -p {} "${BUILD_DIR}"/ ';' || die
}
_distutils-r1_create_setup_cfg ()
{
cat > "${HOME}"/.pydistutils.cfg <<-_EOF_ ||
[build]
build-base = ${BUILD_DIR}
# using a single directory for them helps us export
# ${PYTHONPATH} and ebuilds find the sources independently
# of whether the package installs extensions or not
#
# note: due to some packages (wxpython) relying on separate
# platlib & purelib dirs, we do not set --build-lib (which
# can not be overridden with --build-*lib)
build-platlib = %(build-base)s/lib
build-purelib = %(build-base)s/lib