From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 011C9C433F5 for ; Tue, 11 Jan 2022 19:38:07 +0000 (UTC) Received: from mail-ua1-f43.google.com (mail-ua1-f43.google.com [209.85.222.43]) by mx.groups.io with SMTP id smtpd.web12.12898.1641929886265824370 for ; Tue, 11 Jan 2022 11:38:06 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20210112 header.b=LK+NcbQm; spf=pass (domain: gmail.com, ip: 209.85.222.43, mailfrom: alex.kanavin@gmail.com) Received: by mail-ua1-f43.google.com with SMTP id o1so578868uap.4 for ; Tue, 11 Jan 2022 11:38:06 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=rwrKkM516zOmtl/Ps71qE8t+8yz69OFYQkY/V11x36M=; b=LK+NcbQmPWd3O9Ss53K1ttagf88AxVPr2wDpWDufwxD0XnI9qrmXaHTrfpYU8tj0mM nOxjmJ0lZfrClc3Cg6UDKITCyFVac5L0neIEU6wVs663oCiDHHo/Gr8mYJ01hKMzk/Dm zI2ey4o5V1z6XNwFiVFByICpFzeNgcbzTg9w17IU3hbVxyZuz/0sh9ID2/aNROGG3GYN mtV5kx0YI6KRyhgU4MXjJnOp5rV3NNz32nmRcisRQI0qZhEVubWdtQUigWn8WT6F5cb1 pUVKQ9l5tiG/kROcr3ImSlZD9jBM6zD9dnPG5JDjCDEH5zT6QnyXEhZyoSngtV8infaT X7mw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=rwrKkM516zOmtl/Ps71qE8t+8yz69OFYQkY/V11x36M=; b=Ij+qroZhGpnb1SvGrncWvMHVIf4nN2qdS75Y8Qy6yTqoVYSnDx7z3w2biU8c3x3TMT Uq9LAg6b8QYI5o6xbEXhPkCw0qjhDfh9LZkGMtrSRECju7i+TJLRoIhs4EBiPJP9435v LTzdH9hsFng2Fjoq0v0OSN0G2c6Jy5Vuf4ldWMSF8QP3qy7sI6oKAlOEe/Vmsmbybweq WoN+XUcFYKhcrV+WtCMjWP8vIvbgKVhAU2hpUh/7N4LByXz2o7bC6J7LVYObkvzU+x6N pls1Rr28zRu2p0ItUGd04/N3XOpUyP2zcwzq+Zsb5cISOFr5VE3HgTj+LWL76c+OXS1C qFVA== X-Gm-Message-State: AOAM532wV/virXwSOdTYd+61aPK8a/zDcr1rXFbnnLaPpS8RlPzgJCSN IetUBdKlb6usmvVOzL3ukScA9Lcas+KT/LEq1Y0= X-Google-Smtp-Source: ABdhPJx0V3O6heIbJ/shiJG17OVo08jta0IwPiozHrnWu9hwOIKBIXbb/uroG1V/jl0l42wtMFbSRkS874GC8Se69Aw= X-Received: by 2002:a67:c40e:: with SMTP id c14mr2457488vsk.73.1641929885234; Tue, 11 Jan 2022 11:38:05 -0800 (PST) MIME-Version: 1.0 References: In-Reply-To: From: Alexander Kanavin Date: Tue, 11 Jan 2022 20:37:53 +0100 Message-ID: Subject: Re: [OE-core] [PATCH v2 00/22] deprecation of distutils To: Tim Orling Cc: OE-core Content-Type: multipart/alternative; boundary="0000000000008e39c805d553979f" List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Tue, 11 Jan 2022 19:38:06 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/160459 --0000000000008e39c805d553979f Content-Type: text/plain; charset="UTF-8" Thanks Tim, does this address the issue of building items that don't ship a setup.py anymore? Alex On Tue, 11 Jan 2022 at 20:01, Tim Orling wrote: > distutils is deprecated in Python 3.10 and will be removed in Python > 3.12 (~October 2023). > > This series inserts a deprecation warning into the distutils*.bbclasses > and drops or replaces distutils usage wherever possible. > > Instead of distutils3-base, we introduce setuptools3-base, which also > incorporates distutils-common-base. > > Remaining usage is in: > * lib/recipetool/create_buildsys_python.py until we are ready to > factor it out (and add pyproject.toml and setup.cfg handling) > * oeqa selftests which are testing distutils3 functionality > * glib-2.0: upstream is still using distutils.version.LooseVersion > * gpgme: Still checks for distutils in m4/ax_python_devel.m4 > * python3-numpy: upstream still has a distutils/ module > * python3-setuptools has a vendored _distutils > > I might have missed something else. > > No attempt has been made to look at layers outside of oe-core. > > The intent is to let this percolate for a few weeks and then drop > distutils*.bbclasses (and move them to meta-python, but with the > warnings). > > [YOCTO #14610] > > Changes in v2: > - dropped the import of distutils.version into bb. in favor of > bb.utils.vercmp_string_op() > - dropped some patches that have been addressed already > - update email > - fix typos > - drop already merged scripts/buildhistory-diff patch > The following changes since commit > 16110cdca7211b0efc59464afbb253527c033cad: > > oeqa/sstate: Fix allarch samesigs test (2022-01-11 15:48:11 +0000) > > are available in the Git repository at: > > git://git.yoctoproject.org/git/poky-contrib > timo/deprecate_distutils_14610_v2 > > http://git.yoctoproject.org/cgit.cgi/git/poky-contrib/log/?h=timo/deprecate_distutils_14610_v2 > > Tim Orling (22): > classes/distutils-*: add warning of deprecation > setuptools3: refactor for no distutils bbclasses > python3-cython: DISTUTILS_* -> SETUPTOOLS_* > dnf: inherit setuptools3-base instead of distutils > libdnf: inherit setuptools3-base not distutils > python3-dbus: inherit setuptools3-base not distuils > gpgme: inherit setuptools-base not distuils > python3-pip: inherit setuptools3 not distuils3 > systemtap: use setuptools-base not distutils > libcomps: inherit setuptools3-base not distutils > createrepo-c: inherit setuptools3-base not distutils > librepo: inherit setuptools3-base not distutils > btrfs-tools: use setuptools3-base not distutils > python3-pygobject: setuptools instead of distuils > bind: inherit setuptools3-base instead of distutils > python3-setuptools: do not depend on distutils > gstreamer1.0-python: inherit setuptools3-base > recipetool/create_buildsys_python.py: less distutils > waf.bbclass: drop usage of distutils > dnf: drop python3-distutils dependency > python3native.bbclass: distutils -> sysconfig > rootfs_rpm.bbclass: distutils -> sysconfig module > > meta/classes/distutils-common-base.bbclass | 3 + > meta/classes/distutils3-base.bbclass | 3 + > meta/classes/distutils3.bbclass | 4 ++ > meta/classes/python3native.bbclass | 2 +- > meta/classes/rootfs_rpm.bbclass | 2 +- > meta/classes/setuptools3-base.bbclass | 31 +++++++++ > meta/classes/setuptools3.bbclass | 66 ++++++++++++++++++- > meta/classes/waf.bbclass | 3 +- > .../recipes-connectivity/bind/bind_9.16.24.bb | 2 +- > .../btrfs-tools/btrfs-tools_5.15.1.bb | 2 +- > .../createrepo-c/createrepo-c_0.18.0.bb | 2 +- > meta/recipes-devtools/dnf/dnf_4.10.0.bb | 3 +- > .../libcomps/libcomps_0.1.18.bb | 2 +- > meta/recipes-devtools/libdnf/libdnf_0.65.0.bb | 2 +- > .../librepo/librepo_1.14.2.bb | 2 +- > .../python/python3-cython_0.29.26.bb | 2 +- > .../python/python3-dbus_1.2.18.bb | 2 +- > .../python/python3-pip_21.3.1.bb | 2 +- > .../python/python3-pygobject_3.42.0.bb | 2 +- > .../python/python3-setuptools_59.5.0.bb | 1 - > .../recipes-kernel/systemtap/systemtap_git.bb | 2 +- > .../gstreamer/gstreamer1.0-python_1.18.5.bb | 2 +- > meta/recipes-support/gpgme/gpgme_1.16.0.bb | 2 +- > .../lib/recipetool/create_buildsys_python.py | 8 ++- > 24 files changed, 129 insertions(+), 23 deletions(-) > create mode 100644 meta/classes/setuptools3-base.bbclass > > -- > 2.30.2 > > > -=-=-=-=-=-=-=-=-=-=-=- > Links: You receive all messages sent to this group. > View/Reply Online (#160436): > https://lists.openembedded.org/g/openembedded-core/message/160436 > Mute This Topic: https://lists.openembedded.org/mt/88356412/1686489 > Group Owner: openembedded-core+owner@lists.openembedded.org > Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [ > alex.kanavin@gmail.com] > -=-=-=-=-=-=-=-=-=-=-=- > > --0000000000008e39c805d553979f Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Thanks Tim, does this address the issue of building i= tems that don't ship a setup.py anymore?

