This is the mail archive of the
gdb-prs@sourceware.org
mailing list for the GDB project.
[Bug python/19377] osx
- From: "congeec at live dot com" <sourceware-bugzilla at sourceware dot org>
- To: gdb-prs at sourceware dot org
- Date: Fri, 18 Dec 2015 16:19:08 +0000
- Subject: [Bug python/19377] osx
- Auto-submitted: auto-generated
- References: <bug-19377-4717 at http dot sourceware dot org/bugzilla/>
https://sourceware.org/bugzilla/show_bug.cgi?id=19377
--- Comment #2 from Charles <congeec at live dot com> ---
issue: symbol PyMac_Error does not exit in libpython3.dylib, but in
libpython2.7.dylib.
related files:
gdb/python/python-config
config.log in dir gdb/python/
```
1107 configure:8678: checking for python3.5
1108 configure:8696: gcc -o conftest -g -O2
-I/usr/local/Cellar/python3/3.5.1/Frameworks/Python.fra
mework/Versions/3.5/include/python3.5m
-I/usr/local/Cellar/python3/3.5.1/Frameworks/Python.frame
work/Versions/3.5/include/python3.5m -Wl,-no_pie conftest.c -lncurses -lm
-liconv -L/usr/loc
al/Cellar/python3/3.5.1/Frameworks/Python.framework/Versions/3.5/lib/python3.5/config-3.5m
-ldl -framework CoreFoundation -lpython3.5m -u _PyMac_Error
/usr/local/opt/python3/Frameworks/Python. framework/Versions/3.5/Python >&5
1109 Undefined symbols for architecture x86_64:
1110 "_PyMac_Error", referenced from:
1111 -u command line option
1112 ld: symbol(s) not found for architecture x86_64
1113 clang: error: linker command failed with exit code 1 (use -v to see
invocation)
```
python3
```
>>> from distutils import sysconfig
>>> getvar = sysconfig.get_config_var
>>> getvar('LINKFORSHARED')
'-u _PyMac_Error
/usr/local/opt/python3/Frameworks/Python.framework/Versions/3.5/Python'
```
It can be built by removing these two lines.
```
diff --git a/gdb/python/python-config.py b/gdb/python/python-config
--- a/gdb/python/python-config.py 2015-12-18 22:46:55.000000000 +0800
+++ b/gdb/python/python-config.py 2015-12-18 22:47:22.000000000 +0800
@@ -72,7 +72,5 @@
libs.insert(0, '-L' + getvar('LIBPL'))
elif os.name == 'nt':
libs.insert(0, '-L' + sysconfig.PREFIX + '/libs')
- if getvar('LINKFORSHARED') is not None:
- libs.extend(getvar('LINKFORSHARED').split())
print (to_unix_path(' '.join(libs)))
```
Any suggestions?
--
You are receiving this mail because:
You are on the CC list for the bug.