Gentoo Archives: gentoo-dev

From: "Michał Górny" <mgorny@g.o>
To: gentoo-dev@l.g.o
Cc: python@g.o, "Michał Górny" <mgorny@g.o>
Subject: [gentoo-dev] [PATCH v2 00/20] python-r2 suite
Date: Thu, 05 Mar 2020 15:10:57
Message-Id: 20200305151024.125834-1-mgorny@gentoo.org
Hi,

Here's the second iteration of python-r2 proposal.  This time I've
decided to follow purely the approach of lint-safe changes.  Most
of the conversions would be doable via script, the remaining
incompatibilities would be detectable via script.

A wip version of the script is at [1].  Right now it just detects use
of deprecated EAPIs (including python.eclass leftovers), I will add API
update support later on.  FWICS it has two false positives right now
but I think that's good enough.  To do better, we'd have to employ
a proper bash parser.


Differences from patch v1:

- rebased on cleaned up python-r1 suite (so changes applicable to -r1
  were merged there)

- lowered DISTUTILS_USE_SETUPTOOLS warnings to non-fatal again, as this
  is something that can be detected only at runtime


Overall changes from python-r1 suite:

- the following deprecated API were removed:
  - EXAMPLES -- they were banned in EAPI 7 already yet people kept
                failing to remove them anyway
  - distutils-r2_python_{prepare,configure} -- no-op defaults
  - python_gen_usedep -- deprecated in favor of python_gen_cond_dep

- the following functions were made private:
  - python_wrapper_setup (part of python_setup)
  - python_is_installed (internal since inception)
  - python_export (in favor of python_get*)

- PYTHON_MULTI_USEDEP was renamed back to PYTHON_USEDEP for consistency
  between eclasses (but still needs python_gen_cond_dep in p-s-r1)

- python-r1 becomes python-multi-r2

- distutils-r2 now passes --skip-build to install target -- this is
  the only potentially breaking change but the potential is really
  minimal, so we should catch it via testing the eclasses


[1] https://github.com/mgorny/pymighelper


Michał Górny (20):
  eclass: Copy python-r1 suite to python-r2
  distutils-r2.eclass: Remove EXAMPLES
  distutils-r2.eclass: Remove no-op subphase defaults
  distutils-r2.eclass: Remove distutils.eclass checks
  python-r2.eclass: Remove python_gen_usedep
  python-utils-r2.eclass: Remove python.eclass checks
  python-utils-r2.eclass: Mark python_wrapper_setup private
  python-utils-r2.eclass: Mark python_is_installed private
  python-utils-r2.eclass: Fix obsolete docs on python_export_best
  python-utils-r2.eclass: Mark python_export private
  python-utils-r2.eclass: Remove PYTHON_SITEDIR export
  python-utils-r2.eclass: Remove PYTHON_INCLUDEDIR export
  python-utils-r2.eclass: Remove PYTHON_LIBPATH export
  python-utils-r2.eclass: Remove PYTHON_CFLAGS export
  python-utils-r2.eclass: Remove PYTHON_LIBS export
  python-utils-r2.eclass: Remove PYTHON_CONFIG export
  python-utils-r2.eclass: Remove PYTHON_SCRIPTDIR export
  python-single-r2.eclass: PYTHON_MULTI_USEDEP → PYTHON_USEDEP
  distutils-r2.eclass: Pass --skip-build to install
  eclass: python-r2.eclass → python-multi-r2.eclass

 eclass/distutils-r2.eclass      | 1109 +++++++++++++++++++++++++++++
 eclass/python-any-r2.eclass     |  363 ++++++++++
 eclass/python-multi-r2.eclass   |  786 ++++++++++++++++++++
 eclass/python-single-r2.eclass  |  512 ++++++++++++++
 eclass/python-utils-r2.eclass   | 1180 +++++++++++++++++++++++++++++++
 eclass/tests/distutils-r2.sh    |   98 +++
 eclass/tests/python-utils-r2.sh |  250 +++++++
 7 files changed, 4298 insertions(+)
 create mode 100644 eclass/distutils-r2.eclass
 create mode 100644 eclass/python-any-r2.eclass
 create mode 100644 eclass/python-multi-r2.eclass
 create mode 100644 eclass/python-single-r2.eclass
 create mode 100644 eclass/python-utils-r2.eclass
 create mode 100755 eclass/tests/distutils-r2.sh
 create mode 100755 eclass/tests/python-utils-r2.sh