Alex<= br>

On Tue, 11 Jan 2022 at 20:01, Tim Orling <ticotimo@gmail.com> wrote:
distutils is deprecated in Python 3.10 a= nd will be removed in Python
3.12 (~October 2023).

This series inserts a deprecation warning into the distutils*.bbclasses
and drops or replaces distutils usage wherever possible.

Instead of distutils3-base, we introduce setuptools3-base, which also
incorporates distutils-common-base.

Remaining usage is in:
=C2=A0 * lib/recipetool/create_buildsys_python.py until we are ready to
=C2=A0 =C2=A0 factor it out (and add pyproject.toml and setup.cfg handling)=
=C2=A0 * oeqa selftests which are testing distutils3 functionality
=C2=A0 * glib-2.0: upstream is still using distutils.version.LooseVersion =C2=A0 * gpgme: Still checks for distutils in m4/ax_python_devel.m4
=C2=A0 * python3-numpy: upstream still has a distutils/ module
=C2=A0 * python3-setuptools has a vendored _distutils

I might have missed something else.

No attempt has been made to look at layers outside of oe-core.

The intent is to let this percolate for a few weeks and then drop
distutils*.bbclasses (and move them to meta-python, but with the
warnings).

[YOCTO #14610]

Changes in v2:
=C2=A0 - dropped the import of distutils.version into bb. in favor of
=C2=A0 =C2=A0 bb.utils.vercmp_string_op()
=C2=A0 - dropped some patches that have been addressed already
=C2=A0 - update email
=C2=A0 - fix typos
=C2=A0 - drop already merged scripts/buildhistory-diff patch
The following changes since commit 16110cdca7211b0efc59464afbb253527c033cad= :

=C2=A0 oeqa/sstate: Fix allarch samesigs test (2022-01-11 15:48:11 +0000)
are available in the Git repository at:

=C2=A0 git://git.yoctoproject.org/git/poky-contrib= timo/deprecate_distutils_14610_v2
=C2=A0 http://git.yoctoproject.org/cgit.cgi/git/poky-contrib/log/?h=3Dtimo/depr= ecate_distutils_14610_v2

Tim Orling (22):
=C2=A0 classes/distutils-*: add warning of deprecation
=C2=A0 setuptools3: refactor for no distutils bbclasses
=C2=A0 python3-cython: DISTUTILS_* -> SETUPTOOLS_*
=C2=A0 dnf: inherit setuptools3-base instead of distutils
=C2=A0 libdnf: inherit setuptools3-base not distutils
=C2=A0 python3-dbus: inherit setuptools3-base not distuils
=C2=A0 gpgme: inherit setuptools-base not distuils
=C2=A0 python3-pip: inherit setuptools3 not distuils3
=C2=A0 systemtap: use setuptools-base not distutils
=C2=A0 libcomps: inherit setuptools3-base not distutils
=C2=A0 createrepo-c: inherit setuptools3-base not distutils
=C2=A0 librepo: inherit setuptools3-base not distutils
=C2=A0 btrfs-tools: use setuptools3-base not distutils
=C2=A0 python3-pygobject: setuptools instead of distuils
=C2=A0 bind: inherit setuptools3-base instead of distutils
=C2=A0 python3-setuptools: do not depend on distutils
=C2=A0 gstreamer1.0-python: inherit setuptools3-base
=C2=A0 recipetool/create_buildsys_python.py: less distutils
=C2=A0 waf.bbclass: drop usage of distutils
=C2=A0 dnf: drop python3-distutils dependency
=C2=A0 python3native.bbclass: distutils -> sysconfig
=C2=A0 rootfs_rpm.bbclass: distutils -> sysconfig module

=C2=A0meta/classes/distutils-common-base.bbclass=C2=A0 =C2=A0 |=C2=A0 3 + =C2=A0meta/classes/distutils3-base.bbclass=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 |=C2=A0 3 +
=C2=A0meta/classes/distutils3.bbclass=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0|=C2=A0 4 ++
=C2=A0meta/classes/python3native.bbclass=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 |=C2=A0 2 +-
=C2=A0meta/classes/rootfs_rpm.bbclass=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0|=C2=A0 2 +-
=C2=A0meta/classes/setuptools3-base.bbclass=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0| 31 +++++++++
=C2=A0meta/classes/setuptools3.bbclass=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 | 66 ++++++++++++++++++-
=C2=A0meta/classes/waf.bbclass=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 |=C2=A0 3 +-
=C2=A0.../recipes-connectivity/bind/bind_9.16.24.bb |=C2=A0 2 +-
=C2=A0.../btrfs-tools/btrfs-tools_5.15.1.bb=C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0|=C2=A0 2 +-
=C2=A0.../createrepo-c/createrepo-c_0.18.0.bb=C2=A0 =C2=A0 =C2=A0 = =C2=A0|=C2=A0 2 +-
=C2=A0meta/recipes-devtools/dnf/dnf_4.10.0.bb=C2=A0 =C2=A0 =C2=A0 =C2=A0|=C2= =A0 3 +-
=C2=A0.../libcomps/libcomps_0.1.18.bb=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0= =C2=A0 =C2=A0 =C2=A0|=C2=A0 2 +-
=C2=A0meta/recipes-devtools/libdnf/libdnf_0.65.0.bb |=C2=A0 2 +-
=C2=A0.../librepo/librepo_1.14.2.bb=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0|=C2=A0 2 +-
=C2=A0.../python/python3-cython_0.29.26.bb=C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 |=C2=A0 2 +-
=C2=A0.../python/python3-dbus_1.2.18.bb=C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0|=C2=A0 2 +-
=C2=A0.../python/python3-pip_21.3.1.bb=C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 |=C2=A0 2 +-
=C2=A0.../python/python3-pygobject_3.42.0.bb=C2=A0 =C2=A0 =C2= =A0 =C2=A0 |=C2=A0 2 +-
=C2=A0.../python/python3-setuptools_59.5.0.bb=C2=A0 =C2=A0 = =C2=A0 =C2=A0|=C2=A0 1 -
=C2=A0.../recipes-kernel/systemtap/systemtap_git.bb |=C2=A0 2 +-
=C2=A0.../gstreamer/gstreamer1.0-python_1.18.5.bb=C2=A0 =C2= =A0|=C2=A0 2 +-
=C2=A0meta/recipes-support/gpgme/gpgme_1.16.0.bb=C2=A0 =C2=A0 |=C2=A0 2 +-=
=C2=A0.../lib/recipetool/create_buildsys_python.py=C2=A0 |=C2=A0 8 ++-
=C2=A024 files changed, 129 insertions(+), 23 deletions(-)
=C2=A0create mode 100644 meta/classes/setuptools3-base.bbclass

--
2.30.2


-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-
Links: You receive all messages sent to this group.
View/Reply Online (#160436): https:= //lists.openembedded.org/g/openembedded-core/message/160436
Mute This Topic: https://lists.openembedded.org/mt= /88356412/1686489
Group Owner: openembedded-core+owner@lists.openembedded.org<= br> Unsubscribe: https://lists.openembedded.org/= g/openembedded-core/unsub [alex.kanavin@gmail.com]
-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-

--0000000000008e39c805d553979f--