Fix T48250: suppress CMake ranlib warnings to avoid issue with Qt Creator

Reviewed By: campbellbarton, brecht

Differential Revision: https://developer.blender.org/D1942
This commit is contained in:
Tianwei Shen 2016-04-23 15:44:26 +02:00 committed by Brecht Van Lommel
parent 16316115da
commit 39873891bf
Notes: blender-bot 2023-02-14 10:21:15 +01:00
Referenced by issue #48250, CMake error on mac with qt-creator
1 changed files with 6 additions and 0 deletions

View File

@ -2319,6 +2319,12 @@ elseif(APPLE)
endif()
# Get rid of eventually clashes, we export some symbols explicite as local
set(PLATFORM_LINKFLAGS "${PLATFORM_LINKFLAGS} -Xlinker -unexported_symbols_list -Xlinker ${CMAKE_SOURCE_DIR}/source/creator/osx_locals.map")
# Suppress ranlib "has no symbols" warnings
SET(CMAKE_C_ARCHIVE_CREATE "<CMAKE_AR> Scr <TARGET> <LINK_FLAGS> <OBJECTS>")
SET(CMAKE_CXX_ARCHIVE_CREATE "<CMAKE_AR> Scr <TARGET> <LINK_FLAGS> <OBJECTS>")
SET(CMAKE_C_ARCHIVE_FINISH "<CMAKE_RANLIB> -no_warning_for_no_symbols -c <TARGET>")
SET(CMAKE_CXX_ARCHIVE_FINISH "<CMAKE_RANLIB> -no_warning_for_no_symbols -c <TARGET>")
endif()
#-----------------------------------------------------------------------------