summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorljfa-ag <ljfa-ag@web.de>2015-09-22 17:21:51 +0200
committerljfa <ljfa-ag@web.de>2015-09-22 17:31:58 +0200
commit7f38044924fe5f13a61c3265a73d0045ddd2a1b2 (patch)
tree287cf4a5ffba3ebe45565fcb2e71121f81e827fc
parent9511d3c46dd8a1ad2f1c45a973d69bd048a0c5bf (diff)
downloadProject-Tick-7f38044924fe5f13a61c3265a73d0045ddd2a1b2.tar.gz
Project-Tick-7f38044924fe5f13a61c3265a73d0045ddd2a1b2.zip
Fix CMake CMP0063 warning
-rw-r--r--CMakeLists.txt6
1 files changed, 4 insertions, 2 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 12f816d285..2cde676fca 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -3,8 +3,6 @@ project(libnbt++
VERSION 2.3)
include(GenerateExportHeader)
-set(CMAKE_CXX_VISIBILITY_PRESET hidden)
-set(CMAKE_VISIBILITY_INLINES_HIDDEN 1)
find_package(ZLIB REQUIRED)
@@ -28,8 +26,12 @@ set(NBT_SOURCES
add_library(nbt++ ${NBT_SOURCES})
target_include_directories(nbt++ PUBLIC include ${CMAKE_CURRENT_BINARY_DIR})
target_link_libraries(nbt++ z)
+
target_compile_options(nbt++ PUBLIC -std=c++11)
generate_export_header(nbt++ BASE_NAME nbt)
+set_target_properties(nbt++ PROPERTIES
+ CXX_VISIBILITY_PRESET hidden
+ VISIBILITY_INLINES_HIDDEN 1)
option(BUILD_SHARED_LIBS "Build shared libraries" OFF)
option(NBT_BUILD_TESTS "Build the unit tests. Requires CxxTest." ON)