Reputation: 13350
This should be ridiculously simple.
I found the man page here: http://www.scons.org/doc/HTML/scons-man.html
Directly from it it says:
--warn=all, --warn=no-all // Enables or disables all warnings.
So I type:
scons --warn=no-all
And I still get a million warnings when building. I must be screwing up something ridiculously simple =\
I get a couple hundred of these before my terminal runs out of history:
warning: deprecated conversion from string constant to 'char*'
edit: FOUND THE PROBLEM!! It's a C/C++ project so the code I needed was:
env.Append(CCFLAGS=["-Wno-write-strings"])
what I had:
env.Append(CFLAGS=["-Wno-write-strings"])
Upvotes: 3
Views: 3614
Reputation: 994639
The warnings you are getting are coming from your compiler, not from Scons itself. Scons itself doesn't have very many warnings. The --warn=
switch only applies to Scons.
What you need to do is pass the appropriate compiler flag to your compiler to turn off the warning you don't want. You can do this using the CCFLAGS
environment value:
env.Append(CCFLAGS=["-Wno-write-strings"])
CCFLAGS
applies the line to both C and C++ targets.
The above flag is for Gcc.
Upvotes: 10