From 8b0251ae4b4ce35aa174aa1d2391df433924d6ad Mon Sep 17 00:00:00 2001 From: Sears Russell Date: Fri, 7 Nov 2008 08:18:46 +0000 Subject: [PATCH] Fix conditional compilation for flex / bison --- src/apps/referential/lang/CMakeLists.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/apps/referential/lang/CMakeLists.txt b/src/apps/referential/lang/CMakeLists.txt index d4d2dd9..29b5bb5 100644 --- a/src/apps/referential/lang/CMakeLists.txt +++ b/src/apps/referential/lang/CMakeLists.txt @@ -1,3 +1,4 @@ +if(BISON_EXECUTABLE) BISON_TARGET(RefParser ${CMAKE_CURRENT_SOURCE_DIR}/parse.y ${CMAKE_CURRENT_BINARY_DIR}/y.tab.c) FLEX_TARGET(RefParser ${CMAKE_CURRENT_SOURCE_DIR}/lexer.l ${CMAKE_CURRENT_BINARY_DIR}/lex.yy.c) #SET(INCLUDE_DIR ${INCLUDE_DIR} ${CMAKE_CURRENT_SOURCE_DIR}) @@ -7,4 +8,4 @@ ADD_EXECUTABLE(parse_test ${CMAKE_CURRENT_BINARY_DIR}/lex.yy.c ${CMAKE_CURRENT_B SET_TARGET_PROPERTIES(refparse PROPERTIES COMPILE_FLAGS "-Wno-implicit -Wno-unused -I ${CMAKE_CURRENT_SOURCE_DIR}") SET_TARGET_PROPERTIES(parse_test PROPERTIES COMPILE_FLAGS "-Wno-implicit -Wno-unused -I ${CMAKE_CURRENT_SOURCE_DIR}") ADD_TEST(test_parser ${CMAKE_CURRENT_SOURCE_DIR}/test_parser.pl) - +endif(BISON_EXECUTABLE)