mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-07-21 18:25:41 +03:00
211 lines
8 KiB
Diff
211 lines
8 KiB
Diff
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
|
|
@@ -789,6 +789,7 @@ infodir
|
|
docdir
|
|
oldincludedir
|
|
includedir
|
|
+runstatedir
|
|
localstatedir
|
|
sharedstatedir
|
|
sysconfdir
|
|
@@ -910,6 +911,7 @@ datadir='${datarootdir}'
|
|
sysconfdir='${prefix}/etc'
|
|
sharedstatedir='${prefix}/com'
|
|
localstatedir='${prefix}/var'
|
|
+runstatedir='${localstatedir}/run'
|
|
includedir='${prefix}/include'
|
|
oldincludedir='/usr/include'
|
|
docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
|
|
@@ -1162,6 +1164,15 @@ do
|
|
| -silent | --silent | --silen | --sile | --sil)
|
|
silent=yes ;;
|
|
|
|
+ -runstatedir | --runstatedir | --runstatedi | --runstated \
|
|
+ | --runstate | --runstat | --runsta | --runst | --runs \
|
|
+ | --run | --ru | --r)
|
|
+ ac_prev=runstatedir ;;
|
|
+ -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
|
|
+ | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \
|
|
+ | --run=* | --ru=* | --r=*)
|
|
+ runstatedir=$ac_optarg ;;
|
|
+
|
|
-sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
|
|
ac_prev=sbindir ;;
|
|
-sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
|
|
@@ -1299,7 +1310,7 @@ fi
|
|
for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
|
|
datadir sysconfdir sharedstatedir localstatedir includedir \
|
|
oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
|
|
- libdir localedir mandir
|
|
+ libdir localedir mandir runstatedir
|
|
do
|
|
eval ac_val=\$$ac_var
|
|
# Remove trailing slashes.
|
|
@@ -1452,6 +1463,7 @@ Fine tuning of the installation directories:
|
|
--sysconfdir=DIR read-only single-machine data [PREFIX/etc]
|
|
--sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
|
|
--localstatedir=DIR modifiable single-machine data [PREFIX/var]
|
|
+ --runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run]
|
|
--libdir=DIR object code libraries [EPREFIX/lib]
|
|
--includedir=DIR C header files [PREFIX/include]
|
|
--oldincludedir=DIR C header files for non-gcc [/usr/include]
|
|
@@ -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
|
|
|
|
From 85e060266dae2e5e6bbbd7f5fe828f8916651b8b Mon Sep 17 00:00:00 2001
|
|
From: Natanael Copa <ncopa@alpinelinux.org>
|
|
Date: Fri, 12 Feb 2021 10:55:48 +0100
|
|
Subject: [PATCH 4/4] Revert the runstate changes in the generated configure
|
|
|
|
---
|
|
configure | 14 +-------------
|
|
1 file changed, 1 insertion(+), 13 deletions(-)
|
|
|
|
diff --git a/configure b/configure
|
|
index 4183b10fbb17b..cb1ef8612dcb7 100755
|
|
--- a/configure
|
|
+++ b/configure
|
|
@@ -789,7 +789,6 @@ infodir
|
|
docdir
|
|
oldincludedir
|
|
includedir
|
|
-runstatedir
|
|
localstatedir
|
|
sharedstatedir
|
|
sysconfdir
|
|
@@ -911,7 +910,6 @@ datadir='${datarootdir}'
|
|
sysconfdir='${prefix}/etc'
|
|
sharedstatedir='${prefix}/com'
|
|
localstatedir='${prefix}/var'
|
|
-runstatedir='${localstatedir}/run'
|
|
includedir='${prefix}/include'
|
|
oldincludedir='/usr/include'
|
|
docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
|
|
@@ -1164,15 +1162,6 @@ do
|
|
| -silent | --silent | --silen | --sile | --sil)
|
|
silent=yes ;;
|
|
|
|
- -runstatedir | --runstatedir | --runstatedi | --runstated \
|
|
- | --runstate | --runstat | --runsta | --runst | --runs \
|
|
- | --run | --ru | --r)
|
|
- ac_prev=runstatedir ;;
|
|
- -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
|
|
- | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \
|
|
- | --run=* | --ru=* | --r=*)
|
|
- runstatedir=$ac_optarg ;;
|
|
-
|
|
-sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
|
|
ac_prev=sbindir ;;
|
|
-sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
|
|
@@ -1310,7 +1299,7 @@ fi
|
|
for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
|
|
datadir sysconfdir sharedstatedir localstatedir includedir \
|
|
oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
|
|
- libdir localedir mandir runstatedir
|
|
+ libdir localedir mandir
|
|
do
|
|
eval ac_val=\$$ac_var
|
|
# Remove trailing slashes.
|
|
@@ -1463,7 +1452,6 @@ Fine tuning of the installation directories:
|
|
--sysconfdir=DIR read-only single-machine data [PREFIX/etc]
|
|
--sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
|
|
--localstatedir=DIR modifiable single-machine data [PREFIX/var]
|
|
- --runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run]
|
|
--libdir=DIR object code libraries [EPREFIX/lib]
|
|
--includedir=DIR C header files [PREFIX/include]
|
|
--oldincludedir=DIR C header files for non-gcc [/usr/include]
|
|
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):
|