Boost logo

Boost Users :

From: David Abrahams (dave_at_[hidden])
Date: 2007-05-16 12:52:44


on Wed May 16 2007, Yuval Ronen <ronen_yuval-AT-yahoo.com> wrote:

> Yuval Ronen wrote:
>> Vladimir Prus wrote:
>>> Yuval Ronen wrote:
>>>
>>>> Can I pass a command line argument of some sort to tell Boost.Build V2
>>>> to disable some specific MSVC warnings?
>>> bjam cxxflags=<whatever-MSVC-option-you-want>
>>>
>>> should work.
>>
>> It doesn't. I tried
>>
>> bjam --toolset=msvc-8.0 cxxflags=/wd4251
>>
>> but bjam spits errors about invalid arguments

What are the *exact* error messages?

>> and aborts without building anything. So I tried
>>
>> bjam --toolset=msvc-8.0 --cxxflags=/wd4251
>>
>> and it was better, but not good enough.

No, --cxxflags is not a valid option. Only cxxflags=... will have
anything remotely like the right effect. The other one will be ignored.

>> It did compile this time, only
>> warning 4251 was still not disabled. So I tried
>>
>> bjam -d+2 --toolset=msvc-8.0 --cxxflags=/wd4251
>>
>> to show the actual command executed (as suggested by bjam --help) but I
>> couldn't figure anything from it. It seems 'cl' is passed some .rsp
>> files, instead of .cpp file (as I expected). The command line didn't
>> include '/wd4251', but maybe it's because the usage of the .rsp file
>> (which I have no idea what it is).

Yeah, so look at the commands that build the .rsp file.

-- 
Dave Abrahams
Boost Consulting
http://www.boost-consulting.com
Don't Miss BoostCon 2007! ==> http://www.boostcon.com

Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net