https://github.com/python/cpython/commit/128d31637e8bf23f086d2a09081525adeeb1f65a
commit: 128d31637e8bf23f086d2a09081525adeeb1f65a
branch: main
author: Zanie Blue <[email protected]>
committer: FFY00 <[email protected]>
date: 2025-12-05T02:15:04Z
summary:
gh-141926: Do not unset `RUNSHARED` when cross-compiling (#141958)
files:
A Misc/NEWS.d/next/Build/2025-11-25-13-17-47.gh-issue-141926.KmuM2h.rst
M configure
M configure.ac
diff --git
a/Misc/NEWS.d/next/Build/2025-11-25-13-17-47.gh-issue-141926.KmuM2h.rst
b/Misc/NEWS.d/next/Build/2025-11-25-13-17-47.gh-issue-141926.KmuM2h.rst
new file mode 100644
index 00000000000000..dab79ba5cf949d
--- /dev/null
+++ b/Misc/NEWS.d/next/Build/2025-11-25-13-17-47.gh-issue-141926.KmuM2h.rst
@@ -0,0 +1,4 @@
+``RUNSHARED`` is no longer cleared when cross-compiling. Previously,
+``RUNSHARED`` was cleared when cross-compiling, which breaks PGO when using
+``--enabled-shared`` on systems where the cross-compiled CPython is otherwise
+executable (e.g., via transparent emulation).
diff --git a/configure b/configure
index 620878bb181378..1561f7f4134ac2 100755
--- a/configure
+++ b/configure
@@ -7808,10 +7808,6 @@ fi
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LDLIBRARY" >&5
printf "%s\n" "$LDLIBRARY" >&6; }
-if test "$cross_compiling" = yes; then
- RUNSHARED=
-fi
-
# HOSTRUNNER - Program to run CPython for the host platform
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking HOSTRUNNER" >&5
printf %s "checking HOSTRUNNER... " >&6; }
diff --git a/configure.ac b/configure.ac
index 8ef479fe32036c..f2a7319d22d24b 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1639,10 +1639,6 @@ else # shared is disabled
fi
AC_MSG_RESULT([$LDLIBRARY])
-if test "$cross_compiling" = yes; then
- RUNSHARED=
-fi
-
# HOSTRUNNER - Program to run CPython for the host platform
AC_MSG_CHECKING([HOSTRUNNER])
if test -z "$HOSTRUNNER"
_______________________________________________
Python-checkins mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3//lists/python-checkins.python.org
Member address: [email protected]