• [gentoo-dev] [PATCH 0/4] distutils-r1.eclass: cross support + minor upd

    From =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?@21:1/5 to All on Mon Dec 12 07:20:01 2022
    Hi,

    More patches to the last batch:

    1. Fix build system package version output to work on cross (via passing
    `-b` to best_version calls).

    2. Add support for gpep517-12+ `--sysroot` option for better cross
    support. Since this is only needed by some packages, we do not make
    gpep-517-12+ requirement obligatory at this point and just warn when
    cross-compiling with an older version.

    3. Update minimum versions of dev-lang/python and dev-python/pypy3,
    as well as clean the tests up after removing dead implementations.


    Michał Górny (4):
    distutils-r1.eclass: Pass -b to best_version for buildsys pkgs
    distutils-r1.eclass: Pass --sysroot to gpep517 when cross-compiling
    eclass/tests/python-utils-r1.sh: Remove old impls
    python-utils.eclass: Bump minimal Python versions

    eclass/distutils-r1.eclass | 21 +++++++++++++++------
    eclass/python-utils-r1.eclass | 12 +++++-------
    eclass/tests/python-utils-r1.sh | 18 +-----------------
    3 files changed, 21 insertions(+), 30 deletions(-)

    --
    2.38.2

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?@21:1/5 to All on Mon Dec 12 07:30:01 2022
    Bump minimal Python versions after the last security stabilizations,
    plus PyPy3 sysconfig bugfix.

    Signed-off-by: Michał Górny <mgorny@gentoo.org>
    ---
    eclass/python-utils-r1.eclass | 12 +++++-------
    1 file changed, 5 insertions(+), 7 deletions(-)

    diff --git a/eclass/python-utils-r1.eclass b/eclass/python-utils-r1.eclass index df955371483e..d7b3df6105ab 100644
    --- a/eclass/python-utils-r1.eclass
    +++ b/eclass/python-utils-r1.eclass
    @@ -445,17 +445,15 @@ _python_export() {
    local d
    case ${impl} in
    python3.8)
    - PYTHON_PKG_DEP=">=dev-lang/python-3.8.15_p3:3.8";;
    + PYTHON_PKG_DEP=">=dev-lang/python-3.8.16:3.8";;
    python3.9)
    - PYTHON_PKG_DEP=">=dev-lang/python-3.9.15_p3:3.9";;
    + PYTHON_PKG_DEP=">=dev-lang/python-3.9.16:3.9";;
    python3.10)
    - PYTHON_PKG_DEP=">=dev-lang/python-3.10.8_p3:3.10";;
    + PYTHON_PKG_DEP=">=dev-lang/python-3.10.9:3.10";;
    python3.11)
    - PYTHON_PKG_DEP=">=dev-lang/python-3.11.0_p2:3.11";;
    - python*)
    - PYTHON_PKG_DEP="dev-lang/python:${impl#python}";;
    + PYTHON_PKG_DEP=">=dev-lang/python-3.11.1:3.11";;
    pypy3)
    - PYTHON_PKG_DEP=
  • From =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?@21:1/5 to All on Mon Dec 12 07:30:01 2022
    Signed-off-by: Michał Górny <mgorny@gentoo.org>
    ---
    eclass/distutils-r1.eclass | 19 ++++++++++++++-----
    1 file changed, 14 insertions(+), 5 deletions(-)

    diff --git a/eclass/distutils-r1.eclass b/eclass/distutils-r1.eclass
    index 6e8ff5467bdb..371d52bcb7ef 100644
    --- a/eclass/distutils-r1.eclass
    +++ b/eclass/distutils-r1.eclass
    @@ -1033,6 +1033,11 @@ distutils-r1_python_prepare_all() {
    python_export_utf8_locale
    _distutils-r1_print_package_versions

    + if [[ -n ${SYSROOT} ]] && ! has_version -b ">=dev-python/gpep517-12"; then
    + ewarn ">=dev-python/gpep517-12 features cross-compilation fixes."
    + ewarn "Please consider upgrading to avoid issues."
    + fi
    +
    _DISTUTILS_DEFAULT_CALLED=1
    }

    @@ -1356,16 +1361,18 @@ distutils_pep517_install() {

    local build_backend=$(_distutils-r1_get_backend)
    einfo " Building the wheel for ${PWD#${WORKDIR}/} via ${build_backend}"
    - local config_args=()
    - [[ -n ${config_settings} ]] &&
    - config_args+=( --config-json "${config_settings}" )
    local cmd=(
    gpep517 build-wheel
    --backend "$