Boost logo

Boost-Build :

From: Vladimir Prus (ghost_at_[hidden])
Date: 2006-02-10 09:24:02


On Tuesday 07 February 2006 20:48, Renaud Lepere wrote:
> > On Tuesday 24 January 2006 18:59, Renaud Lepere wrote:
> > > > > In makefile world, svnrev can be used using a line
> > > > > svnrev.h : main.cpp gui.cpp gui.h storage.cpp storage.h
> > > > > svnrev $?
> > > > > How can i do something similar in bbv2 ?
>
> ...
>
> > Try <implicit-dependency> as documented at:
> >
> > http://boost.org/boost-build2/doc/html/bbv2/reference/jamfiles
>
> I still have a small problem with 2 directory
>
> - first one project1 with the given jamfile
> make svnrev.h : project1.cpp : svnrev ;
> actions svnrev
> {
> svnrev -o$(<) $(>)
> }
> lib project1 : project1.cpp svnrev.h : <implicit-dependency>svnrev.h ;
>
> - second one with the given jamfile
> exe main : main.cpp ../project1//project1 ;
>
> If i call bjam -a in the second directory, the svnrev action is not
> done ? How can i add a true dependancy between building the lib
> and rebuilding the snvrev.h file ?

You can use <dependency>svnrev
But maybe you can try the attached patch? It fixes a problem with the
<implicit-dependency> feature, and if your main.cpp includes svnrev.h, then
with this patch svnrev.h should be rebuilt as needed.

Let me know if this works out.

- Volodya

- Volodya




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