From f9a4e6890bf5b21ae39c12f920e11005b07df9aa Mon Sep 17 00:00:00 2001 From: hurikhan Date: Mon, 12 Jan 2015 12:54:17 +0800 Subject: SCons: colored compilation --- platform/server/detect.py | 3 +++ platform/x11/detect.py | 3 +++ 2 files changed, 6 insertions(+) (limited to 'platform') diff --git a/platform/server/detect.py b/platform/server/detect.py index 24b36d3188..e2d64c6545 100644 --- a/platform/server/detect.py +++ b/platform/server/detect.py @@ -40,6 +40,9 @@ def configure(env): env["CC"]="clang" env["CXX"]="clang++" env["LD"]="clang++" + if (env["colored"]=="yes"): + if sys.stdout.isatty(): + env.Append(CXXFLAGS=["-fcolor-diagnostics"]) is64=sys.maxsize > 2**32 diff --git a/platform/x11/detect.py b/platform/x11/detect.py index 621a0c66a0..2b38099a74 100644 --- a/platform/x11/detect.py +++ b/platform/x11/detect.py @@ -81,6 +81,9 @@ def configure(env): env.extra_suffix=".llvms" else: env.extra_suffix=".llvm" + if (env["colored"]=="yes"): + if sys.stdout.isatty(): + env.Append(CXXFLAGS=["-fcolor-diagnostics"]) -- cgit v1.2.3 From 067a0d0e640e5c478715b55cd2f6fec39bf21326 Mon Sep 17 00:00:00 2001 From: hurikhan Date: Mon, 12 Jan 2015 14:04:25 +0800 Subject: osx support for llvm coloring added --- platform/osx/detect.py | 3 +++ 1 file changed, 3 insertions(+) (limited to 'platform') diff --git a/platform/osx/detect.py b/platform/osx/detect.py index 141a876657..08784be810 100644 --- a/platform/osx/detect.py +++ b/platform/osx/detect.py @@ -84,6 +84,9 @@ def configure(env): env.Append(CPPFLAGS=['-DTYPED_METHOD_BIND']) env["CC"]="clang" env["LD"]="clang++" + if (env["colored"]=="yes"): + if sys.stdout.isatty(): + env.Append(CXXFLAGS=["-fcolor-diagnostics"]) import methods -- cgit v1.2.3 From 928e068f71afed015bdf6851dad7d4f57f827ef6 Mon Sep 17 00:00:00 2001 From: hurikhan Date: Tue, 13 Jan 2015 12:54:23 +0800 Subject: -try fixing LLVM color diagnostic on osx --- platform/osx/detect.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'platform') diff --git a/platform/osx/detect.py b/platform/osx/detect.py index 08784be810..5703cbc546 100644 --- a/platform/osx/detect.py +++ b/platform/osx/detect.py @@ -86,7 +86,7 @@ def configure(env): env["LD"]="clang++" if (env["colored"]=="yes"): if sys.stdout.isatty(): - env.Append(CXXFLAGS=["-fcolor-diagnostics"]) + env.Append(CPPFLAGS=["-fcolor-diagnostics"]) import methods -- cgit v1.2.3