summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Marshall <rgm@linux.com>2012-11-19 20:20:22 -0800
committerRichard Marshall <rgm@linux.com>2012-11-19 20:33:26 -0800
commita2c4bd8f094a7247903578860a9c42049991860b (patch)
tree6d952a7966c6f033f23ea088432baf0bc3b4c9db
parent4d94ed5f6bd3492965882f080120fed9de7131a5 (diff)
downloadlibnl-baserock/morph.tar.gz
Updated configure.in to make sure bison and lex are installed.baserock/morph
Fixes issue #7
-rw-r--r--configure.in15
1 files changed, 14 insertions, 1 deletions
diff --git a/configure.in b/configure.in
index 9a190c2..a06bee1 100644
--- a/configure.in
+++ b/configure.in
@@ -68,7 +68,7 @@ AM_PROG_CC_C_O
AC_PROG_INSTALL
AM_PROG_LIBTOOL
AM_PROG_LEX
-AC_PROG_YACC
+AC_CHECK_PROGS(YACC, 'bison -y')
AC_C_CONST
AC_C_INLINE
@@ -118,6 +118,19 @@ python/netlink/route/Makefile
include/netlink/version.h
])
+ac_errcount=0
+if test -z "$YACC"; then
+ AC_MSG_WARN(bison not found. Please install before continuing.)
+ ac_errcount=$((ac_errcount + 1))
+fi
+if test -z "$LEXLIB"; then
+ AC_MSG_WARN(flex or lex not found. Please install before continuing.)
+ ac_errcount=$((ac_errcount + 1))
+fi
+if test $ac_errcount -gt 0; then
+ AC_MSG_ERROR(Required packages are missing. Please install them and rerun ./configure)
+fi
+
AC_OUTPUT
echo "-------------------------------------------------------------------------------"