Boost logo

Boost Interest :

Subject: Re: [Boost-cmake] placement_new test failure under VC++8
From: David Wolfe (dwolfe_at_[hidden])
Date: 2009-05-17 23:41:20


>> I poked around in the BuildLog.htm files (for VS2005) and build.make
>> files (NMake) and convinced myself that CMake builds that use the NMake
>> generator are specifying /RTC1, while VS 2005 builds are not.

> Hmm.... are you building the Debug or the Release variant in VS 2005?
> Perhaps this flag is only provided with debug (which is probably the
> default for NMake Makefiles)?

It's slightly weirder than that. The test binaries are built in debug
mode by default when using the NMake generator, and the '/RTC1' flag is
definitely being passed to the compiler. When using the VS 2005
generator, if I select Debug mode in the IDE and build the placement_new
test, it runs fine, and the build log shows that '/RTC1' is *not* being
passed to the compiler.

So the situation is: in Debug mode, different compiler flags wind up
being specified depending on which generator I choose---even though the
underlying compiler is the same. It's a little bit surprising.

I noticed there's a symbol in CMakeCache.txt called 'DEBUG_COMPILE_FLAGS'
that's defined to: '/D_DEBUG /Zi /Ob0 /Od /RTC1'. If I remove '/RTC1'
from the end, then placement_new builds and runs fine with NMake. But
I'm not sure it's a good idea to monkey with that setting(?)

>>> IIRC, CTest has an internal
>>> timer and will kill a test after some number of seconds.
>>
>> That number appears to be 1500. `:-} I re-checked this and discovered
>> that the test does eventually time out after 25 minutes.

> Ah, good. It looks like this can be set via the CTEST_TEST_TIMEOUT
> variable. So, on could use -DCTEST_TEST_TIMEOUT=300 when configuring
> CMake to reduce the timeout time to 5 minutes.

Thanks for that tip---it'll definitely come in handy...


Boost-cmake list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk