Make diagnostics colored when compiling gn.
Ninja makes all subprocesses talk to a pipe, so clang and gcc suppress
their colored diagnostics. Explicitly opt-in. (Ninja will strip the
color codes when it itself discovers it's writing to a pipe.)
Change-Id: I842f3be9731f9d987e9dd8c38ba5e3348211ec5e
Reviewed-on: https://gn-review.googlesource.com/2700
Reviewed-by: Brett Wilson <brettw@chromium.org>
Commit-Queue: Brett Wilson <brettw@chromium.org>
diff --git a/build/gen.py b/build/gen.py
index 76f88e8..11c9246 100755
--- a/build/gen.py
+++ b/build/gen.py
@@ -359,6 +359,7 @@
'-pipe',
'-fno-exceptions',
'-fno-rtti',
+ '-fdiagnostics-color',
])
cflags_cc.extend(['-std=c++14', '-Wno-c++11-narrowing'])