summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--solenv/gbuild/Output.mk7
1 files changed, 7 insertions, 0 deletions
diff --git a/solenv/gbuild/Output.mk b/solenv/gbuild/Output.mk
index ca3da3b7c5be..b9f8515200e4 100644
--- a/solenv/gbuild/Output.mk
+++ b/solenv/gbuild/Output.mk
@@ -48,6 +48,13 @@ endef
gb_Output_ESCAPE := $(shell echo|awk 'BEGIN { printf "%c", 27 }' -)
gb_Output_BELL := $(shell echo|awk 'BEGIN { printf "%c", 7 }' -)
+# default to color output, if interactive
+ifeq ($(origin gb_COLOR),undefined)
+ifneq ($(MAKE_TERMOUT),)
+gb_COLOR=$(true)
+endif
+endif
+
# only enable colorized output if
# - gb_COLOR is set
# - we have a known term