From 2811adc0924b0227a0795eb3325eeaf33fde4130 Mon Sep 17 00:00:00 2001 From: Hauke Petersen Date: Mon, 10 Jul 2017 16:31:41 +0200 Subject: [PATCH] cflags: add -fdiagnostics-color if supported --- makefiles/cflags.inc.mk | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/makefiles/cflags.inc.mk b/makefiles/cflags.inc.mk index b4a0df368c..c5e3c52e8b 100644 --- a/makefiles/cflags.inc.mk +++ b/makefiles/cflags.inc.mk @@ -25,6 +25,11 @@ ifeq ($(shell $(CC) -fno-delete-null-pointer-checks -E - 2>/dev/null >/dev/null endif endif +# Use colored gcc output if the compiler supports this +ifeq ($(shell $(CC) -fdiagnostics-color -E - 2>/dev/null >/dev/null