public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
* [PATCH] Allow configure with python on macOS
@ 2023-12-26 15:36 Simon Wright
  2023-12-31 23:58 ` Simon Marchi
  0 siblings, 1 reply; 2+ messages in thread
From: Simon Wright @ 2023-12-26 15:36 UTC (permalink / raw)
  To: gdb-patches; +Cc: Simon Wright

PR29070 reports that a framework build of GDB, configured
--with-python, fails becaue of an inappropriately set value in the
LINKFORSHARED variable.

Python PR36508: python-config --ldflags must not contain LINKFORSHARED
("-Xlinker -export-dynamic" on Linux) (https://bugs.python.org/issue36508)
states (2019-04-16) that the issue is resolved in Python 3.7.

This patch removes the use of LINKFORSHARED.

  * gdb/python/python-config.py: --ldflags doesn't include LINKFORSHARED
---

I've seen this problem in binutils-gdb at gcc-12.1-release,
gcc-13.1-release, gcc-14.1-release; previous fixes were as in PR29070,
but looking at Python PR36508 I think that LINKFORSHARED shouldn't be
there at all.

I haven't run the testsuite, because without this patch there's no
build.

I have GCC copyright assignment 1016382.

 gdb/python/python-config.py | 2 --
 1 file changed, 2 deletions(-)

diff --git a/gdb/python/python-config.py b/gdb/python/python-config.py
index e89e0fd40bb..748ced64b75 100644
--- a/gdb/python/python-config.py
+++ b/gdb/python/python-config.py
@@ -77,6 +77,4 @@ for opt in opt_flags:
                     libs.insert(0, "-L" + getvar("LIBPL"))
                 elif os.name == "nt":
                     libs.insert(0, "-L" + os.path.normpath(sys.prefix) + "/libs")
-            if getvar("LINKFORSHARED") is not None:
-                libs.extend(getvar("LINKFORSHARED").split())
         print(to_unix_path(" ".join(libs)))
-- 
2.42.1


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2023-12-31 23:58 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-12-26 15:36 [PATCH] Allow configure with python on macOS Simon Wright
2023-12-31 23:58 ` Simon Marchi

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).