Created
February 12, 2019 20:44
-
-
Save Ben1980/944ad24d8997123ad3194e8487fddccb to your computer and use it in GitHub Desktop.
Root CMakeLists.txt file of n-body-project
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cmake_minimum_required(VERSION 3.1...3.13) | |
if(${CMAKE_VERSION} VERSION_LESS 3.12) | |
cmake_policy(VERSION ${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION}) | |
endif() | |
project(gravity VERSION 0.1.0 | |
DESCRIPTION "N-Body-Problem project of https://thoughts-on-cpp.com" | |
LANGUAGES CXX) | |
list(APPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake/") | |
include(GNUInstallDirs) | |
find_package(Catch 2.6.0 REQUIRED) | |
if(CATCH_FOUND) | |
message(STATUS "Building interpreter tests using Catch v${CATCH_VERSION}") | |
else() | |
message(STATUS "Catch not detected. Interpreter tests will be skipped. Install Catch headers" | |
" manually or use `cmake -DDOWNLOAD_CATCH=1` to fetch them automatically.") | |
return() | |
endif() | |
add_library(Catch INTERFACE) | |
target_include_directories(Catch | |
INTERFACE | |
${CATCH_INCLUDE_DIR}) | |
include(CTest) | |
add_subdirectory(solver solver) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment