mirror of
https://github.com/MaSzyna-EU07/maszyna.git
synced 2026-03-22 15:05:03 +01:00
do not make unnecessary exports on nix platforms
This commit is contained in:
@@ -9,6 +9,8 @@ if(POLICY CMP0069)
|
||||
cmake_policy(SET CMP0069 NEW)
|
||||
endif()
|
||||
|
||||
include(CheckCXXSymbolExists)
|
||||
|
||||
set(CMAKE_FIND_PACKAGE_PREFER_CONFIG TRUE)
|
||||
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/CMake_modules/")
|
||||
|
||||
@@ -329,6 +331,11 @@ set_target_properties( ${PROJECT_NAME}
|
||||
DEBUG_POSTFIX "_d"
|
||||
)
|
||||
|
||||
check_cxx_symbol_exists(__GNUC__ "" COMPILER_HAVE_GNUC)
|
||||
if (COMPILER_HAVE_GNUC)
|
||||
set_target_properties(${PROJECT_NAME} PROPERTIES COMPILE_FLAGS "-fvisibility=hidden")
|
||||
endif()
|
||||
|
||||
if(NOT ${CMAKE_VERSION} VERSION_LESS "3.16.0")
|
||||
option(USE_PCH "Use precompiled header" ON)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user