SCons

How to fix SCons error: Do not know how to make File target `clean’

Problem:

You are trying to clean your SCons build using

scons clean

but you see the following error message:

scons: Reading SConscript files ...
scons: done reading SConscript files.
scons: Building targets ...
scons: *** Do not know how to make File target `clean' (/home/user/myproject/clean).  Stop.
scons: building terminated because of errors.

Solution:

When using SCons, the correct command to clean is

scons --clean

 

Posted by Uli Köhler in Build systems, SCons

How to fix SCons not providing colored GCC/C++ output

You can force SCons to provide colored output when using GCC or G++ by adding

-fdiagnostics-color=always

to your CFLAGS or CXXFLAGS. Typically, my recommendation is to add it to both CFLAGS and CXXFLAGS.

Posted by Uli Köhler in Build systems, SCons