Skip to content

Commit

Permalink
feat: add option to exclude building examples
Browse files Browse the repository at this point in the history
  • Loading branch information
plusk01 committed Dec 9, 2020
1 parent caaa4ee commit 9baaf1d
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ add_library(plot INTERFACE)
target_include_directories(plot INTERFACE include)

option(BUILD_SINGLE_HEADER "Pack all headers into a single header library" OFF)
option(BUILD_EXAMPLES "Build plot examples" ON)

if(BUILD_SINGLE_HEADER)
find_package(PythonInterp 3 REQUIRED)
Expand Down Expand Up @@ -66,4 +67,7 @@ if(BUILD_SINGLE_HEADER)
single-header ALL DEPENDS "${CMAKE_CURRENT_BINARY_DIR}/plot.hpp")
endif()

add_subdirectory(examples)

if(BUILD_EXAMPLES)
add_subdirectory(examples)
endif()

0 comments on commit 9baaf1d

Please sign in to comment.