Исправлено подключение системных каталогов в cotire

This commit is contained in:
Andrei Astafev 2020-04-15 15:24:18 +03:00
parent 0b69005b7a
commit 9c6148ab82

View File

@ -931,7 +931,13 @@ function (cotire_add_includes_to_cmd _cmdVar _language _includesVar _systemInclu
list (FIND ${_systemIncludesVar} "${_include}" _index) list (FIND ${_systemIncludesVar} "${_include}" _index)
endif() endif()
if (_index GREATER -1) if (_index GREATER -1)
list (APPEND ${_cmdVar} "${CMAKE_INCLUDE_SYSTEM_FLAG_${_language}}${CMAKE_INCLUDE_FLAG_SEP_${_language}}${_include}") if (CMAKE_${_language}_COMPILER_ID MATCHES "GNU|Clang")
string(REPLACE " " "" _flag ${CMAKE_INCLUDE_SYSTEM_FLAG_${_language}})
list (APPEND ${_cmdVar} "${_flag}")
list (APPEND ${_cmdVar} "${_include}")
else()
list (APPEND ${_cmdVar} "${CMAKE_INCLUDE_SYSTEM_FLAG_${_language}}${CMAKE_INCLUDE_FLAG_SEP_${_language}}${_include}")
endif()
else() else()
list (APPEND ${_cmdVar} "${CMAKE_INCLUDE_FLAG_${_language}}${CMAKE_INCLUDE_FLAG_SEP_${_language}}${_include}") list (APPEND ${_cmdVar} "${CMAKE_INCLUDE_FLAG_${_language}}${CMAKE_INCLUDE_FLAG_SEP_${_language}}${_include}")
endif() endif()