add hidden symbols options

This commit is contained in:
zhaowq32 2024-11-12 17:33:09 +08:00
parent 51a0deca2c
commit 7b2525469c

View File

@ -54,6 +54,12 @@ endif()
option(SPDLOG_BUILD_ALL "Build all artifacts" OFF)
option(SPDLOG_HIDDEN_SYMBOLS "Hidden symbols" OFF)
if(SPDLOG_HIDDEN_SYMBOLS)
set(CMAKE_CXX_VISIBILITY_PRESET hidden)
endif()
# build shared option
option(SPDLOG_BUILD_SHARED "Build shared library" OFF)