commit:     4c42c36f5fdea8612cb824fbb6eeeeaed0719531
Author:     Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Mon Mar  8 19:04:33 2021 +0000
Commit:     Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Thu Mar 11 08:47:57 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4c42c36f

distutils-r1.eclass: Use underscores in .pydistutils.cfg keys

Switch to using underscore instead of hyphens in .pydistutils.cfg keys.
The latter form is now deprecated by setuptools, while both seem to work
fine with plain distutils.

Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>

 eclass/distutils-r1.eclass | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/eclass/distutils-r1.eclass b/eclass/distutils-r1.eclass
index 0e543412f64..4f21cfd9e4c 100644
--- a/eclass/distutils-r1.eclass
+++ b/eclass/distutils-r1.eclass
@@ -673,7 +673,7 @@ distutils-r1_python_configure() {
 _distutils-r1_create_setup_cfg() {
        cat > "${HOME}"/.pydistutils.cfg <<-_EOF_ || die
                [build]
-               build-base = ${BUILD_DIR}
+               build_base = ${BUILD_DIR}
 
                # using a single directory for them helps us export
                # ${PYTHONPATH} and ebuilds find the sources independently
@@ -682,16 +682,16 @@ _distutils-r1_create_setup_cfg() {
                # note: due to some packages (wxpython) relying on separate
                # platlib & purelib dirs, we do not set --build-lib (which
                # can not be overridden with --build-*lib)
-               build-platlib = %(build-base)s/lib
-               build-purelib = %(build-base)s/lib
+               build_platlib = %(build_base)s/lib
+               build_purelib = %(build_base)s/lib
 
                # make the ebuild writer lives easier
-               build-scripts = %(build-base)s/scripts
+               build_scripts = %(build_base)s/scripts
 
                # this is needed by distutils_install_for_testing since
                # setuptools like to create .egg files for install --home.
                [bdist_egg]
-               dist-dir = ${BUILD_DIR}/dist
+               dist_dir = ${BUILD_DIR}/dist
        _EOF_
 
        # we can't refer to ${D} before src_install()
@@ -708,7 +708,7 @@ _distutils-r1_create_setup_cfg() {
 
                if [[ ! ${DISTUTILS_SINGLE_IMPL} ]]; then
                        cat >> "${HOME}"/.pydistutils.cfg <<-_EOF_ || die
-                               install-scripts = $(python_get_scriptdir)
+                               install_scripts = $(python_get_scriptdir)
                        _EOF_
                fi
        fi

Reply via email to