From bea744e8c1fe05e9aad12d8c86d550ef38e8bf14 Mon Sep 17 00:00:00 2001
From: Matthew Feickert <matthew.feickert@cern.ch>
Date: Wed, 30 Nov 2022 14:06:31 -0600
Subject: [PATCH 1/2] feat: Use setuptools over setuptools._distutils.core
Drop all usage of setuptools._distutils in favor of pure setuptools.
This effectively solves the problems that were present in the attempt
in https://github.com/xrootd/xrootd/pull/1585 and
https://github.com/xrootd/xrootd/pull/1700.
Co-authored-by: Henry Schreiner <henry.fredrick.schreiner@cern.ch>
---
bindings/python/setup.py.in | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/bindings/python/setup.py.in b/bindings/python/setup.py.in
index fbac3e6df..c5bbec503 100644
--- a/bindings/python/setup.py.in
+++ b/bindings/python/setup.py.in
@@ -3,7 +3,7 @@ from __future__ import print_function
# setuptools._distutils added in setuptools v48.0.0
# c.f. https://setuptools.pypa.io/en/latest/history.html#v48-0-0
try:
- from setuptools._distutils.core import setup, Extension
+ from setuptools import setup, Extension
# sysconfig v48.0.0+ is incompatible for Python 3.6 only, so fall back to distutils.
# Instead of checking setuptools.__version__ explicitly, use the knowledge that
# to get here in the 'try' block requires setuptools v48.0.0+.
--
2.39.0