Skip to content

Commit

Permalink
enable --no-undefined only for linux
Browse files Browse the repository at this point in the history
  • Loading branch information
Rashad Kanavath committed Jan 30, 2018
1 parent 02bfe0a commit f6a2c0a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions CMakeLists.txt
Expand Up @@ -616,11 +616,11 @@ IF (WITH_CORE)
ENDIF(MSVC)
ENDIF(COMMAND cmake_policy)

IF (PEDANTIC AND NOT WIN32 AND NOT APPLE)
if("${CMAKE_SYSTEM_NAME}" MATCHES "Linux")
SET(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -Wl,--no-undefined")
SET(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -Wl,--no-undefined")
SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,--no-undefined")
ENDIF(PEDANTIC AND NOT WIN32 AND NOT APPLE)
endif() #"${CMAKE_SYSTEM_NAME}" MATCHES "Linux")

SET(CMAKE_CXX_VISIBILITY_PRESET hidden)
INCLUDE(GenerateExportHeader)
Expand Down

0 comments on commit f6a2c0a

Please sign in to comment.