Enable colored warnings in ninja's output

Authored by elvisangelaccio on Dec 29 2016, 11:18 AM.

Description

Enable colored warnings in ninja's output

Summary:
Colored compiler warnings in ninja output only work with the
-fdiagnostics-color=always flag.
See https://github.com/ninja-build/ninja/issues/814 for a rationale.

This commit adds such flag in ecm for gcc >= 4.9 and clang >= 3.5,
and only if the CMAKE_GENERATOR is Ninja.

Test Plan: ninja+gcc and ninja+clang now show nice colored compiler warnings.

Reviewers: Frameworks

Differential Revision: https://phabricator.kde.org/D3733

Details

Committed
elvisangelaccioDec 29 2016, 11:18 AM
Differential Revision
D3733: Force colored warnings in ninja's output
Parents
R240:c0a047a20591: Revert "Add Clang Sanitizer CMAKE_C_FLAGS for C project"
Branches
Unknown
Tags
Unknown