Skip to content

Commit 1faaf69

Browse files
mgornygithub-actions[bot]
authored andcommitted
Automerge: [offload] [test] Use test compiler ID rather than host (#124408)
Use the test compiler ID to verify whether tests can be run rather than the host compiler. This makes it possible to run tests (with Clang) while the library itself was built with GCC. (cherry picked from commit 689ef5f)
2 parents d5c7ba5 + 28e563c commit 1faaf69

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

offload/test/CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# CMakeLists.txt file for unit testing OpenMP offloading runtime library.
2-
if(NOT CMAKE_CXX_COMPILER_ID STREQUAL "Clang" OR
3-
CMAKE_CXX_COMPILER_VERSION VERSION_LESS 6.0.0)
2+
if(NOT OPENMP_TEST_COMPILER_ID STREQUAL "Clang" OR
3+
OPENMP_TEST_COMPILER_VERSION VERSION_LESS 6.0.0)
44
message(STATUS "Can only test with Clang compiler in version 6.0.0 or later.")
55
message(WARNING "The check-offload target will not be available!")
66
return()

0 commit comments

Comments
 (0)