solidity/libsolidity/CMakeLists.txt

20 lines
750 B
CMake
Raw Normal View History

2017-05-23 17:21:14 +00:00
# Until we have a clear separation, libjulia has to be included here
2017-08-16 11:29:59 +00:00
file(GLOB_RECURSE sources "*.cpp" "../libjulia/*.cpp")
file(GLOB_RECURSE headers "*.h" "../libjulia/*.h")
2017-07-13 19:04:19 +00:00
find_package(Z3 QUIET)
if (${Z3_FOUND})
include_directories(${Z3_INCLUDE_DIR})
add_definitions(-DHAVE_Z3)
2017-10-13 12:33:18 +00:00
message("Z3 SMT solver found. This enables optional SMT checking.")
2017-07-13 19:04:19 +00:00
else()
2017-10-13 12:33:18 +00:00
message("Z3 SMT solver NOT found. Optional SMT checking will not be available. Please install Z3 if it is desired.")
2017-07-13 19:04:19 +00:00
list(REMOVE_ITEM sources "${CMAKE_CURRENT_SOURCE_DIR}/formal/Z3Interface.cpp")
endif()
2017-08-16 11:29:59 +00:00
add_library(solidity ${sources} ${headers})
2017-07-13 19:04:19 +00:00
target_link_libraries(solidity PUBLIC evmasm devcore)
if (${Z3_FOUND})
target_link_libraries(solidity PUBLIC ${Z3_LIBRARY})
endif()