diff options
Diffstat (limited to 'meta-python/recipes-devtools/python')
-rw-r--r-- | meta-python/recipes-devtools/python/python3-m2crypto/0001-setup.py-Make-the-cmd-available.patch | 40 | ||||
-rw-r--r-- | meta-python/recipes-devtools/python/python3-m2crypto_0.44.0.bb (renamed from meta-python/recipes-devtools/python/python3-m2crypto_0.42.0.bb) | 6 |
2 files changed, 45 insertions, 1 deletions
diff --git a/meta-python/recipes-devtools/python/python3-m2crypto/0001-setup.py-Make-the-cmd-available.patch b/meta-python/recipes-devtools/python/python3-m2crypto/0001-setup.py-Make-the-cmd-available.patch new file mode 100644 index 0000000000..819ecabf6c --- /dev/null +++ b/meta-python/recipes-devtools/python/python3-m2crypto/0001-setup.py-Make-the-cmd-available.patch | |||
@@ -0,0 +1,40 @@ | |||
1 | From b14664fdab286485c5cbc0fbe5b0ff13f062edd8 Mon Sep 17 00:00:00 2001 | ||
2 | From: Mingli Yu <mingli.yu@windriver.com> | ||
3 | Date: Fri, 28 Mar 2025 12:13:26 +0800 | ||
4 | Subject: [PATCH] setup.py: Make the cmd available | ||
5 | |||
6 | The cmd will be None in OE environment as below. | ||
7 | >>> import os | ||
8 | >>> os.environ.get('CC', 'gcc') | ||
9 | 'x86_64-wrs-linux-gcc -m64 -march=nehalem -mtune=generic -mfpmath=sse -msse4.2 -fstack-protector-strong -O2 -D_FORTIFY_SOURCE=2 -Wformat -Wformat-security -Werror=format-security --sysroot=/buildarea/tmp/work/corei7-64-wrs-linux/python3-m2crypto/0.44.0/recipe-sysroot' | ||
10 | >>> import shutil | ||
11 | >>> shutil.which(os.environ.get('CC', 'gcc')) | ||
12 | >>> cmd = [shutil.which(os.environ.get('CC', 'gcc'))] | ||
13 | >>> print(cmd) | ||
14 | [None] | ||
15 | |||
16 | So change the check logic to get the expected cmd. | ||
17 | |||
18 | Upstream-Status: Inappropriate [oe specific] | ||
19 | |||
20 | Signed-off-by: Mingli Yu <mingli.yu@windriver.com> | ||
21 | --- | ||
22 | setup.py | 2 +- | ||
23 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
24 | |||
25 | diff --git a/setup.py b/setup.py | ||
26 | index 7e295f3..cc414c9 100644 | ||
27 | --- a/setup.py | ||
28 | +++ b/setup.py | ||
29 | @@ -221,7 +221,7 @@ class _M2CryptoBuildExt(build_ext.build_ext): | ||
30 | with open( | ||
31 | "src/SWIG/x509_v_flag.h", "w", encoding="utf-8" | ||
32 | ) as x509_v_h: | ||
33 | - cmd = [shutil.which(os.environ.get('CC', 'gcc'))] | ||
34 | + cmd = os.environ.get('CC', 'gcc').split() | ||
35 | cflags = os.environ.get("CFLAGS") | ||
36 | if cflags is not None: | ||
37 | cmd += cflags.split() | ||
38 | -- | ||
39 | 2.34.1 | ||
40 | |||
diff --git a/meta-python/recipes-devtools/python/python3-m2crypto_0.42.0.bb b/meta-python/recipes-devtools/python/python3-m2crypto_0.44.0.bb index b50ae31e4c..5201e704ea 100644 --- a/meta-python/recipes-devtools/python/python3-m2crypto_0.42.0.bb +++ b/meta-python/recipes-devtools/python/python3-m2crypto_0.44.0.bb | |||
@@ -4,7 +4,11 @@ HOMEPAGE = "https://gitlab.com/m2crypto/m2crypto" | |||
4 | LICENSE = "MIT" | 4 | LICENSE = "MIT" |
5 | LIC_FILES_CHKSUM = "file://LICENCE;md5=b0e1f0b7d0ce8a62c18b1287b991800e" | 5 | LIC_FILES_CHKSUM = "file://LICENCE;md5=b0e1f0b7d0ce8a62c18b1287b991800e" |
6 | 6 | ||
7 | SRC_URI[sha256sum] = "42b62df2caf623161b1d643a7235464c2fe2a3105049ebc498a6d47dc08f64b4" | 7 | SRC_URI[sha256sum] = "384bb4cbd178ee0e74015311b7b1f9f2c377e3686e03fa070b3ec2f494671c0f" |
8 | |||
9 | SRC_URI += " \ | ||
10 | file://0001-setup.py-Make-the-cmd-available.patch \ | ||
11 | " | ||
8 | 12 | ||
9 | inherit pypi siteinfo python_setuptools_build_meta | 13 | inherit pypi siteinfo python_setuptools_build_meta |
10 | 14 | ||