-- 
2.25.1

Replies

Subject Author
[gentoo-dev] [PATCH v2 01/20] eclass: Copy python-r1 suite to python-r2 "Michał Górny" <mgorny@g.o>
[gentoo-dev] [PATCH v2 02/20] distutils-r2.eclass: Remove EXAMPLES "Michał Górny" <mgorny@g.o>
[gentoo-dev] [PATCH v2 03/20] distutils-r2.eclass: Remove no-op subphase defaults "Michał Górny" <mgorny@g.o>
[gentoo-dev] [PATCH v2 04/20] distutils-r2.eclass: Remove distutils.eclass checks "Michał Górny" <mgorny@g.o>
[gentoo-dev] [PATCH v2 05/20] python-r2.eclass: Remove python_gen_usedep "Michał Górny" <mgorny@g.o>
[gentoo-dev] [PATCH v2 06/20] python-utils-r2.eclass: Remove python.eclass checks "Michał Górny" <mgorny@g.o>
[gentoo-dev] [PATCH v2 07/20] python-utils-r2.eclass: Mark python_wrapper_setup private "Michał Górny" <mgorny@g.o>
[gentoo-dev] [PATCH v2 08/20] python-utils-r2.eclass: Mark python_is_installed private "Michał Górny" <mgorny@g.o>
[gentoo-dev] [PATCH v2 10/20] python-utils-r2.eclass: Mark python_export private "Michał Górny" <mgorny@g.o>
[gentoo-dev] [PATCH v2 09/20] python-utils-r2.eclass: Fix obsolete docs on python_export_best "Michał Górny" <mgorny@g.o>
[gentoo-dev] [PATCH v2 11/20] python-utils-r2.eclass: Remove PYTHON_SITEDIR export "Michał Górny" <mgorny@g.o>
[gentoo-dev] [PATCH v2 12/20] python-utils-r2.eclass: Remove PYTHON_INCLUDEDIR export "Michał Górny" <mgorny@g.o>
[gentoo-dev] [PATCH v2 13/20] python-utils-r2.eclass: Remove PYTHON_LIBPATH export "Michał Górny" <mgorny@g.o>
[gentoo-dev] [PATCH v2 14/20] python-utils-r2.eclass: Remove PYTHON_CFLAGS export "Michał Górny" <mgorny@g.o>
[gentoo-dev] [PATCH v2 15/20] python-utils-r2.eclass: Remove PYTHON_LIBS export "Michał Górny" <mgorny@g.o>
[gentoo-dev] [PATCH v2 16/20] python-utils-r2.eclass: Remove PYTHON_CONFIG export "Michał Górny" <mgorny@g.o>
[gentoo-dev] [PATCH v2 17/20] python-utils-r2.eclass: Remove PYTHON_SCRIPTDIR export "Michał Górny" <mgorny@g.o>
[gentoo-dev] [PATCH v2 18/20] python-single-r2.eclass: PYTHON_MULTI_USEDEP → PYTHON_USEDEP "Michał Górny" <mgorny@g.o>
[gentoo-dev] [PATCH v2 19/20] distutils-r2.eclass: Pass --skip-build to install "Michał Górny" <mgorny@g.o>
[gentoo-dev] [PATCH v2 20/20] eclass: python-r2.eclass → python-multi-r2.eclass "Michał Górny" <mgorny@g.o>