Issue
Is there a way how to produce a colorful output from gcc
which is called from Makefile generated by cmake
? It would make debugging application a lot easier.
Solution
Do you want colourful output from cmake
binary? For that I don't know any solution.
CMake
can generate Makefiles
that provide verbose (and colourful) information about the build process. This can be enabled in the following way:
SET(CMAKE_COLOR_MAKEFILE ON)
# And optionally
SET(CMAKE_VERBOSE_MAKEFILE ON)
If you want to have the gcc
output colourised, then have a look at colorgcc
perl script. Having it installed try something like this:
CC=/usr/bin/colorgcc cmake .....
Or use the newer solution proposed in another answer by gfour - the gccfilter
Answered By - Anonymous Answer Checked By - Timothy Miller (WPSolving Admin)