summaryrefslogtreecommitdiffstats
path: root/configure
diff options
context:
space:
mode:
authorChris Johns <chrisj@rtems.org>2019-07-02 09:57:28 +1000
committerJiri Gaisler <jiri@gaisler.se>2019-07-02 22:03:52 +0200
commitd509fe6c57f18e2534c586e7dde844811c76a146 (patch)
tree6e667f33725e141a9af9ae166f9ecbfa1c90deb2 /configure
parentelf_load() failed in interactive shell. (diff)
downloadsis-d509fe6c57f18e2534c586e7dde844811c76a146.tar.bz2
Make readline conditional and add linenoise it not present.
- Readline is not present on all hosts is used on and it has not been a requirement. Rather than break all hosts that are working this patch conditionally adds linenoise a small simple realline replacement.
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure28
1 files changed, 22 insertions, 6 deletions
diff --git a/configure b/configure
index bd85564..ae26489 100755
--- a/configure
+++ b/configure
@@ -623,6 +623,9 @@ ac_subst_vars='am__EXEEXT_FALSE
am__EXEEXT_TRUE
LTLIBOBJS
LIBOBJS
+LINENOISE
+LINENOISE_FALSE
+LINENOISE_TRUE
READLINE
EGREP
GREP
@@ -3978,9 +3981,6 @@ fi
done
-ac_config_files="$ac_config_files Makefile"
-
-
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for readline in -lreadline" >&5
$as_echo_n "checking for readline in -lreadline... " >&6; }
if ${ac_cv_lib_readline_readline+:} false; then :
@@ -4018,12 +4018,25 @@ fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_readline" >&5
$as_echo "$ac_cv_lib_readline_readline" >&6; }
if test "x$ac_cv_lib_readline_readline" = xyes; then :
- READLINE=-lreadline
+
+$as_echo "#define HAVE_READLINE 1" >>confdefs.h
+ READLINE=-lreadline linenoise=false
else
- as_fn_error $? "the required \"readline\" library is missing" "$LINENO" 5
+ linenoise=true
fi
+ if test x$linenoise = xtrue; then
+ LINENOISE_TRUE=
+ LINENOISE_FALSE='#'
+else
+ LINENOISE_TRUE='#'
+ LINENOISE_FALSE=
+fi
+
+
+ac_config_files="$ac_config_files Makefile"
+
# Check whether --enable-l1cache was given.
if test "${enable_l1cache+set}" = set; then :
@@ -4394,6 +4407,10 @@ if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
Usually this means the macro was only invoked conditionally." "$LINENO" 5
fi
+if test -z "${LINENOISE_TRUE}" && test -z "${LINENOISE_FALSE}"; then
+ as_fn_error $? "conditional \"LINENOISE\" was never defined.
+Usually this means the macro was only invoked conditionally." "$LINENO" 5
+fi
: "${CONFIG_STATUS=./config.status}"
@@ -5716,4 +5733,3 @@ if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
fi
-