I am using SCons in our python project to automate some steps. We do not use C/C++ in this project, and we do not have Visual C++, or any other C++ compilers installed in our build machine. However, SCons always gives a warning: scons: warning: No version of Visual Studio compiler found - C/C++ compilers most likely not set correctly File "D:\BuildAgent\work\dea9985b7c13c306\CCARModeling\SConstruct", line 14, in
We pinned it down to the line:
env = Environment(BUILDERS = {'RModels' : RBuilder}, ENV = os.environ)
There is no reason Scons should always look for a C++ compiler. Is there a way to suppress this particular warning?
You can use
env = Environment(tools=[])
to disable loading any default tools, and you may want to do the same for the DefaultEnvironment. Depending on which Builders/Tools you actually need, you can give the list instead, like this:
env = Environment(tools=['ar', 'textfile'])
See also the UserGuide at http://www.scons.org/doc/production/HTML/scons-user.html , especially 7.2.5 Controlling the Default Environment.