X-Git-Url: https://git.lizzy.rs/?a=blobdiff_plain;f=CMakeLists.txt;h=d8dd85af6e02c18ac9ef92965eea114c3bcd6828;hb=6f0c966877f83f585c6b3fd26f8b70e5d22525b3;hp=827191835d5bb2baa90fe754a4c847fbded21049;hpb=04bd253390cc6c67a555e4837e7e48d524fdf014;p=minetest.git diff --git a/CMakeLists.txt b/CMakeLists.txt index 827191835..d8dd85af6 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -52,6 +52,7 @@ set(RUN_IN_PLACE ${DEFAULT_RUN_IN_PLACE} CACHE BOOL set(BUILD_CLIENT TRUE CACHE BOOL "Build client") set(BUILD_SERVER FALSE CACHE BOOL "Build server") set(BUILD_UNITTESTS TRUE CACHE BOOL "Build unittests") +set(BUILD_BENCHMARKS FALSE CACHE BOOL "Build benchmarks") set(WARN_ALL TRUE CACHE BOOL "Enable -Wall for Release build") @@ -69,7 +70,7 @@ if(NOT "${IRRLICHTMT_BUILD_DIR}" STREQUAL "") find_package(IrrlichtMt QUIET PATHS "${IRRLICHTMT_BUILD_DIR}" NO_DEFAULT_PATH -) + ) if(NOT TARGET IrrlichtMt::IrrlichtMt) # find_package() searches certain subdirectories. ${PATH}/cmake is not @@ -280,6 +281,10 @@ elseif(CMAKE_CXX_COMPILER_ID MATCHES "(Apple)?Clang") endif() endif() +if(BUILD_BENCHMARKS) + add_subdirectory(lib/catch2) +endif() + # Subdirectories # Be sure to add all relevant definitions above this add_subdirectory(src)