Boost logo

Boost-Build :

From: timgift (timgift_at_[hidden])
Date: 2005-08-03 16:23:59


Overriding the location-prefix on the library works great for some of
the libraries, Thanks :) Still don't quite have a feeling for how the
system ties together... Another related question, dealing with more
sub-directories:

I have something like this:
+-root
--+-util
----|-a.cc
----+-sub1
------|-a.cc

So, the following doesn't work:

lib util : util/a.cc util/sub1/a.cc : <location-prefix>util ;

I tried an alias, but the location prefix feature seems to be bound to
the target, and not the source files. So this doesn't work either:

alias sub1 : util/sub1/a.cc : <location-prefix>util/sub2 ;
lib util : util/a.cc sub1 : <location-prefix>util ;

What does work is this:

lib sub1 : util/sub1/a.cc : <location-prefix>util/sub1 ;
lib util : util/a.cc sub1 : <location-prefix>util ;

but then I end up with two libraries. I've seen references to binding
locations to obj targets, but then I'd need a declaration for each
object in sub1, which I'd like to avoid.

Is there a way to combine libraries? or another way to bind
location-prefix values to source files?

Thanks for helping out!

Tim

--- In jamboost_at_[hidden], Vladimir Prus <ghost_at_c...> wrote:
> On Wednesday 03 August 2005 05:06, timgift wrote:
>
> > A possible solution is to allow multiple projects in a Jamfile, but so
> > far that doesn't seem possible... does anybody know if this is
> > possible? I'd basically like to have a single Jamefile something like
> > this:
> >
> > project util : source-location util ;
> > lib util : a.cpp b.cpp ;
> >
> > project kernel : source-location kernel ;
> > lib kernel : a.cpp b.cpp c.cpp ;
> >
> > project tool : source-location tool ;
> > exe tool : tool.cpp /util//util /kernel//kernel ;
>
> No, it's not possible, but you can use this:
>
> lib util : util/a.cpp util/b.cpp : <location-prefix>util ;
> lib kernel : kernel/a.cpp kernel/b.cpp : <location-prefix>kernel ;
>
> This should resolve your problems with identically named files.
>
> HTH,
> 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