#-----------------------------------------------------------------------------#
-option(USE_CLN "Use CLN instead of GMP" OFF)
-option(ENABLE_PROOFS "Enable proof support" OFF)
-option(USE_SYMFPU "Use SymFPU for floating point support" OFF)
+option(ENABLE_PROOFS "Enable proof support" OFF)
+option(USE_CLN "Use CLN instead of GMP" OFF)
+option(USE_CRYPTOMINISAT "Use CryptoMiniSat SAT solver" OFF)
+option(USE_SYMFPU "Use SymFPU for floating point support" OFF)
#-----------------------------------------------------------------------------#
find_package(PythonInterp REQUIRED)
+find_package(ANTLR REQUIRED)
+cvc4_link_library(${ANTLR_LIBRARIES})
+include_directories(${ANTLR_INCLUDE_DIR})
+
find_package(GMP REQUIRED)
cvc4_link_library(${GMP_LIBRARIES})
include_directories(${GMP_INCLUDE_DIR})
include_directories(${CLN_INCLUDE_DIR})
endif()
+if(USE_CRYPTOMINISAT)
+ # CryptoMiniSat requires pthreads support
+ set(THREADS_PREFER_PTHREAD_FLAG ON)
+ find_package(Threads REQUIRED)
+ if(THREADS_HAVE_PTHREAD_ARG)
+ add_c_cxx_flag(-pthread)
+ endif()
+ find_package(CryptoMiniSat REQUIRED)
+ cvc4_link_library(${CryptoMiniSat_LIBRARIES})
+ include_directories(${CryptoMiniSat_INCLUDE_DIR})
+endif()
+
if(USE_SYMFPU)
find_package(SymFPU REQUIRED)
include_directories(${SymFPU_INCLUDE_DIR})
endif()
-find_package(ANTLR REQUIRED)
-cvc4_link_library(${ANTLR_LIBRARIES})
-include_directories(${ANTLR_INCLUDE_DIR})
-
#-----------------------------------------------------------------------------#
add_check_c_flag("-fexceptions")
set(CVC4_USE_GMP_IMP 1)
endif()
+if(USE_CRYPTOMINISAT)
+ add_definitions(-DCVC4_USE_CRYPTOMINISAT)
+endif()
+
if(USE_SYMFPU)
add_definitions(-DCVC4_USE_SYMFPU)
set(CVC4_USE_SYMFPU 1)
--- /dev/null
+# Find CryptoMiniSat
+# CryptoMiniSat_FOUND - system has CryptoMiniSat lib
+# CryptoMiniSat_INCLUDE_DIR - the CryptoMiniSat include directory
+# CryptoMiniSat_LIBRARIES - Libraries needed to use CryptoMiniSat
+
+find_path(CryptoMiniSat_INCLUDE_DIR
+ NAMES cryptominisat5/cryptominisat.h
+ PATHS "${PROJECT_SOURCE_DIR}/cryptominisat5/install/include")
+find_library(CryptoMiniSat_LIBRARIES
+ NAMES cryptominisat5
+ PATHS "${PROJECT_SOURCE_DIR}/cryptominisat5/install/lib")
+
+include(FindPackageHandleStandardArgs)
+find_package_handle_standard_args(CryptoMiniSat
+ DEFAULT_MSG
+ CryptoMiniSat_INCLUDE_DIR CryptoMiniSat_LIBRARIES)
+
+mark_as_advanced(CryptoMiniSat_INCLUDE_DIR CryptoMiniSat_LIBRARIES)