[PATCH 02/18] py: Replace distutils.core with setuptools

Jiaxun Yang jiaxun.yang at flygoat.com
Wed Jul 17 16:29:13 CEST 2024


distutils is deprecated long ago and being removed in python 3.12.

Signed-off-by: Jiaxun Yang <jiaxun.yang at flygoat.com>
---
 tools/binman/setup.py           | 2 +-
 tools/buildman/requirements.txt | 1 +
 tools/dtoc/setup.py             | 2 +-
 3 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/tools/binman/setup.py b/tools/binman/setup.py
index 9a9206eb044a..bec078a3d9b1 100644
--- a/tools/binman/setup.py
+++ b/tools/binman/setup.py
@@ -1,6 +1,6 @@
 # SPDX-License-Identifier: GPL-2.0+
 
-from distutils.core import setup
+from setuptools import setup
 setup(name='binman',
       version='1.0',
       license='GPL-2.0+',
diff --git a/tools/buildman/requirements.txt b/tools/buildman/requirements.txt
index 052d0ed5c6f7..0dadbf3fa2c5 100644
--- a/tools/buildman/requirements.txt
+++ b/tools/buildman/requirements.txt
@@ -3,3 +3,4 @@ jsonschema==4.17.3
 pycryptodome==3.20
 pyyaml==6.0
 yamllint==1.26.3
+setuptools==65.5.1
diff --git a/tools/dtoc/setup.py b/tools/dtoc/setup.py
index 5e092fe0872a..ae9ad043b013 100644
--- a/tools/dtoc/setup.py
+++ b/tools/dtoc/setup.py
@@ -1,6 +1,6 @@
 # SPDX-License-Identifier: GPL-2.0+
 
-from distutils.core import setup
+from setuptools import setup
 setup(name='dtoc',
       version='1.0',
       license='GPL-2.0+',

-- 
2.45.2



More information about the U-Boot mailing list