Skip to content

Commit c2c4f1c

Browse files
author
Yuanfang Chen
committed
[openmp][cmake] passing option argument correctly
From the context, it looks like the test should not be run with `check-all`, but it does. It turns out option argument resolving to True/False which could not be passed down as is. There is one such example in AddLLVM.cmake.
1 parent c84a0bd commit c2c4f1c

File tree

1 file changed

+16
-7
lines changed

1 file changed

+16
-7
lines changed

openmp/cmake/OpenMPTesting.cmake

Lines changed: 16 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -180,13 +180,22 @@ function(add_openmp_testsuite target comment)
180180
${cmake_3_2_USES_TERMINAL}
181181
)
182182
else()
183-
add_lit_testsuite(${target}
184-
${comment}
185-
${ARG_UNPARSED_ARGUMENTS}
186-
${ARG_EXCLUDE_FROM_CHECK_ALL}
187-
DEPENDS clang clang-resource-headers FileCheck ${ARG_DEPENDS}
188-
ARGS ${ARG_ARGS}
189-
)
183+
if (ARG_EXCLUDE_FROM_CHECK_ALL)
184+
add_lit_testsuite(${target}
185+
${comment}
186+
${ARG_UNPARSED_ARGUMENTS}
187+
EXCLUDE_FROM_CHECK_ALL
188+
DEPENDS clang clang-resource-headers FileCheck ${ARG_DEPENDS}
189+
ARGS ${ARG_ARGS}
190+
)
191+
else()
192+
add_lit_testsuite(${target}
193+
${comment}
194+
${ARG_UNPARSED_ARGUMENTS}
195+
DEPENDS clang clang-resource-headers FileCheck ${ARG_DEPENDS}
196+
ARGS ${ARG_ARGS}
197+
)
198+
endif()
190199
endif()
191200
endfunction()
192201

0 commit comments

Comments
 (0)