changeset: 92730:b826ba76d1ce branch: 3.4 parent: 92727:3bff73df6dab user: doko@ubuntu.com date: Thu Oct 02 02:00:14 2014 +0200 files: Misc/NEWS Misc/python-config.in Misc/python-config.sh.in description: - Issue #18096: Fix library order returned by python-config. diff -r 3bff73df6dab -r b826ba76d1ce Misc/NEWS --- a/Misc/NEWS Thu Oct 02 00:09:37 2014 +0300 +++ b/Misc/NEWS Thu Oct 02 02:00:14 2014 +0200 @@ -38,6 +38,8 @@ - Issue #16537: Check whether self.extensions is empty in setup.py. Patch by Jonathan Hosmer. +- Issue #18096: Fix library order returned by python-config. + What's New in Python 3.4.2? =========================== diff -r 3bff73df6dab -r b826ba76d1ce Misc/python-config.in --- a/Misc/python-config.in Thu Oct 02 00:09:37 2014 +0300 +++ b/Misc/python-config.in Thu Oct 02 02:00:14 2014 +0200 @@ -47,8 +47,9 @@ print(' '.join(flags)) elif opt in ('--libs', '--ldflags'): - libs = getvar('LIBS').split() + getvar('SYSLIBS').split() - libs.append('-lpython' + pyver + sys.abiflags) + libs = ['-lpython' + pyver + sys.abiflags] + libs += getvar('LIBS').split() + libs += getvar('SYSLIBS').split() # add the prefix/lib/pythonX.Y/config dir, but only if there is no # shared library in prefix/lib/. if opt == '--ldflags': diff -r 3bff73df6dab -r b826ba76d1ce Misc/python-config.sh.in --- a/Misc/python-config.sh.in Thu Oct 02 00:09:37 2014 +0300 +++ b/Misc/python-config.sh.in Thu Oct 02 02:00:14 2014 +0200 @@ -40,7 +40,7 @@ LIBC="@LIBC@" SYSLIBS="$LIBM $LIBC" ABIFLAGS="@ABIFLAGS@" -LIBS="@LIBS@ $SYSLIBS -lpython${VERSION}${ABIFLAGS}" +LIBS="-lpython${VERSION}${ABIFLAGS} @LIBS@ $SYSLIBS" BASECFLAGS="@BASECFLAGS@" LDLIBRARY="@LDLIBRARY@" LINKFORSHARED="@LINKFORSHARED@"