--- a/usr/lib64/portage/python3.4/phase-helpers.sh +++ b/usr/lib64/portage/python3.4/phase-helpers.sh @@ -590,7 +590,7 @@ econf() { fi local conf_args=() - if ___eapi_econf_passes_--disable-dependency-tracking || ___eapi_econf_passes_--disable-silent-rules || ___eapi_econf_passes_--docdir_and_--htmldir; then + if ___eapi_econf_passes_--disable-dependency-tracking || ___eapi_econf_passes_--disable-silent-rules || ___eapi_econf_passes_--docdir_and_--htmldir || [ -n "$SYSROOT" ] ; then local conf_help=$("${ECONF_SOURCE}/configure" --help 2>/dev/null) if ___eapi_econf_passes_--disable-dependency-tracking; then @@ -614,6 +614,11 @@ econf() { conf_args+=( --htmldir="${EPREFIX}"/usr/share/doc/${PF}/html ) fi fi + if [ -n "$SYSROOT" ] ; then + if [[ ${conf_help} == *--with-sysroot* ]]; then + conf_args+=( --with-sysroot="${SYSROOT}" ) + fi + fi fi # if the profile defines a location to install libs to aside from default, pass it on.