OS X: Use -iframework with Clang only on version >= 3.2

Since commit v3.1.0-rc1~564^2 (OS X: Use -iframework for system
framework directories, 2014-05-05) we test the version of Clang is smaller
that 3.1 to see if it supports -iframework.

Considering that "iframework" support has been added in clang@r142418
(Frontend: Support -iframework.) prior to clang 3.1, this made sense.

That said, considering that support for multiple -iframework parameters
has been added later in clang@r164607 (-iframework should allow separate
arguments. ) prior to clang 3.2, this commit updates the check to enable
framework support only if version is >= 3.2
This commit is contained in:
Jean-Christophe Fillion-Robin 2016-03-09 00:50:21 -05:00 committed by Brad King
parent eb094da60b
commit 63c4133b38
1 changed files with 1 additions and 1 deletions

View File

@ -24,7 +24,7 @@ macro(__darwin_compiler_clang lang)
set(CMAKE_SHARED_MODULE_CREATE_${lang}_FLAGS "-bundle -Wl,-headerpad_max_install_names") set(CMAKE_SHARED_MODULE_CREATE_${lang}_FLAGS "-bundle -Wl,-headerpad_max_install_names")
set(CMAKE_${lang}_SYSROOT_FLAG "-isysroot") set(CMAKE_${lang}_SYSROOT_FLAG "-isysroot")
set(CMAKE_${lang}_OSX_DEPLOYMENT_TARGET_FLAG "-mmacosx-version-min=") set(CMAKE_${lang}_OSX_DEPLOYMENT_TARGET_FLAG "-mmacosx-version-min=")
if(NOT CMAKE_${lang}_COMPILER_VERSION VERSION_LESS 3.1) if(NOT CMAKE_${lang}_COMPILER_VERSION VERSION_LESS 3.2)
set(CMAKE_${lang}_SYSTEM_FRAMEWORK_SEARCH_FLAG "-iframework ") set(CMAKE_${lang}_SYSTEM_FRAMEWORK_SEARCH_FLAG "-iframework ")
endif() endif()
endmacro() endmacro()