[cfe-commits] r153854 - /cfe/trunk/lib/Driver/Tools.cpp

Bob Wilson bob.wilson at apple.com
Sun Apr 1 16:03:30 PDT 2012


Author: bwilson
Date: Sun Apr  1 18:03:29 2012
New Revision: 153854

URL: http://llvm.org/viewvc/llvm-project?rev=153854&view=rev
Log:
Ignore unused --serialize-diagnostics option when using llvm-gcc.

llvm-gcc doesn't handle --serialize-diagnostics so when compiling i386
kernel/kext code with -Werror, you get an error about that option being
unused.  Claim the argument to prevent this from breaking builds.
<rdar://problem/11161933>

Modified:
    cfe/trunk/lib/Driver/Tools.cpp

Modified: cfe/trunk/lib/Driver/Tools.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Driver/Tools.cpp?rev=153854&r1=153853&r2=153854&view=diff
==============================================================================
--- cfe/trunk/lib/Driver/Tools.cpp (original)
+++ cfe/trunk/lib/Driver/Tools.cpp Sun Apr  1 18:03:29 2012
@@ -3619,6 +3619,9 @@
 
   assert(Inputs.size() == 1 && "Unexpected number of inputs!");
 
+  // Silence warning about unused --serialize-diagnostics
+  Args.ClaimAllArgs(options::OPT__serialize_diags);
+
   types::ID InputType = Inputs[0].getType();
   const Arg *A;
   if ((A = Args.getLastArg(options::OPT_traditional)))





More information about the cfe-commits mailing list