diff options
author | Mathias Preiner <mathias.preiner@gmail.com> | 2018-09-10 11:35:14 -0700 |
---|---|---|
committer | Mathias Preiner <mathias.preiner@gmail.com> | 2018-09-22 16:30:59 -0700 |
commit | 52281cf25960740c46275783cf62c881fa8ef703 (patch) | |
tree | e7275fc10e1041ed6f66f4a754d15c1ead6f8fe1 /src/parser | |
parent | 9a1507d1907e7a504fc67d14b4ecb0a1fa1ed10f (diff) |
cmake: Move find_package to where it is actually needed.
Diffstat (limited to 'src/parser')
-rw-r--r-- | src/parser/CMakeLists.txt | 6 | ||||
-rw-r--r-- | src/parser/cvc/CMakeLists.txt | 1 | ||||
-rw-r--r-- | src/parser/smt1/CMakeLists.txt | 1 | ||||
-rw-r--r-- | src/parser/smt2/CMakeLists.txt | 1 | ||||
-rw-r--r-- | src/parser/tptp/CMakeLists.txt | 1 |
5 files changed, 6 insertions, 4 deletions
diff --git a/src/parser/CMakeLists.txt b/src/parser/CMakeLists.txt index 6a7f77ea3..52fa55f9d 100644 --- a/src/parser/CMakeLists.txt +++ b/src/parser/CMakeLists.txt @@ -23,6 +23,12 @@ set(cvc4parser_src_files parser_exception.h ) +set(ANTLR_HOME ${ANTLR_DIR}) +find_package(ANTLR REQUIRED) + +# Java runtime is required for ANTLR +find_package(Java COMPONENTS Runtime REQUIRED) + add_library(cvc4parser ${cvc4parser_src_files}) set_target_properties(cvc4parser diff --git a/src/parser/cvc/CMakeLists.txt b/src/parser/cvc/CMakeLists.txt index ab88ffe1b..c75df0ab4 100644 --- a/src/parser/cvc/CMakeLists.txt +++ b/src/parser/cvc/CMakeLists.txt @@ -14,7 +14,6 @@ add_custom_command( ${ANTLR_BINARY} ${CMAKE_CURRENT_SOURCE_DIR}/Cvc.g -fo ${CMAKE_CURRENT_BINARY_DIR} - 2> /dev/null # Ignore Antlr3 warnings DEPENDS Cvc.g ) diff --git a/src/parser/smt1/CMakeLists.txt b/src/parser/smt1/CMakeLists.txt index 2dd0bfd9b..cd27bb513 100644 --- a/src/parser/smt1/CMakeLists.txt +++ b/src/parser/smt1/CMakeLists.txt @@ -16,7 +16,6 @@ add_custom_command( ${ANTLR_BINARY} ${CMAKE_CURRENT_SOURCE_DIR}/Smt1.g -fo ${CMAKE_CURRENT_BINARY_DIR} - 2> /dev/null # Ignore Antlr3 warnings DEPENDS Smt1.g ) diff --git a/src/parser/smt2/CMakeLists.txt b/src/parser/smt2/CMakeLists.txt index 90cc391b0..f3258839e 100644 --- a/src/parser/smt2/CMakeLists.txt +++ b/src/parser/smt2/CMakeLists.txt @@ -18,7 +18,6 @@ add_custom_command( ${ANTLR_BINARY} ${CMAKE_CURRENT_SOURCE_DIR}/Smt2.g -fo ${CMAKE_CURRENT_BINARY_DIR} - 2> /dev/null # Ignore Antlr3 warnings DEPENDS Smt2.g ) diff --git a/src/parser/tptp/CMakeLists.txt b/src/parser/tptp/CMakeLists.txt index aadd47a2a..5712e8175 100644 --- a/src/parser/tptp/CMakeLists.txt +++ b/src/parser/tptp/CMakeLists.txt @@ -16,7 +16,6 @@ add_custom_command( ${ANTLR_BINARY} ${CMAKE_CURRENT_SOURCE_DIR}/Tptp.g -fo ${CMAKE_CURRENT_BINARY_DIR} - 2> /dev/null # Ignore Antlr3 warnings DEPENDS Tptp.g ) |