Boost logo

Boost-Build :

From: Vladimir Prus (ghost_at_[hidden])
Date: 2006-04-26 04:55:05


On Wednesday 12 April 2006 18:18, Arjan Knepper wrote:
> Vladimir Prus wrote:
> > On Wednesday 12 April 2006 16:44, Arjan Knepper wrote:
> >> I need to add the -WD flag when compiling sources for a DLL and the -WA
> >> when compiling sources for a static LIB. How do I achieve that?
> >
> > Hi Arjan,
> > something like:
> >
> > flags dmc.compile OPTIONS <link>shared : -WD ;
> > flags dmc.compile OPTIONS <link>static : -WA ;
>
> When using the above flags I see the -WD flag on building an executable
> which is linked against shared libs.
> The -WD flag should be used ONLY when building an actual shared lib (DLL).
> The -WA flag should be used when building EXE or building a static LIB.
>
> Is that possible or did I misunderstood the suggestion?

Ah, I misunderstood the issue. Try this:

   LINK_TYPE = -WA ;
   flags dmc.compile OPTIONS <link>shared/<main-target-type>LIB : -WD ;

And then add $(LINK_TYPE) to compiler command.

- Volodya

-- 
Vladimir Prus
http://vladimir_prus.blogspot.com
Boost.Build V2: http://boost.org/boost-build2

Boost-Build 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