diff options
Diffstat (limited to 'meta-python')
| -rw-r--r-- | meta-python/recipes-devtools/python/files/0001-versioneer.py-do-not-use-SafeConfigParser.patch | 29 | ||||
| -rw-r--r-- | meta-python/recipes-devtools/python/python3-custom-inherit_2.4.1.bb | 1 |
2 files changed, 30 insertions, 0 deletions
diff --git a/meta-python/recipes-devtools/python/files/0001-versioneer.py-do-not-use-SafeConfigParser.patch b/meta-python/recipes-devtools/python/files/0001-versioneer.py-do-not-use-SafeConfigParser.patch new file mode 100644 index 0000000000..34caaca982 --- /dev/null +++ b/meta-python/recipes-devtools/python/files/0001-versioneer.py-do-not-use-SafeConfigParser.patch | |||
| @@ -0,0 +1,29 @@ | |||
| 1 | From 0920bd21ceab75bc4b655c571a37835526dd2468 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Alexander Kanavin <alex@linutronix.de> | ||
| 3 | Date: Wed, 27 Dec 2023 15:12:19 +0100 | ||
| 4 | Subject: [PATCH] versioneer.py: do not use SafeConfigParser | ||
| 5 | |||
| 6 | This has been deprecated for a long time, and finally removed in python 3.12 | ||
| 7 | |||
| 8 | Upstream-Status: Submitted [https://github.com/rsokl/custom_inherit/pull/49] | ||
| 9 | Signed-off-by: Alexander Kanavin <alex@linutronix.de> | ||
| 10 | --- | ||
| 11 | versioneer.py | 4 ++-- | ||
| 12 | 1 file changed, 2 insertions(+), 2 deletions(-) | ||
| 13 | |||
| 14 | diff --git a/versioneer.py b/versioneer.py | ||
| 15 | index 64fea1c..3aa5da3 100644 | ||
| 16 | --- a/versioneer.py | ||
| 17 | +++ b/versioneer.py | ||
| 18 | @@ -339,9 +339,9 @@ def get_config_from_root(root): | ||
| 19 | # configparser.NoOptionError (if it lacks "VCS="). See the docstring at | ||
| 20 | # the top of versioneer.py for instructions on writing your setup.cfg . | ||
| 21 | setup_cfg = os.path.join(root, "setup.cfg") | ||
| 22 | - parser = configparser.SafeConfigParser() | ||
| 23 | + parser = configparser.ConfigParser() | ||
| 24 | with open(setup_cfg, "r") as f: | ||
| 25 | - parser.readfp(f) | ||
| 26 | + parser.read_file(f) | ||
| 27 | VCS = parser.get("versioneer", "VCS") # mandatory | ||
| 28 | |||
| 29 | def get(parser, name): | ||
diff --git a/meta-python/recipes-devtools/python/python3-custom-inherit_2.4.1.bb b/meta-python/recipes-devtools/python/python3-custom-inherit_2.4.1.bb index 478abbf1fd..e7409f77e6 100644 --- a/meta-python/recipes-devtools/python/python3-custom-inherit_2.4.1.bb +++ b/meta-python/recipes-devtools/python/python3-custom-inherit_2.4.1.bb | |||
| @@ -5,6 +5,7 @@ LIC_FILES_CHKSUM = "file://LICENSE.md;md5=f910a85a4c3da51edf780f17a7608434" | |||
| 5 | 5 | ||
| 6 | PYPI_PACKAGE = "custom_inherit" | 6 | PYPI_PACKAGE = "custom_inherit" |
| 7 | 7 | ||
| 8 | SRC_URI += "file://0001-versioneer.py-do-not-use-SafeConfigParser.patch" | ||
| 8 | SRC_URI[sha256sum] = "7052eb337bcce83551815264391cc4efc2bf70b295a3c52aba64f1ab57c3a8a2" | 9 | SRC_URI[sha256sum] = "7052eb337bcce83551815264391cc4efc2bf70b295a3c52aba64f1ab57c3a8a2" |
| 9 | 10 | ||
| 10 | inherit pypi setuptools3 | 11 | inherit pypi setuptools3 |
