aboutsummaryrefslogtreecommitdiff
path: root/gdb/configure
diff options
context:
space:
mode:
authorPaul Pluzhnikov <ppluzhnikov@google.com>2018-05-04 10:07:58 -0400
committerSimon Marchi <simon.marchi@ericsson.com>2018-05-04 10:08:09 -0400
commitbf27f0e2c76839af8524e053cca271934150a90c (patch)
treefae5cc97580cdf5b61489be7610f0124187c342e /gdb/configure
parent089a949083dcd5c679376033e975d54093007408 (diff)
downloadgdb-bf27f0e2c76839af8524e053cca271934150a90c.zip
gdb-bf27f0e2c76839af8524e053cca271934150a90c.tar.gz
gdb-bf27f0e2c76839af8524e053cca271934150a90c.tar.bz2
configure uses incorrect link order when testing libpython
References: https://stackoverflow.com/a/49868387 https://sourceware.org/bugzilla/show_bug.cgi?id=11420 Configure uses "gcc -o conftest -g ... conftest.c -ldl -lncurses -lm -ldl ... -lpthread ... -lpython2.7" when deciding whether give libpython is usable. That of course is the wrong link order, and only works for shared libraries (mostly by accident), and only on some systems. gdb/ChangeLog: PR gdb/11420 * configure.ac: Prepend libpython. * python/python-config.py: Likewise. * configure: Regenerate.
Diffstat (limited to 'gdb/configure')
-rwxr-xr-xgdb/configure18
1 files changed, 9 insertions, 9 deletions
diff --git a/gdb/configure b/gdb/configure
index f18d78e..1aac930 100755
--- a/gdb/configure
+++ b/gdb/configure
@@ -10441,7 +10441,7 @@ $as_echo_n "checking for ${version}... " >&6; }
save_CPPFLAGS=$CPPFLAGS
save_LIBS=$LIBS
CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
- LIBS="$LIBS $new_LIBS"
+ LIBS="$new_LIBS $LIBS"
found_usable_python=no
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
@@ -10478,13 +10478,13 @@ $as_echo "${found_usable_python}" >&6; }
version=python2.7
new_CPPFLAGS=${python_includes}
- new_LIBS="${python_libs} -lpython2.7"
+ new_LIBS="-lpython2.7 ${python_libs}"
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${version}" >&5
$as_echo_n "checking for ${version}... " >&6; }
save_CPPFLAGS=$CPPFLAGS
save_LIBS=$LIBS
CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
- LIBS="$LIBS $new_LIBS"
+ LIBS="$new_LIBS $LIBS"
found_usable_python=no
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
@@ -10516,13 +10516,13 @@ $as_echo "${found_usable_python}" >&6; }
version=python2.6
new_CPPFLAGS=${python_includes}
- new_LIBS="${python_libs} -lpython2.6"
+ new_LIBS="-lpython2.6 ${python_libs}"
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${version}" >&5
$as_echo_n "checking for ${version}... " >&6; }
save_CPPFLAGS=$CPPFLAGS
save_LIBS=$LIBS
CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
- LIBS="$LIBS $new_LIBS"
+ LIBS="$new_LIBS $LIBS"
found_usable_python=no
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
@@ -10554,13 +10554,13 @@ $as_echo "${found_usable_python}" >&6; }
version=python2.5
new_CPPFLAGS=${python_includes}
- new_LIBS="${python_libs} -lpython2.5"
+ new_LIBS="-lpython2.5 ${python_libs}"
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${version}" >&5
$as_echo_n "checking for ${version}... " >&6; }
save_CPPFLAGS=$CPPFLAGS
save_LIBS=$LIBS
CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
- LIBS="$LIBS $new_LIBS"
+ LIBS="$new_LIBS $LIBS"
found_usable_python=no
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */
@@ -10592,13 +10592,13 @@ $as_echo "${found_usable_python}" >&6; }
version=python2.4
new_CPPFLAGS=${python_includes}
- new_LIBS="${python_libs} -lpython2.4"
+ new_LIBS="-lpython2.4 ${python_libs}"
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${version}" >&5
$as_echo_n "checking for ${version}... " >&6; }
save_CPPFLAGS=$CPPFLAGS
save_LIBS=$LIBS
CPPFLAGS="$CPPFLAGS $new_CPPFLAGS"
- LIBS="$LIBS $new_LIBS"
+ LIBS="$new_LIBS $LIBS"
found_usable_python=no
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */