summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCharlie Li <vishwin@FreeBSD.org>2025-03-07 21:15:28 -0500
committerCharlie Li <vishwin@FreeBSD.org>2025-03-07 23:05:17 -0500
commitbc7ed2ccd62e3bb0b76cea6f261558a121aa422a (patch)
tree2b3f282269dcf93c7a653eb4be8d58b1459f2730
parentx11-wm/notion: New port: Tiling tabbed window manager (diff)
python.mk: remove setuptools from RUN_DEPENDS
Historically this was needed as a RUN_DEPENDS due to consumers using the included pkg_resources, which has been deprecated for some time now in favour of the importlib suite. (pkg_resources consumers are strongly advised to migrate to importlib et al.) PR: 270510 Reviewed by: crees, rm Tested by: jhale, wen exp-run by: antoine Differential Revision: https://reviews.freebsd.org/D39303
-rw-r--r--CHANGES20
-rw-r--r--Mk/Uses/python.mk1
2 files changed, 20 insertions, 1 deletions
diff --git a/CHANGES b/CHANGES
index e28cfeb8c787..adcffeea0b9f 100644
--- a/CHANGES
+++ b/CHANGES
@@ -10,6 +10,26 @@ in the release notes and/or placed into UPDATING.
All ports committers are allowed to commit to this file.
+20250307:
+AUTHOR: python@FreeBSD.org
+
+ setuptools has been removed as a RUN_DEPENDS for USE_PYTHON=distutils
+ ports, except for those operating under Python 2. If your port
+ needs setuptools to run, you can add it back to RUN_DEPENDS, but
+ keep in mind that this practice is deprecated and discouraged in
+ the greater Python ecosystem.
+
+ setuptools includes a module, pkg_resources, that historically
+ has been used as a runtime API for "finding, introspecting,
+ activating and using installed Python distributions." These
+ functions have been superseded by the importlib family and the
+ packaging package.
+
+ setuptools also includes their own copy of distutils, which is
+ not present in the base Python distribution starting in 3.12. The
+ use of distutils primitives directly in consumers is also discouraged
+ and deprecated.
+
20250306:
AUTHOR: jhale@FreeBSD.org
diff --git a/Mk/Uses/python.mk b/Mk/Uses/python.mk
index 6c3b0681032a..5159c006b9da 100644
--- a/Mk/Uses/python.mk
+++ b/Mk/Uses/python.mk
@@ -675,7 +675,6 @@ BUILD_DEPENDS+= ${PYTHON_PKGNAMEPREFIX}setuptools44>0:devel/py-setuptools44@${P
RUN_DEPENDS+= ${PYTHON_PKGNAMEPREFIX}setuptools44>0:devel/py-setuptools44@${PY_FLAVOR}
. else
BUILD_DEPENDS+= ${PYTHON_PKGNAMEPREFIX}setuptools>=63.1.0:devel/py-setuptools@${PY_FLAVOR}
-RUN_DEPENDS+= ${PYTHON_PKGNAMEPREFIX}setuptools>=63.1.0:devel/py-setuptools@${PY_FLAVOR}
. endif
. endif