From 218d629e4af36c5bd6763527b4811eac8c5d67cc Mon Sep 17 00:00:00 2001 From: Flatcar Buildbot Date: Mon, 25 Sep 2023 07:13:54 +0000 Subject: [PATCH] eclass/python-utils-r1: Sync with Gentoo It's from Gentoo commit 93a87f4f59eb62356f2d2cc45c6cb252cf865e11. --- .../eclass/python-utils-r1.eclass | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) diff --git a/sdk_container/src/third_party/portage-stable/eclass/python-utils-r1.eclass b/sdk_container/src/third_party/portage-stable/eclass/python-utils-r1.eclass index f9c6d161d3..50aeabae1c 100644 --- a/sdk_container/src/third_party/portage-stable/eclass/python-utils-r1.eclass +++ b/sdk_container/src/third_party/portage-stable/eclass/python-utils-r1.eclass @@ -346,24 +346,22 @@ _python_export() { PYTHON_SITEDIR) [[ -n ${PYTHON} ]] || die "PYTHON needs to be set for ${var} to be exported, or requested before it" PYTHON_SITEDIR=$( - "${PYTHON}" - <<-EOF || die - import sysconfig - print(sysconfig.get_path("purelib")) + "${PYTHON}" - "${EPREFIX}/usr" <<-EOF || die + import sys, sysconfig + print(sysconfig.get_path("purelib", vars={"base": sys.argv[1]})) EOF ) - PYTHON_SITEDIR=${EPREFIX}${PYTHON_SITEDIR#"${BROOT-${EPREFIX}}"} export PYTHON_SITEDIR debug-print "${FUNCNAME}: PYTHON_SITEDIR = ${PYTHON_SITEDIR}" ;; PYTHON_INCLUDEDIR) [[ -n ${PYTHON} ]] || die "PYTHON needs to be set for ${var} to be exported, or requested before it" PYTHON_INCLUDEDIR=$( - "${PYTHON}" - <<-EOF || die - import sysconfig - print(sysconfig.get_path("platinclude")) + "${PYTHON}" - "${ESYSROOT}/usr" <<-EOF || die + import sys, sysconfig + print(sysconfig.get_path("platinclude", vars={"installed_platbase": sys.argv[1]})) EOF ) - PYTHON_INCLUDEDIR=${ESYSROOT}${PYTHON_INCLUDEDIR#"${BROOT-${EPREFIX}}"} export PYTHON_INCLUDEDIR debug-print "${FUNCNAME}: PYTHON_INCLUDEDIR = ${PYTHON_INCLUDEDIR}" @@ -1244,10 +1242,6 @@ _python_check_EPYTHON() { _python_check_occluded_packages() { debug-print-function ${FUNCNAME} "${@}" - # DO NOT ENABLE THIS unless you're going to check for false - # positives before filing bugs. - [[ ! ${PYTHON_EXPERIMENTAL_QA} ]] && return - [[ -z ${BUILD_DIR} || ! -d ${BUILD_DIR}/install ]] && return local sitedir="${BUILD_DIR}/install$(python_get_sitedir)"