commit:     6c7a7f2c99d77a5aed1dc21d9525a5f85fea5968
Author:     Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Tue Oct  8 15:17:52 2024 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Tue Oct  8 15:18:12 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6c7a7f2c

net-firewall/ufw: strip distutils use

Signed-off-by: Sam James <sam <AT> gentoo.org>

 net-firewall/ufw/files/ufw-0.36.1-distutils.patch          | 14 ++++++++++++++
 .../ufw/{ufw-0.36.1.ebuild => ufw-0.36.1-r1.ebuild}        |  6 +++---
 2 files changed, 17 insertions(+), 3 deletions(-)

diff --git a/net-firewall/ufw/files/ufw-0.36.1-distutils.patch 
b/net-firewall/ufw/files/ufw-0.36.1-distutils.patch
new file mode 100644
index 000000000000..fe7ab3845058
--- /dev/null
+++ b/net-firewall/ufw/files/ufw-0.36.1-distutils.patch
@@ -0,0 +1,14 @@
+https://src.fedoraproject.org/rpms/ufw/raw/rawhide/f/ufw-0.35-distutils-setuptools.patch
+--- a/setup.py
++++ b/setup.py
+@@ -26,8 +26,8 @@
+ #
+ 
+ from __future__ import print_function
+-from distutils.command.install import install as _install
+-from distutils.core import setup
++from setuptools.command.install import install as _install
++from setuptools import setup
+ import errno
+ import os
+ import re

diff --git a/net-firewall/ufw/ufw-0.36.1.ebuild 
b/net-firewall/ufw/ufw-0.36.1-r1.ebuild
similarity index 98%
rename from net-firewall/ufw/ufw-0.36.1.ebuild
rename to net-firewall/ufw/ufw-0.36.1-r1.ebuild
index b731656a901d..09b82a5878f8 100644
--- a/net-firewall/ufw/ufw-0.36.1.ebuild
+++ b/net-firewall/ufw/ufw-0.36.1-r1.ebuild
@@ -20,10 +20,8 @@ IUSE="examples ipv6"
 
 RDEPEND="net-firewall/iptables[ipv6(+)?]"
 BDEPEND="
+       dev-python/setuptools[${PYTHON_USEDEP}]
        sys-devel/gettext
-       $(python_gen_cond_dep '
-               dev-python/setuptools[${PYTHON_USEDEP}]
-       ' python3_12)
 "
 
 PATCHES=(
@@ -35,6 +33,8 @@ PATCHES=(
        "${FILESDIR}/${P}-shebang.patch"
        # Fix bash completions, bug #526300
        "${FILESDIR}/${PN}-0.36-bash-completion.patch"
+       # Strip distutils use
+       "${FILESDIR}/${PN}-0.36.1-distutils.patch"
 )
 
 pkg_pretend() {

Reply via email to