Boost logo

Boost-Build :

From: Vladimir Prus (ghost_at_[hidden])
Date: 2005-06-03 00:53:05


On Thursday 02 June 2005 19:25, Phillip Seaver wrote:
> Vladimir Prus wrote:
> > This commit has one user-visible change. The code:
> >
> > exe a : a.cpp b ;
> > obj b : b.cpp helper;
> > lib helper ;
> >
> > No longer works -- the 'a' target won't link to 'helper'. However, this
> > is pretty stange code and worked before almost by accident.
>
> I'm using m10, and I've got something similar. Mine is more like this,
> though:
>
> lib helper ;
> obj b : b.cpp <use>helper ;

Did you mean:

obj b : b.cpp : <use>helper ;

(note extra ':'). That use case should not be affected at all.

> On a side note, I've got a prebuilt library that requires a library that
> I build, so I do something like this:
>
> lib prebuilt : : <file>prebuilt_d.a <variant>debug <threading>single
> <use>a ;
> lib a : a.cpp ;
> exe b : b.cpp prebuilt ;
>
> IIRC, it builds 'a' when necessary. The problem is that it doesn't put
> 'a' after 'prebuilt' on the link line, so I get link errors (on Unix).
> I worked around it by adding "<library-file>a" to the exe definition.

I think

lib prebuilt : a : <file>prebuilt_d.a <variant>debug <threading>single
<use>a ;

should work. At least 'unix-prebuilt-lib-generator' in unix.jam sets
dependency from what's mentioned in <file> to sources.

- 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