Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/gabime/spdlog.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorgabime <gmelman1@gmail.com>2019-07-01 02:06:09 +0300
committergabime <gmelman1@gmail.com>2019-07-01 02:06:09 +0300
commitbb0f3839c1e52948f2ecb66e4e0aa79740a30205 (patch)
treef29cc018ae73dbf883b084d3700c98aae8af6617 /example
parentf09334dc6f6073a0f3cbeba9bd5e148f14514dd4 (diff)
Updated CMake options and defaults
Diffstat (limited to 'example')
-rw-r--r--example/CMakeLists.txt8
1 files changed, 5 insertions, 3 deletions
diff --git a/example/CMakeLists.txt b/example/CMakeLists.txt
index ac738161..b5fc4060 100644
--- a/example/CMakeLists.txt
+++ b/example/CMakeLists.txt
@@ -19,9 +19,11 @@ target_link_libraries(example PRIVATE spdlog::spdlog)
#---------------------------------------------------------------------------------------
# Example of using header-only library
#---------------------------------------------------------------------------------------
-add_executable(example_header_only example.cpp)
-spdlog_enable_warnings(example_header_only)
-target_link_libraries(example_header_only PRIVATE spdlog::spdlog_header_only)
+if(SPDLOG_BUILD_EXAMPLE_HO)
+ add_executable(example_header_only example.cpp)
+ spdlog_enable_warnings(example_header_only)
+ target_link_libraries(example_header_only PRIVATE spdlog::spdlog_header_only)
+endif()
# Create logs directory
file(MAKE_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/logs")