diff options
author | Natanael Copa <ncopa@alpinelinux.org> | 2022-07-26 15:12:30 +0200 |
---|---|---|
committer | Natanael Copa <ncopa@alpinelinux.org> | 2022-07-26 15:12:30 +0200 |
commit | ec543d16ea53848d57a25dc032bb82c6a4f65ec3 (patch) | |
tree | 414a7609e97d6cb500ba61c77ac13fbc7bd94783 | |
parent | 19c33e30039b434952f433e73221599c403da806 (diff) |
main/python3: add back and rebase -gnu soabi fix
It was unintentionally removed due to patch claiming it was already
applied upstream. It wasn't.
fixes commit 663699e90bfc (main/python3: upgrade to 3.9.13)
-rw-r--r-- | main/python3/APKBUILD | 4 | ||||
-rw-r--r-- | main/python3/bpo-43112.patch | 100 |
2 files changed, 103 insertions, 1 deletions
diff --git a/main/python3/APKBUILD b/main/python3/APKBUILD index b93df9768f8..1f250ab3a36 100644 --- a/main/python3/APKBUILD +++ b/main/python3/APKBUILD @@ -6,7 +6,7 @@ pkgname=python3 pkgver=3.9.13 _bluez_ver=5.55 _basever="${pkgver%.*}" -pkgrel=0 +pkgrel=1 pkgdesc="A high-level scripting language" url="https://www.python.org/" arch="all" @@ -22,6 +22,7 @@ source="https://www.python.org/ftp/python/$pkgver/Python-$pkgver.tar.xz custom-bluetooth-h-path.patch arm-alignment.patch mpdecimal-2.5.1.patch + bpo-43112.patch gnu-fallback-soabi.patch " options="net" # Required for tests @@ -205,5 +206,6 @@ ab8eaa2858d5109049b1f9f553198d40e0ef8d78211ad6455f7b491af525bffb16738fed60fc84e9 df78b2bb4890047cb7bcd5db0972f108368bbb8b51b6635d5f6376c3e0c7bf131e5cba2cbad36287893c5929d8a6bfa65e254ab0bcf41a55659e2ba3247d9a52 custom-bluetooth-h-path.patch a84483246e413650a904c34c18f5e4f4168c39067d069f48557c330de6eb3db19fd96a4d453d742db3dcb7c7f962722903f62823c752ff90510c89830435ffc0 arm-alignment.patch d95e36ef3c315a2ddf689c9319e027cf56e8817b0cae139e3ade4742ab6f9efcb3cc4adca178e9bbc8757bd0e3fb924ac2b37e66e70eaa7288202a25339eed7d mpdecimal-2.5.1.patch +5be787c7f5197925a4b4f64f23e166a65637c6be22d7a70c6a4a0291d82179484591884154aff15c4ea03dbec5b952a6c2cebfa9661e309b461a237a82b97287 bpo-43112.patch 7500d4e51975446fd59231985f75a198e8074b9f0a0941b7998958e8a4175de09bd08fd1b4db26aa82f9cef0db922078bf4a6f05e50abc37a200c5f6169e6868 gnu-fallback-soabi.patch " diff --git a/main/python3/bpo-43112.patch b/main/python3/bpo-43112.patch new file mode 100644 index 00000000000..42caafcdd19 --- /dev/null +++ b/main/python3/bpo-43112.patch @@ -0,0 +1,100 @@ +From 82bf05d215dfcc2ef779395bf79b5fc23d5b9555 Mon Sep 17 00:00:00 2001 +From: Natanael Copa <ncopa@alpinelinux.org> +Date: Wed, 10 Feb 2021 18:36:04 +0100 +Subject: [PATCH 1/4] bpo-43112: detect musl as a separate SOABI + +musl libc and gnu libc are not ABI compatible so we need set different +SOABI for musl and not simply assume that all linux is linux-gnu. + +Replace linux-gnu with the detected os for the build from config.guess +for linux-musl*. +--- + configure.ac | 5 +++++ + 1 file changed, 5 insertions(+) + +diff --git a/configure.ac b/configure.ac +index 60c5d8e0b5b03..0e6b617080123 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -860,6 +860,11 @@ EOF + + if $CPP $CPPFLAGS conftest.c >conftest.out 2>/dev/null; then + PLATFORM_TRIPLET=`grep -v '^#' conftest.out | grep -v '^ *$' | tr -d ' '` ++ case "$build_os" in ++ linux-musl*) ++ PLATFORM_TRIPLET=`echo "$PLATFORM_TRIPLET" | sed 's/linux-gnu/linux-musl/'` ++ ;; ++ esac + AC_MSG_RESULT([$PLATFORM_TRIPLET]) + else + AC_MSG_RESULT([none]) + +From a2f26c78cfa7e41dea21d7adcf59809b3b933adf Mon Sep 17 00:00:00 2001 +From: "blurb-it[bot]" <43283697+blurb-it[bot]@users.noreply.github.com> +Date: Wed, 10 Feb 2021 17:54:06 +0000 +Subject: [PATCH 2/4] =?UTF-8?q?=F0=9F=93=9C=F0=9F=A4=96=20Added=20by=20blu?= + =?UTF-8?q?rb=5Fit.?= +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +--- + Misc/NEWS.d/next/Build/2021-02-10-17-54-04.bpo-43112.H5Lat6.rst | 1 + + 1 file changed, 1 insertion(+) + create mode 100644 Misc/NEWS.d/next/Build/2021-02-10-17-54-04.bpo-43112.H5Lat6.rst + +diff --git a/Misc/NEWS.d/next/Build/2021-02-10-17-54-04.bpo-43112.H5Lat6.rst b/Misc/NEWS.d/next/Build/2021-02-10-17-54-04.bpo-43112.H5Lat6.rst +new file mode 100644 +index 0000000000000..8da82f85b4908 +--- /dev/null ++++ b/Misc/NEWS.d/next/Build/2021-02-10-17-54-04.bpo-43112.H5Lat6.rst +@@ -0,0 +1 @@ ++Detect musl libc as a separate SOABI. +\ No newline at end of file + +From e45d9f5889a49bb66d67d7a79df364fe9e1accd1 Mon Sep 17 00:00:00 2001 +From: Natanael Copa <ncopa@alpinelinux.org> +Date: Wed, 10 Feb 2021 20:04:11 +0100 +Subject: [PATCH 3/4] regenerate configure + +--- + configure | 19 ++++++++++++++++++- + 1 file changed, 18 insertions(+), 1 deletion(-) + +diff --git a/configure b/configure +index 8e0cc71a50480..4183b10fbb17b 100755 +--- a/configure ++++ b/configure +@@ -5351,6 +5363,11 @@ EOF + + if $CPP $CPPFLAGS conftest.c >conftest.out 2>/dev/null; then + PLATFORM_TRIPLET=`grep -v '^#' conftest.out | grep -v '^ *$' | tr -d ' '` ++ case "$build_os" in ++ linux-musl*) ++ PLATFORM_TRIPLET=`echo "$PLATFORM_TRIPLET" | sed 's/linux-gnu/linux-musl/'` ++ ;; ++ esac + { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PLATFORM_TRIPLET" >&5 + $as_echo "$PLATFORM_TRIPLET" >&6; } + else + +diff --git a/Lib/test/test_sysconfig.py b/Lib/test/test_sysconfig.py +index e279957e26..83ce74aa6f 100644 +--- a/Lib/test/test_sysconfig.py ++++ b/Lib/test/test_sysconfig.py +@@ -387,10 +387,13 @@ def test_triplet_in_ext_suffix(self): + if re.match('(i[3-6]86|x86_64)$', machine): + if ctypes.sizeof(ctypes.c_char_p()) == 4: + self.assertTrue(suffix.endswith('i386-linux-gnu.so') or +- suffix.endswith('x86_64-linux-gnux32.so'), ++ suffix.endswith('x86_64-linux-gnux32.so') or ++ suffix.endswith('i386-linux-musl.so'), + suffix) + else: # 8 byte pointer size +- self.assertTrue(suffix.endswith('x86_64-linux-gnu.so'), suffix) ++ self.assertTrue(suffix.endswith('x86_64-linux-gnu.so') or ++ suffix.endswith('x86_64-linux-musl.so'), ++ suffix) + + @unittest.skipUnless(sys.platform == 'darwin', 'OS X-specific test') + def test_osx_ext_suffix(self): |