bpo-36508: python-config don't export LINKFORSHARED (GH-12661) · python/cpython@e65f01f · GitHub
Skip to content

Commit e65f01f

Browse files
authored
bpo-36508: python-config don't export LINKFORSHARED (GH-12661)
python-config --ldflags no longer includes flags of the LINKFORSHARED variable. The LINKFORSHARED variable must only be used to build executables.
1 parent 2ee077f commit e65f01f

4 files changed

Lines changed: 6 additions & 8 deletions

File tree

Makefile.pre.in

Lines changed: 2 additions & 0 deletions
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
``python-config --ldflags`` no longer includes flags of the
2+
``LINKFORSHARED`` variable. The ``LINKFORSHARED`` variable must only be used
3+
to build executables.

Misc/python-config.in

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,8 +55,6 @@ for opt in opt_flags:
5555
if opt == '--ldflags':
5656
if not getvar('Py_ENABLE_SHARED'):
5757
libs.insert(0, '-L' + getvar('LIBPL'))
58-
if not getvar('PYTHONFRAMEWORK'):
59-
libs.extend(getvar('LINKFORSHARED').split())
6058
print(' '.join(libs))
6159

6260
elif opt == '--extension-suffix':

Misc/python-config.sh.in

Lines changed: 1 addition & 6 deletions

0 commit comments

Comments
 (0)