1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-25 14:25:07 +00:00
serenity/Ports/python3/patches/fix-autoconf.patch
Linus Groh 6d9a1d3c93 Ports: Update Python to 3.10.1 :^)
This was released a couple of days ago, on 2021-12-06 and contains
various changes that we previously needed custom patches for, so we are
now able to remove those and compile more unchanged upstream sources.
Thanks to Rodrigo for making that effort! :^)
2021-12-11 19:02:00 +00:00

90 lines
2.6 KiB
Diff

--- Python-3.10.1/config.sub 2021-12-06 18:23:39.000000000 +0000
+++ Python-3.10.1/config.sub 2021-12-11 17:17:07.076780435 +0000
@@ -1474,6 +1474,9 @@
oss*)
os=sysv3
;;
+ serenity*)
+ os=serenity
+ ;;
svr4*)
os=sysv4
;;
--- Python-3.10.1/configure.ac 2021-12-06 18:23:39.000000000 +0000
+++ Python-3.10.1/configure.ac 2021-12-11 17:23:18.363664786 +0000
@@ -391,6 +391,9 @@
# a lot of different things including 'define_xopen_source'
# in the case statement below.
case "$host" in
+ *-*-serenity*)
+ ac_sys_system=SerenityOS
+ ;;
*-*-linux-android*)
ac_sys_system=Linux-android
;;
@@ -429,6 +432,7 @@
linux*) MACHDEP="linux";;
cygwin*) MACHDEP="cygwin";;
darwin*) MACHDEP="darwin";;
+ serenityos*) MACHDEP="serenityos";;
'') MACHDEP="unknown";;
esac
fi
@@ -437,6 +441,9 @@
AC_SUBST(_PYTHON_HOST_PLATFORM)
if test "$cross_compiling" = yes; then
case "$host" in
+ *-*-serenity*)
+ _host_cpu=$host_cpu
+ ;;
*-*-linux*)
case "$host_cpu" in
arm*)
@@ -2802,7 +2809,7 @@
LINKFORSHARED="-Wl,-E -Wl,+s";;
# LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/lib-dynload";;
Linux-android*) LINKFORSHARED="-pie -Xlinker -export-dynamic";;
- Linux*|GNU*) LINKFORSHARED="-Xlinker -export-dynamic";;
+ Linux*|GNU*|SerenityOS*) LINKFORSHARED="-Xlinker -export-dynamic";;
# -u libsys_s pulls in all symbols in libsys
Darwin/*)
LINKFORSHARED="$extra_undefs -framework CoreFoundation"
--- Python-3.10.1/configure 2021-12-06 18:23:39.000000000 +0000
+++ Python-3.10.1/configure 2021-12-11 17:25:05.866475699 +0000
@@ -3335,6 +3335,9 @@
# a lot of different things including 'define_xopen_source'
# in the case statement below.
case "$host" in
+ *-*-serenity*)
+ ac_sys_system=SerenityOS
+ ;;
*-*-linux-android*)
ac_sys_system=Linux-android
;;
@@ -3373,6 +3376,7 @@
linux*) MACHDEP="linux";;
cygwin*) MACHDEP="cygwin";;
darwin*) MACHDEP="darwin";;
+ serenityos*) MACHDEP="serenityos";;
'') MACHDEP="unknown";;
esac
fi
@@ -3382,6 +3386,9 @@
if test "$cross_compiling" = yes; then
case "$host" in
+ *-*-serenity*)
+ _host_cpu=$host_cpu
+ ;;
*-*-linux*)
case "$host_cpu" in
arm*)
@@ -9875,7 +9882,7 @@
LINKFORSHARED="-Wl,-E -Wl,+s";;
# LINKFORSHARED="-Wl,-E -Wl,+s -Wl,+b\$(BINLIBDEST)/lib-dynload";;
Linux-android*) LINKFORSHARED="-pie -Xlinker -export-dynamic";;
- Linux*|GNU*) LINKFORSHARED="-Xlinker -export-dynamic";;
+ Linux*|GNU*|SerenityOS*) LINKFORSHARED="-Xlinker -export-dynamic";;
# -u libsys_s pulls in all symbols in libsys
Darwin/*)
LINKFORSHARED="$extra_undefs -framework CoreFoundation"