aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorwangmy <wangmy@fujitsu.com>2022-04-02 20:32:47 +0800
committerTrevor Gamblin <trevor.gamblin@windriver.com>2022-04-06 14:55:16 -0400
commitdb5534e5316697dda0529d58c1531b8201622bc1 (patch)
tree894946fe3944e9a14364d75dd7d383b9fd15287c
parent166cfe0ae2aa2eadbaaadb391993ed9aecb972c1 (diff)
downloadmeta-openembedded-contrib-db5534e5316697dda0529d58c1531b8201622bc1.tar.gz
python3-pyparted: upgrade 3.11.7 -> 3.12.0
setuptools.patch removed since it's included in 3.12.0 Signed-off-by: Wang Mingyu <wangmy@fujitsu.com> Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Trevor Gamblin <trevor.gamblin@windriver.com>
-rw-r--r--meta-python/recipes-extended/python-pyparted/files/setuptools.patch82
-rw-r--r--meta-python/recipes-extended/python-pyparted/python3-pyparted_3.12.0.bb (renamed from meta-python/recipes-extended/python-pyparted/python3-pyparted_3.11.7.bb)5
2 files changed, 1 insertions, 86 deletions
diff --git a/meta-python/recipes-extended/python-pyparted/files/setuptools.patch b/meta-python/recipes-extended/python-pyparted/files/setuptools.patch
deleted file mode 100644
index 51fe8c7c56..0000000000
--- a/meta-python/recipes-extended/python-pyparted/files/setuptools.patch
+++ /dev/null
@@ -1,82 +0,0 @@
-Upstream-Status: Submitted [https://github.com/dcantrell/pyparted/pull/85]
-Signed-off-by: Ross Burton <ross.burton@arm.com>
-
-From 3f5ca7eb6f57d8bcaa3b333497aba6e53d847450 Mon Sep 17 00:00:00 2001
-From: Ross Burton <ross.burton@arm.com>
-Date: Fri, 14 Jan 2022 16:06:31 +0000
-Subject: [PATCH] setup.py: port to setuptools
-
-Python 3.10 has deprecated distutils[1], and it will be removed entirely
-in Python 3.12.
-
-As the setuptools API is identical, moving to setuptools is trivial by
-changing the import.
-
-Remove check_mod_version, a version specifier can be passed directly
-to pkg-config.
-
-Remove unused imports.
-
-[1] https://docs.python.org/3/whatsnew/3.10.html#distutils-deprecated
-
-Signed-off-by: Ross Burton <ross.burton@arm.com>
----
- setup.py | 29 +++++++++--------------------
- 1 file changed, 9 insertions(+), 20 deletions(-)
-
-diff --git a/setup.py b/setup.py
-index da71d9c..1e9e367 100644
---- a/setup.py
-+++ b/setup.py
-@@ -25,12 +25,7 @@ import glob
- import os
- import platform
- import sys
--from distutils.ccompiler import new_compiler
--from distutils.errors import CompileError
--from distutils.errors import LinkError
--from distutils.core import setup
--from distutils.core import Extension
--from distutils.version import LooseVersion
-+from setuptools import setup, Extension
-
- pyparted_version = '3.11.7'
- python_version = sys.version_info
-@@ -45,19 +40,13 @@ if python_version < need_python_version:
- # http://code.activestate.com/recipes/502261-python-distutils-pkg-config/
- def pkgconfig(*packages, **kwargs):
- flag_map = {'-I': 'include_dirs', '-L': 'library_dirs', '-l': 'libraries'}
-- for token in subprocess.check_output(["pkg-config", "--libs", "--cflags"] + list(packages)).decode('utf-8').split():
--
-- kwargs.setdefault(flag_map.get(token[:2]), []).append(token[2:])
-- return kwargs
--
--def check_mod_version(module, version):
-- modversion = subprocess.check_output(["pkg-config", "--modversion", module]).decode('utf-8').split()[0]
-- if not LooseVersion(modversion) >= LooseVersion(version):
-- sys.stderr.write("*** Minimum required %s version: %s, found: %s\n" % (module, version, modversion,))
-- sys.exit(1)
-- return
--
--check_mod_version('libparted', need_libparted_version)
-+ try:
-+ for token in subprocess.check_output(["pkg-config", "--libs", "--cflags"] + list(packages),
-+ universal_newlines=True).split():
-+ kwargs.setdefault(flag_map.get(token[:2]), []).append(token[2:])
-+ return kwargs
-+ except subprocess.CalledProcessError as e:
-+ sys.exit("Cannot find pkg-config dependencies:\n" + e.output)
-
- # This list is in the format necessary for the define_macros parameter
- # for an Extension() module definition. See:
-@@ -77,6 +66,6 @@ setup(name='pyparted',
- ext_modules=[Extension('_ped',
- sorted(glob.glob(os.path.join('src', '*.c'))),
- define_macros=features,
-- **pkgconfig('libparted',
-+ **pkgconfig('libparted >= %s' % need_libparted_version,
- include_dirs=['include']))
- ])
---
-2.25.1
-
diff --git a/meta-python/recipes-extended/python-pyparted/python3-pyparted_3.11.7.bb b/meta-python/recipes-extended/python-pyparted/python3-pyparted_3.12.0.bb
index 2cdf82365a..9dd362766d 100644
--- a/meta-python/recipes-extended/python-pyparted/python3-pyparted_3.11.7.bb
+++ b/meta-python/recipes-extended/python-pyparted/python3-pyparted_3.12.0.bb
@@ -9,10 +9,7 @@ LIC_FILES_CHKSUM = "\
file://src/_pedmodule.c;beginline=10;endline=22;md5=9e53304db812b80d0939e11bb69dcab2 \
"
-SRC_URI += "file://setuptools.patch"
-
-SRC_URI[md5sum] = "69284f943982f54ded76960c92098a02"
-SRC_URI[sha256sum] = "61cde7b096bccd69ddc75c85b17f8baed45c3687d404706d91403a319453b903"
+SRC_URI[sha256sum] = "da985e116beb733371feb605b174db9eec8bd0eedffc8f739f8e603f51b521e7"
inherit pkgconfig pypi setuptools3