summaryrefslogtreecommitdiff
path: root/src/CMakeLists.txt
diff options
context:
space:
mode:
Diffstat (limited to 'src/CMakeLists.txt')
-rw-r--r--src/CMakeLists.txt14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index 03e48ddbd..7bba68a64 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -330,6 +330,7 @@ add_subdirectory(mapgen)
add_subdirectory(network)
add_subdirectory(script)
add_subdirectory(unittest)
+add_subdirectory(benchmark)
add_subdirectory(util)
add_subdirectory(irrlicht_changes)
add_subdirectory(server)
@@ -412,6 +413,9 @@ if(BUILD_UNITTESTS)
set(common_SRCS ${common_SRCS} ${UNITTEST_SRCS})
endif()
+if(BUILD_BENCHMARKS)
+ set(common_SRCS ${common_SRCS} ${BENCHMARK_SRCS})
+endif()
# This gives us the icon and file version information
if(WIN32)
@@ -452,6 +456,10 @@ if(BUILD_UNITTESTS)
set(client_SRCS ${client_SRCS} ${UNITTEST_CLIENT_SRCS})
endif()
+if(BUILD_BENCHMARKS)
+ set(client_SRCS ${client_SRCS} ${BENCHMARK_CLIENT_SRCS})
+endif()
+
list(SORT client_SRCS)
# Server sources
@@ -567,6 +575,9 @@ if(BUILD_CLIENT)
if (USE_SPATIAL)
target_link_libraries(${PROJECT_NAME} ${SPATIAL_LIBRARY})
endif()
+ if(BUILD_BENCHMARKS)
+ target_link_libraries(${PROJECT_NAME} catch2)
+ endif()
endif(BUILD_CLIENT)
@@ -626,6 +637,9 @@ if(BUILD_SERVER)
${CURL_LIBRARY}
)
endif()
+ if(BUILD_BENCHMARKS)
+ target_link_libraries(${PROJECT_NAME}server catch2)
+ endif()
endif(BUILD_SERVER)
# Blacklisted locales that don't work.