Skip to content

Commit 2249c00

Browse files
[SYCL][Unittest] Disable SYCL header warning in unittests (#19323)
The SYCL unittests include the SYCL headers without using -fsycl. To avoid the new warning for cases that uses this include pattern, we override the warning by defining the SYCL_DISABLE_FSYCL_SYCLHPP_WARNING preprocessor macro for all unittests. Signed-off-by: Larsen, Steffen <steffen.larsen@intel.com>
1 parent 858f2d1 commit 2249c00

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

sycl/cmake/modules/AddSYCLUnitTest.cmake

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -115,4 +115,6 @@ macro(add_sycl_unittest test_dirname link_variant)
115115
-Wno-inconsistent-missing-override
116116
)
117117
endif()
118+
119+
target_compile_definitions(${test_dirname} PRIVATE SYCL_DISABLE_FSYCL_SYCLHPP_WARNING)
118120
endmacro()

0 commit comments

Comments
 (0)