[libc++] Disable -Wattributes in GCC
authorNikolas Klauser <nikolasklauser@berlin.de>
Mon, 7 Feb 2022 15:07:01 +0000 (16:07 +0100)
committerNikolas Klauser <nikolasklauser@berlin.de>
Mon, 7 Feb 2022 18:58:25 +0000 (19:58 +0100)
Currently GCC produces lots of warnings. Most of them are `-Wattributes`, but these warnings are completly ignored by everybody. So let's disable -Wattributes and make the output cleaner.

Reviewed By: ldionne, #libc

Spies: libcxx-commits, mgorny

Differential Revision: https://reviews.llvm.org/D119140

libcxx/CMakeLists.txt

index 00fc9b3175158c5eb73ad3d866bb5c4645c0fd10..3c6bd0fbbd0d11a33d4f42d532ab87ab74d4ce93 100644 (file)
@@ -623,6 +623,7 @@ function(cxx_add_warning_flags target)
     endif()
   elseif("${CMAKE_CXX_COMPILER_ID}" MATCHES "GNU")
     target_add_compile_flags_if_supported(${target} PRIVATE
+      -Wno-attributes
       -Wno-literal-suffix
       -Wno-c++14-compat
       -Wno-noexcept-type