|
|
@@ -836,21 +836,29 @@ macro (cotire_add_definitions_to_cmd _cmdVar _language) |
|
|
|
endforeach() |
|
|
|
endmacro() |
|
|
|
|
|
|
|
macro (cotire_add_includes_to_cmd _cmdVar _language _includesVar _systemIncludesVar) |
|
|
|
foreach (_include ${${_includesVar}}) |
|
|
|
if (WIN32 AND CMAKE_${_language}_COMPILER_ID MATCHES "MSVC|Intel") |
|
|
|
file (TO_NATIVE_PATH "${_include}" _include) |
|
|
|
list (APPEND ${_cmdVar} "${CMAKE_INCLUDE_FLAG_${_language}}${CMAKE_INCLUDE_FLAG_${_language}_SEP}${_include}") |
|
|
|
else() |
|
|
|
list (FIND ${_systemIncludesVar} "${_include}" _index) |
|
|
|
if (_index GREATER -1 AND CMAKE_INCLUDE_SYSTEM_FLAG_${_language}) |
|
|
|
list (APPEND ${_cmdVar} "${CMAKE_INCLUDE_SYSTEM_FLAG_${_language}}${_include}") |
|
|
|
else() |
|
|
|
function (cotire_add_includes_to_cmd _cmdVar _language _includesVar _systemIncludesVar) |
|
|
|
set (_includeDirs ${${_includesVar}} ${${_systemIncludesVar}}) |
|
|
|
if (_includeDirs) |
|
|
|
list (REMOVE_DUPLICATES _includeDirs) |
|
|
|
foreach (_include ${_includeDirs}) |
|
|
|
if (WIN32 AND CMAKE_${_language}_COMPILER_ID MATCHES "MSVC|Intel") |
|
|
|
file (TO_NATIVE_PATH "${_include}" _include) |
|
|
|
list (APPEND ${_cmdVar} "${CMAKE_INCLUDE_FLAG_${_language}}${CMAKE_INCLUDE_FLAG_${_language}_SEP}${_include}") |
|
|
|
else() |
|
|
|
set (_index -1) |
|
|
|
if ("${CMAKE_INCLUDE_SYSTEM_FLAG_${_language}}" MATCHES ".+") |
|
|
|
list (FIND ${_systemIncludesVar} "${_include}" _index) |
|
|
|
endif() |
|
|
|
if (_index GREATER -1) |
|
|
|
list (APPEND ${_cmdVar} "${CMAKE_INCLUDE_SYSTEM_FLAG_${_language}}${_include}") |
|
|
|
else() |
|
|
|
list (APPEND ${_cmdVar} "${CMAKE_INCLUDE_FLAG_${_language}}${CMAKE_INCLUDE_FLAG_${_language}_SEP}${_include}") |
|
|
|
endif() |
|
|
|
endif() |
|
|
|
endif() |
|
|
|
endforeach() |
|
|
|
endmacro() |
|
|
|
endforeach() |
|
|
|
endif() |
|
|
|
set (${_cmdVar} ${${_cmdVar}} PARENT_SCOPE) |
|
|
|
endfunction() |
|
|
|
|
|
|
|
macro (cotire_add_frameworks_to_cmd _cmdVar _language) |
|
|
|
if (APPLE) |
|
|
|