NVHPC: Support SYSTEM include directories

Fixed #22834
This commit is contained in:
Robert Maynard
2021-11-02 09:57:55 -04:00
committed by Brad King
parent 28a033cc7d
commit 92624714c4
2 changed files with 2 additions and 0 deletions

View File

@@ -12,4 +12,5 @@ include(Compiler/PGI)
macro(__compiler_nvhpc lang)
# Logic specific to NVHPC.
set(CMAKE_INCLUDE_SYSTEM_FLAG_${lang} "-isystem ")
endmacro()

View File

@@ -3,6 +3,7 @@ project(IncludeDirectories)
if (((CMAKE_C_COMPILER_ID STREQUAL GNU AND CMAKE_C_COMPILER_VERSION VERSION_GREATER 4.4)
OR (CMAKE_C_COMPILER_ID STREQUAL Clang AND NOT "x${CMAKE_CXX_SIMULATE_ID}" STREQUAL "xMSVC")
OR CMAKE_C_COMPILER_ID STREQUAL NVHPC
OR CMAKE_C_COMPILER_ID STREQUAL AppleClang
OR ("x${CMAKE_C_COMPILER_ID}" STREQUAL "xMSVC" AND
CMAKE_C_COMPILER_VERSION VERSION_GREATER_EQUAL "19.29.30036.3" AND