]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
[3.12] gh-110459: Make sure --with-openssl-rpath works on macOS (GH-113441) (#113535)
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Thu, 28 Dec 2023 09:21:12 +0000 (10:21 +0100)
committerGitHub <noreply@github.com>
Thu, 28 Dec 2023 09:21:12 +0000 (10:21 +0100)
gh-110459: Make sure --with-openssl-rpath works on macOS (GH-113441)

* gh-110459: Make sure --with-openssl-rpath works on macOS

On macOS the `-rpath` linker flag is spelled differently
than on on platforms.
(cherry picked from commit cc13eabc7ce08accf49656e258ba500f74a1dae8)

Co-authored-by: Ronald Oussoren <ronaldoussoren@mac.com>
Misc/NEWS.d/next/macOS/2023-12-23-22-41-07.gh-issue-110459.NaMBJy.rst [new file with mode: 0644]
configure
configure.ac

diff --git a/Misc/NEWS.d/next/macOS/2023-12-23-22-41-07.gh-issue-110459.NaMBJy.rst b/Misc/NEWS.d/next/macOS/2023-12-23-22-41-07.gh-issue-110459.NaMBJy.rst
new file mode 100644 (file)
index 0000000..44ffd85
--- /dev/null
@@ -0,0 +1,2 @@
+Running ``configure ... --with-openssl-rpath=X/Y/Z`` no longer fails to detect
+OpenSSL on macOS.
index 99dd1fe595805ef09e34c80fefb1674317b8662a..89cb0af392e556a890b19d01edc91c1326782465 100755 (executable)
--- a/configure
+++ b/configure
@@ -28114,7 +28114,12 @@ then :
 
 else $as_nop
 
-  rpath_arg="-Wl,-rpath="
+  if test "$ac_sys_system" = "Darwin"
+  then
+     rpath_arg="-Wl,-rpath,"
+  else
+     rpath_arg="-Wl,-rpath="
+  fi
 
 fi
 
index bd2be94b47cb9c1bd032f23807bfb0902c22c9a9..4ae70a10ef8141fd4546561fbc320e83e48b21cf 100644 (file)
@@ -7002,7 +7002,12 @@ AX_CHECK_OPENSSL([have_openssl=yes],[have_openssl=no])
 AS_VAR_IF([GNULD], [yes], [
   rpath_arg="-Wl,--enable-new-dtags,-rpath="
 ], [
-  rpath_arg="-Wl,-rpath="
+  if test "$ac_sys_system" = "Darwin"
+  then
+     rpath_arg="-Wl,-rpath,"
+  else
+     rpath_arg="-Wl,-rpath="
+  fi
 ])
 
 AC_MSG_CHECKING([for --with-openssl-rpath])