]> git.ipfire.org Git - thirdparty/kea.git/commitdiff
[4125] Made the parser target dependent on --enable-generate-parser
authorFrancis Dupont <fdupont@isc.org>
Sat, 14 Nov 2015 19:17:01 +0000 (20:17 +0100)
committerFrancis Dupont <fdupont@isc.org>
Sat, 14 Nov 2015 19:17:01 +0000 (20:17 +0100)
configure.ac
src/lib/eval/Makefile.am

index 7f228e54ec23faf85c831047f471a109c7fa76f8..4c247d0026d1dfe76a532e29fc05e9458b4b3e1e 100755 (executable)
@@ -1255,6 +1255,8 @@ EOF
     $RM -f bisontest.y bisontest.cc
 fi
 
+AM_CONDITIONAL([GENERATE_PARSER], [test x$enable_generate_parser != xno])
+
 AC_ARG_ENABLE(generate_docs, [AC_HELP_STRING([--enable-generate-docs],
   [regenerate documentation using Docbook [default=no]])],
   enable_generate_docs=$enableval, enable_generate_docs=no)
index e95a6d88d2a6e891ea69a584f44e5855350b02dd..b2c939409a629dc9e266e43e2ca93f066dca594d 100644 (file)
@@ -73,6 +73,8 @@ maintainer-clean-local:
 # Make sure you have both flex and bison installed.
 parser-clean: maintainer-clean-local
 
+if GENERATE_PARSER
+
 parser: lexer.cc location.hh position.hh stack.hh parser.cc parser.h
        @echo "Flex/bison files regenerated"
 
@@ -82,3 +84,10 @@ location.hh position.hh stack.hh parser.cc parser.h: parser.yy
 
 lexer.cc: lexer.ll
        $(LEX) -o lexer.cc lexer.ll
+
+else
+
+parser location.hh position.hh stack.hh parser.cc parser.h lexer.cc:
+       @echo Parser generation disabled. Configure with --enable-generate-parser to enable it.
+
+endif