[PATCH] D118671: [Bazel] Don't fail the build on usage of deprecated APIs

Geoffrey Martin-Noble via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jan 31 18:10:04 PST 2022


This revision was not accepted when it landed; it landed in state "Needs Review".
This revision was automatically updated to reflect the committed changes.
Closed by commit rGef72739eac18: [Bazel] Don't fail the build on usage of deprecated APIs (authored by GMNGeoffrey).

Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D118671/new/

https://reviews.llvm.org/D118671

Files:
  utils/bazel/.bazelrc


Index: utils/bazel/.bazelrc
===================================================================
--- utils/bazel/.bazelrc
+++ utils/bazel/.bazelrc
@@ -34,14 +34,16 @@
 # C++14 standard version is required.
 build:generic_clang --cxxopt=-std=c++14 --host_cxxopt=-std=c++14
 
+# Use `-Wall` and `-Werror` for Clang.
+build:generic_clang --copt=-Wall --copt=-Werror --host_copt=-Wall --host_copt=-Werror
+
 # The Clang available on MacOS has a warning that isn't clean on MLIR code. The
 # warning doesn't show up with more recent Clangs, so just disable for now.
 build:generic_clang --cxxopt=-Wno-range-loop-analysis --host_cxxopt=-Wno-range-loop-analysis
 
-# Use `-Wall` and `-Werror` for Clang.
-build:generic_clang --copt=-Wall --copt=-Werror --host_copt=-Wall --host_copt=-Werror
-# This doesn't appear to be enforced by any upstream bot.
-build:generic_clang --copt=-Wno-unused --host_copt=-Wno-unused
+# Build errors are not a helpful way to enforce deprecation in-repo and it is
+# not the point of the Bazel build to catch usage of deprecated APIs.
+build:generic_clang --copt=-Wno-deprecated --host_copt=-Wno-deprecated
 
 ###############################################################################
 # Options for "generic_gcc" builds: these options should generally apply to
@@ -57,6 +59,10 @@
 # C++14 standard version is required.
 build:generic_gcc --cxxopt=-std=c++14 --host_cxxopt=-std=c++14
 
+# Build errors are not a helpful way to enforce deprecation in-repo and it is
+# not the point of the Bazel build to catch usage of deprecated APIs.
+build:generic_gcc --copt=-Wno-deprecated --host_copt=-Wno-deprecated
+
 # Disable GCC warnings that are noisy and/or false positives on LLVM code.
 # These need to be global as some code triggering these is in header files.
 build:generic_gcc --copt=-Wno-unused-parameter --host_copt=-Wno-unused-parameter


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D118671.404777.patch
Type: text/x-patch
Size: 1869 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220201/edadc2b7/attachment.bin>


More information about the llvm-commits mailing list