Boost logo

Boost-Build :

Subject: Re: [Boost-build] turning off -DNDEBUG in release mode
From: Amos Anderson (nitroamos_at_[hidden])
Date: 2010-04-13 14:39:24

On Tue, Apr 13, 2010 at 1:56 AM, Juraj Ivančić <juraj.ivancic_at_[hidden]> wrote:
> On 13.4.2010 0:34, Amos Anderson wrote:
>> hello -- i'm trying to enable asserts in release mode. based on the
>> manual, it looks like this should do the trick:
> The only way I found to do this is to define a new build variant:
> variant release-assert
> :
>    <optimization>speed
>    <debug-symbols>on
>    <inlining>full
>    <runtime-debugging>off
> ;
> This is actually definition of release variant with omitted
> <define>NDEBUG.
> I would much rather define it by e.g. extending 'release' variant and
> removing <define>NDEBUG from it, but it is currently impossible - when
> extending a variant you can AFAICT only add features, not remove them.

Good enough, thanks.
I'd imagine this is a common question because a typical policy is to
always keep cheap asserts active.

Could somebody add it to the FAQ?


Boost-Build list run by bdawes at, david.abrahams at, gregod at, cpdaniel at, john at