From 7f690c5c00221486c90b09c3c222b65b2a33c7d0 Mon Sep 17 00:00:00 2001 From: Michael Schellenberger Costa Date: Wed, 18 Sep 2024 17:24:13 +0200 Subject: [PATCH] [DO_NOT_MERGE] disable system header escape hatch --- cmake/CCCLBuildCompilerTargets.cmake | 3 --- libcudacxx/test/utils/libcudacxx/test/config.py | 1 - thrust/testing/CMakeLists.txt | 3 --- 3 files changed, 7 deletions(-) diff --git a/cmake/CCCLBuildCompilerTargets.cmake b/cmake/CCCLBuildCompilerTargets.cmake index 5f2784ba38..aa0176893a 100644 --- a/cmake/CCCLBuildCompilerTargets.cmake +++ b/cmake/CCCLBuildCompilerTargets.cmake @@ -50,9 +50,6 @@ function(cccl_build_compiler_targets) list(APPEND cuda_compile_definitions "-Xcudafe=--promote_warnings") list(APPEND cuda_compile_definitions "-Wno-deprecated-gpu-targets") - # Ensure that we build our tests without treating ourself as system header - list(APPEND cxx_compile_definitions "_CCCL_NO_SYSTEM_HEADER") - if ("MSVC" STREQUAL "${CMAKE_CXX_COMPILER_ID}") list(APPEND cuda_compile_options "--use-local-env") list(APPEND cxx_compile_options "/bigobj") diff --git a/libcudacxx/test/utils/libcudacxx/test/config.py b/libcudacxx/test/utils/libcudacxx/test/config.py index d1aef968a2..34f2f3a067 100644 --- a/libcudacxx/test/utils/libcudacxx/test/config.py +++ b/libcudacxx/test/utils/libcudacxx/test/config.py @@ -640,7 +640,6 @@ def configure_compile_flags(self): # Configure extra flags compile_flags_str = self.get_lit_conf('compile_flags', '') self.cxx.compile_flags += shlex.split(compile_flags_str) - self.cxx.compile_flags += ['-D_CCCL_NO_SYSTEM_HEADER'] if self.is_windows: # FIXME: Can we remove this? self.cxx.compile_flags += ['-D_CRT_SECURE_NO_WARNINGS'] diff --git a/thrust/testing/CMakeLists.txt b/thrust/testing/CMakeLists.txt index d60f60db7e..cb8d955f66 100644 --- a/thrust/testing/CMakeLists.txt +++ b/thrust/testing/CMakeLists.txt @@ -79,9 +79,6 @@ function(thrust_add_test target_name_var test_name test_src thrust_target) target_compile_definitions(${test_target} PRIVATE THRUST_TEST_DEVICE_SIDE) endif() - # Ensure that we build our tests without treating ourself as system header - target_compile_definitions(${test_target} PRIVATE "_CCCL_NO_SYSTEM_HEADER") - thrust_fix_clang_nvcc_build_for(${test_target}) # Add to the active configuration's meta target