diff options
author | Yann Herklotz <ymherklotz@gmail.com> | 2018-04-06 15:42:02 +0100 |
---|---|---|
committer | Yann Herklotz <ymherklotz@gmail.com> | 2018-04-06 15:42:02 +0100 |
commit | e8e65c7593506fae3356bd9ab690fa0709d42bdf (patch) | |
tree | f65cc9d8a3f224999f76665f1c7f4084dc13e319 | |
parent | 52fae93d2903fc606bb0c4347a994a1b1285835b (diff) | |
download | YAGE-e8e65c7593506fae3356bd9ab690fa0709d42bdf.tar.gz YAGE-e8e65c7593506fae3356bd9ab690fa0709d42bdf.zip |
Adding option to build examples
-rw-r--r-- | CMakeLists.txt | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index bbf66d77..bcd8644a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -5,8 +5,9 @@ project(yage VERSION 0.1.4.0 LANGUAGES CXX) -option(YAGE_BUILD_TESTS "Build tests and ctest testing suite" ON) -option(YAGE_BUILD_DOCS "Build documentation using Doxygen" ON) +option(YAGE_BUILD_TESTS "Build tests and ctest testing suite" OFF) +option(YAGE_BUILD_DOCS "Build documentation using Doxygen" OFF) +option(YAGE_BUILD_EXAMPLES "Build example executables" OFF) # set standard set(CMAKE_CXX_STANDARD 14) @@ -61,12 +62,14 @@ target_link_libraries(yage ${GLFW_LIBRARIES} glad) -add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/examples) +if(${YAGE_BUILD_EXAMPLES}) -if(${YAGE_BUILD_TESTS}) + add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/examples) - add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/tests) +endif(${YAGE_BUILD_EXAMPLES}) +if(${YAGE_BUILD_TESTS}) + add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/tests) endif(${YAGE_BUILD_TESTS}) if(${YAGE_BUILD_DOCS}) @@ -91,6 +94,6 @@ if(${YAGE_BUILD_DOCS}) message("Doxygen needs to be installed to generate the documentation.") endif(DOXYGEN_FOUND) - -endif(${YAGE_BUILD_DOCS}) +endif(${YAGE_BUILD_DOCS}) + |