summaryrefslogtreecommitdiff
path: root/sim/erc32/configure.ac
diff options
context:
space:
mode:
authorHans-Peter Nilsson <hp@axis.com>2006-12-20 22:35:51 +0000
committerHans-Peter Nilsson <hp@axis.com>2006-12-20 22:35:51 +0000
commit85f7420302fdd5744812b28da6d6464faa42bc66 (patch)
treef804104805ee3833d4cd0b76d13520be04358bd7 /sim/erc32/configure.ac
parent63e3b390f9edf0c631bec827604aec236f4972b5 (diff)
downloadgdb-85f7420302fdd5744812b28da6d6464faa42bc66.tar.gz
* configure.ac: Add test for readline, substitute READLINE.
* Makefile.in (READLINE_LIB): New substituted-contents variable. (SIM_EXTRA_LIBDEPS): Don't set. (SIM_EXTRA_LIBS): Use $(READLINE_LIB) instead of ../../readline/libreadline.a. * configure: Regenerate.
Diffstat (limited to 'sim/erc32/configure.ac')
-rw-r--r--sim/erc32/configure.ac9
1 files changed, 9 insertions, 0 deletions
diff --git a/sim/erc32/configure.ac b/sim/erc32/configure.ac
index f1aeadac36d..7637a771b03 100644
--- a/sim/erc32/configure.ac
+++ b/sim/erc32/configure.ac
@@ -25,4 +25,13 @@ else
fi
AC_SUBST(TERMCAP)
+# We prefer the in-tree readline. Top-level dependencies make sure
+# src/readline (if it's there) is configured before src/sim.
+if test -r ../../readline/Makefile; then
+ READLINE=../../readline/libreadline.a
+else
+ AC_CHECK_LIB(readline, readline, READLINE=-lreadline,
+ AC_ERROR([the required "readline" library is missing]), $TERMCAP)
+fi
+AC_SUBST(READLINE)
SIM_AC_OUTPUT