summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnthony Mallet <anthony.mallet@laas.fr>2011-11-20 19:01:05 +0100
committerAnthony Mallet <anthony.mallet@laas.fr>2011-11-20 19:01:05 +0100
commit94febb4483269542fdb11a805ba9449ab04a5875 (patch)
treeb8564a5d0c0af4e6aaa11100259d0fdfccc4b853
parent57d3c648e6b65639ba00a6bfd732dd69380d3283 (diff)
downloadeltclsh-94febb4483269542fdb11a805ba9449ab04a5875.tar.gz
Use LIBS instead of LDFLAGS when looking for libtcl in configure.ac
When using AC_TRY_LINK, LDFLAGS is passed before source file, while LIBS is passed after. So one must put -ltcl in LIBS rather than LDFLAGS. Note: I have no idea why this worked before nor why this suddenly stopped working with ubuntu-11.10 only.
-rw-r--r--m4/robots.m410
1 files changed, 5 insertions, 5 deletions
diff --git a/m4/robots.m4 b/m4/robots.m4
index 8a8d69f..5f526df 100644
--- a/m4/robots.m4
+++ b/m4/robots.m4
@@ -273,7 +273,7 @@ AC_DEFUN([ROBOT_LIB_TCL],
AC_MSG_CHECKING([for tcl library])
AC_LANG([C])
ac_tmp_cppflags=$CPPFLAGS; CPPFLAGS="${CPPFLAGS} ${TCL_INCLUDE_SPEC}"
- ac_tmp_ldflags=$LDFLAGS; LDFLAGS="${LDFLAGS} ${TCL_LIB_SPEC}"
+ ac_tmp_libs=$LIBS; LIBS="${LIBS} ${TCL_LIB_SPEC}"
AC_TRY_LINK([#include "$tcl_test_include"], [Tcl_Interp *i; Tcl_Init(i);],[
AC_MSG_RESULT([${TCL_LIB_SPEC}])
],[
@@ -281,7 +281,7 @@ AC_DEFUN([ROBOT_LIB_TCL],
AC_MSG_ERROR([tcl libraries seem not to be installed or cannot be linked.])
])
CPPFLAGS=$ac_tmp_cppflags
- LDFLAGS=$ac_tmp_ldflags
+ LIBS=$ac_tmp_libs
# Add libtool -R flag to the runtime path of tcl
AC_PROG_SED
@@ -367,9 +367,9 @@ AC_DEFUN([ROBOT_LIB_TK],
AC_MSG_CHECKING([for tk library])
AC_LANG([C])
ac_tmp_cppflags=$CPPFLAGS;
- ac_tmp_ldflags=$LDFLAGS;
+ ac_tmp_libs=$LIBS;
CPPFLAGS="${CPPFLAGS} ${TK_INCLUDE_SPEC} ${TCL_INCLUDE_SPEC}"
- LDFLAGS="${LDFLAGS} ${TK_LIB_SPEC} ${TCL_LIB_SPEC}"
+ LIBS="${LIBS} ${TK_LIB_SPEC} ${TCL_LIB_SPEC}"
AC_TRY_LINK([#include "$tk_test_include"], [Tcl_Interp *i; Tk_Init(i);],[
AC_MSG_RESULT([${TK_LIB_SPEC}])
],[
@@ -377,7 +377,7 @@ AC_DEFUN([ROBOT_LIB_TK],
AC_MSG_ERROR([tk libraries seem not to be installed or cannot be linked.])
])
CPPFLAGS=$ac_tmp_cppflags
- LDFLAGS=$ac_tmp_ldflags
+ LIBS=$ac_tmp_libs
# Add libtool -R flag to the runtime path of tcl
AC_PROG_SED