diff options
author | Christoph Reiter <reiter.christoph@gmail.com> | 2018-04-12 09:28:20 +0200 |
---|---|---|
committer | Christoph Reiter <reiter.christoph@gmail.com> | 2018-04-12 16:28:35 +0200 |
commit | 773bb9de8cfc6dbcce88854e9cc35fc37ed1072e (patch) | |
tree | f52ade5c9a373f43ff3e3f1ad708cc44adda0d78 /setup.py | |
parent | b77f9fb8be61698814000aefff3c1f29609bf6c8 (diff) | |
download | pygobject-773bb9de8cfc6dbcce88854e9cc35fc37ed1072e.tar.gz |
setup.py: force GCC to use colors in case of stdout.isatty()
Diffstat (limited to 'setup.py')
-rwxr-xr-x | setup.py | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -929,6 +929,10 @@ def add_ext_compiler_flags(ext, compiler, _cache={}): "-fvisibility=hidden", ] + # force GCC to use colors + if hasattr(sys.stdout, "isatty") and sys.stdout.isatty(): + args.append("-fdiagnostics-color") + _cache[cache_key] = filter_compiler_arguments(compiler, args) ext.extra_compile_args += _cache[cache_key] |