dev-lang/python sometimes used to install the epython module into the wrong libdir (e.g. lib vs lib64). The earlier eclass changes actually break the build entirely as sysconfigdata is now sourced from within SYSROOT, where it may not even be installed yet. This therefore needs to be handled as a special case where sysconfigdata is sourced from within ED instead.
Signed-off-by: James Le Cuirot <ch...@gentoo.org> --- eclass/python-utils-r1.eclass | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/eclass/python-utils-r1.eclass b/eclass/python-utils-r1.eclass index 91e457f3cf14..17de9ca9c44f 100644 --- a/eclass/python-utils-r1.eclass +++ b/eclass/python-utils-r1.eclass @@ -1028,7 +1028,11 @@ python_wrapper_setup() { # overridden but hopefully it will be somewhere under ${T}. local ${lpyvar}=$(PATH=${PATH//${T}//dev/null} type -P "${EPYTHON}" || die "${FUNCNAME}: can't find ${EPYTHON} in PATH") - local pysysroot=${ESYSROOT-${SYSROOT%/}${EPREFIX}} + if [[ ${CATEGORY}/${PN} == dev-lang/python ]]; then + local pysysroot=${ED%/} + else + local pysysroot=${ESYSROOT-${SYSROOT%/}${EPREFIX}} + fi if [[ ! -x ${workdir}/bin/python ]]; then _python_check_dead_variables -- 2.19.2