diff options
author | Sam James <sam@gentoo.org> | 2024-01-22 11:25:05 +0000 |
---|---|---|
committer | Sam James <sam@gentoo.org> | 2024-01-22 11:26:10 +0000 |
commit | d2a3cfe3b625829a894f700da57795327a9cbe92 (patch) | |
tree | 4ad92052f7d6402d147713fff8c96c56bc1f2486 /dev-util/gdbus-codegen | |
parent | net-misc/iperf: Stabilize 3.16 hppa, #921306 (diff) | |
download | gentoo-d2a3cfe3b625829a894f700da57795327a9cbe92.tar.gz gentoo-d2a3cfe3b625829a894f700da57795327a9cbe92.tar.bz2 gentoo-d2a3cfe3b625829a894f700da57795327a9cbe92.zip |
dev-util/gdbus-codegen: patch out distutils use
Just like the fix from bug #922654, but utils.py gets installed, so we need
to make sure we both patch it here too & add dev-python/packaging to RDEPEND.
Thanks to leio for pointing it out.
Bug: https://bugs.gentoo.org/919904
Bug: https://bugs.gentoo.org/922654
Fixes: 214971a1af7edd43d423a590d17f8cff8f36526e
Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'dev-util/gdbus-codegen')
-rw-r--r-- | dev-util/gdbus-codegen/files/gdbus-codegen-2.78.4-distutils.patch | 36 | ||||
-rw-r--r-- | dev-util/gdbus-codegen/gdbus-codegen-2.78.4-r1.ebuild (renamed from dev-util/gdbus-codegen/gdbus-codegen-2.78.4.ebuild) | 8 |
2 files changed, 43 insertions, 1 deletions
diff --git a/dev-util/gdbus-codegen/files/gdbus-codegen-2.78.4-distutils.patch b/dev-util/gdbus-codegen/files/gdbus-codegen-2.78.4-distutils.patch new file mode 100644 index 000000000000..38fbe0e1a9b5 --- /dev/null +++ b/dev-util/gdbus-codegen/files/gdbus-codegen-2.78.4-distutils.patch @@ -0,0 +1,36 @@ +https://bugs.gentoo.org/922654 +https://gitlab.gnome.org/GNOME/glib/-/issues/3134 +https://gitlab.gnome.org/GNOME/glib/-/commit/6ef967a0f930ce37a8c9b5aff969693b34714291 + +[sam: Trimmed the CI changes.] + +From 6ef967a0f930ce37a8c9b5aff969693b34714291 Mon Sep 17 00:00:00 2001 +From: Jordan Williams <jordan@jwillikers.com> +Date: Fri, 1 Dec 2023 09:53:50 -0600 +Subject: [PATCH] Switch from the deprecated distutils module to the packaging + module + +The distutils module was removed in Python 3.12. +--- + +--- a/utils.py ++++ b/utils.py +@@ -19,7 +19,7 @@ + # + # Author: David Zeuthen <davidz@redhat.com> + +-import distutils.version ++import packaging.version + import os + import sys + +@@ -166,4 +166,4 @@ def version_cmp_key(key): + v = str(key[0]) + else: + v = "0" +- return (distutils.version.LooseVersion(v), key[1]) ++ return (packaging.version.Version(v), key[1]) +-- +GitLab + + diff --git a/dev-util/gdbus-codegen/gdbus-codegen-2.78.4.ebuild b/dev-util/gdbus-codegen/gdbus-codegen-2.78.4-r1.ebuild index a859319309e2..00234d0e217a 100644 --- a/dev-util/gdbus-codegen/gdbus-codegen-2.78.4.ebuild +++ b/dev-util/gdbus-codegen/gdbus-codegen-2.78.4-r1.ebuild @@ -17,7 +17,12 @@ LICENSE="LGPL-2+" SLOT="0" KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~x64-macos" -RDEPEND="${PYTHON_DEPS}" +RDEPEND=" + ${PYTHON_DEPS} + $(python_gen_cond_dep ' + dev-python/packaging[${PYTHON_USEDEP}] + ') +" DEPEND="${RDEPEND}" BDEPEND=" dev-libs/libxslt @@ -29,6 +34,7 @@ S="${WORKDIR}/glib-${PV}/gio/gdbus-2.0/codegen" python_prepare_all() { PATCHES=( "${FILESDIR}/${PN}-2.56.1-sitedir.patch" + "${FILESDIR}/${PN}-2.78.4-distutils.patch" ) distutils-r1_python_prepare_all |