diff options
-rw-r--r-- | meta-networking/recipes-connectivity/samba/samba/0001-Fix-pyext_PATTERN-for-cross-compilation.patch | 63 | ||||
-rw-r--r-- | meta-networking/recipes-connectivity/samba/samba_4.14.10.bb | 1 |
2 files changed, 64 insertions, 0 deletions
diff --git a/meta-networking/recipes-connectivity/samba/samba/0001-Fix-pyext_PATTERN-for-cross-compilation.patch b/meta-networking/recipes-connectivity/samba/samba/0001-Fix-pyext_PATTERN-for-cross-compilation.patch new file mode 100644 index 0000000000..d497dd32ca --- /dev/null +++ b/meta-networking/recipes-connectivity/samba/samba/0001-Fix-pyext_PATTERN-for-cross-compilation.patch | |||
@@ -0,0 +1,63 @@ | |||
1 | From a0547cacaddcb2fbef1fb9991c5ad522226e6817 Mon Sep 17 00:00:00 2001 | ||
2 | From: Yi Zhao <yi.zhao@windriver.com> | ||
3 | Date: Wed, 24 Nov 2021 13:33:35 +0800 | ||
4 | Subject: [PATCH] Fix pyext_PATTERN for cross compilation | ||
5 | |||
6 | The pyext_PATTERN will add native arch as suffix when cross compiling. | ||
7 | For example, on qemuarm64, it is expanded to: | ||
8 | pyext_PATTERN ='%s.cpython-310-x86_64-linux-gnu.so' | ||
9 | which will result in the incorrect library name. | ||
10 | |||
11 | root@qemuarm64:~# find /usr/lib -name \*cpython\* | ||
12 | /usr/lib/pkgconfig/samba-policy.cpython-310-x86_64-linux-gnu.pc | ||
13 | /usr/lib/libsamba-policy.cpython-310-x86-64-linux-gnu.so | ||
14 | /usr/lib/samba/libsamba-python.cpython-310-x86-64-linux-gnu-samba4.so | ||
15 | /usr/lib/samba/libsamba-net.cpython-310-x86-64-linux-gnu-samba4.so | ||
16 | /usr/lib/libsamba-policy.cpython-310-x86-64-linux-gnu.so.0 | ||
17 | /usr/lib/libsamba-policy.cpython-310-x86-64-linux-gnu.so.0.0.1 | ||
18 | /usr/lib/python3.10/site-packages/samba/dsdb_dns.cpython-310-x86_64-linux-gnu.so | ||
19 | /usr/lib/python3.10/site-packages/samba/dsdb.cpython-310-x86_64-linux-gnu.so | ||
20 | /usr/lib/python3.10/site-packages/samba/xattr_tdb.cpython-310-x86_64-linux-gnu.so | ||
21 | /usr/lib/python3.10/site-packages/samba/_ldb.cpython-310-x86_64-linux-gnu.so | ||
22 | /usr/lib/python3.10/site-packages/samba/gensec.cpython-310-x86_64-linux-gnu.so | ||
23 | [snip] | ||
24 | |||
25 | Set pyext_PATTERN to '%s.so' to remove the suffix. | ||
26 | After the patch: | ||
27 | root@qemuarm64:~# find /usr/lib/ | ||
28 | /usr/lib/pkgconfig/samba-policy.pc | ||
29 | /usr/lib/libsamba-policy.so | ||
30 | /usr/lib/samba/libsamba-python-samba4.so | ||
31 | /usr/lib/samba/libsamba-net-samba4.so | ||
32 | /usr/lib/libsamba-policy.so.0 | ||
33 | /usr/lib/libsamba-policy.so.0.0.1 | ||
34 | /usr/lib/python3.10/site-packages/samba/dsdb_dns.so | ||
35 | /usr/lib/python3.10/site-packages/samba/dsdb.so | ||
36 | /usr/lib/python3.10/site-packages/samba/xattr_tdb.so | ||
37 | /usr/lib/python3.10/site-packages/samba/_ldb.so | ||
38 | /usr/lib/python3.10/site-packages/samba/gensec.so | ||
39 | [snip] | ||
40 | |||
41 | Upstream-Status: Inappropriate [embedded specific] | ||
42 | |||
43 | Signed-off-by: Yi Zhao <yi.zhao@windriver.com> | ||
44 | --- | ||
45 | third_party/waf/waflib/Tools/python.py | 2 +- | ||
46 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
47 | |||
48 | diff --git a/third_party/waf/waflib/Tools/python.py b/third_party/waf/waflib/Tools/python.py | ||
49 | index b1c8dd0..24faa31 100644 | ||
50 | --- a/third_party/waf/waflib/Tools/python.py | ||
51 | +++ b/third_party/waf/waflib/Tools/python.py | ||
52 | @@ -328,7 +328,7 @@ def check_python_headers(conf, features='pyembed pyext'): | ||
53 | x = 'MACOSX_DEPLOYMENT_TARGET' | ||
54 | if dct[x]: | ||
55 | env[x] = conf.environ[x] = dct[x] | ||
56 | - env.pyext_PATTERN = '%s' + dct['SO'] # not a mistake | ||
57 | + env.pyext_PATTERN = '%s.so' | ||
58 | |||
59 | |||
60 | # Try to get pythonX.Y-config | ||
61 | -- | ||
62 | 2.17.1 | ||
63 | |||
diff --git a/meta-networking/recipes-connectivity/samba/samba_4.14.10.bb b/meta-networking/recipes-connectivity/samba/samba_4.14.10.bb index c1c3937381..af07954584 100644 --- a/meta-networking/recipes-connectivity/samba/samba_4.14.10.bb +++ b/meta-networking/recipes-connectivity/samba/samba_4.14.10.bb | |||
@@ -24,6 +24,7 @@ SRC_URI = "${SAMBA_MIRROR}/stable/samba-${PV}.tar.gz \ | |||
24 | file://0007-wscript_configure_system_gnutls-disable-check-gnutls.patch \ | 24 | file://0007-wscript_configure_system_gnutls-disable-check-gnutls.patch \ |
25 | file://0008-source3-wscript-disable-check-fcntl-F_OWNER_EX.patch \ | 25 | file://0008-source3-wscript-disable-check-fcntl-F_OWNER_EX.patch \ |
26 | file://0009-source3-wscript-disable-check-fcntl-RW_HINTS.patch \ | 26 | file://0009-source3-wscript-disable-check-fcntl-RW_HINTS.patch \ |
27 | file://0001-Fix-pyext_PATTERN-for-cross-compilation.patch \ | ||
27 | " | 28 | " |
28 | 29 | ||
29 | SRC_URI:append:libc-musl = " \ | 30 | SRC_URI:append:libc-musl = " \ |