Boost logo

Boost-Build :

From: Kostas Kostiadis (kos_at_[hidden])
Date: 2006-05-31 09:46:32


Hello all,

I have a project, which involves a bunch of libs.
I want to keep the sources separate from the output.
The "build-dir" rule helps to an extend, but it doesn't do exactly what I
want.

Here's an example that should make things easier to understand...
Assume my project is structured as follows:

Root:
   - libs
   --- math

   - projects
   --- helloWorld

After I build helloWorld (which depends on math), I'd like the following to
happen:

1) /libs should stay exactly as it was...(i.e. there should be no object or
.lib/.a files in there)

2) Everything but the final executable should go in
/output/projects/helloWorld

i.e. there should be

/output/projects/helloWorld/libs/math/someMathFile.o
/output/projects/helloWorld/libs/math/someOtherMathFile.o
/output/projects/helloWorld/libs/math/math.a ( <<< the actual lib )
/output/projects/helloWorld/someHelloWorldFile.o
Etc.

3) The final executable (i.e. helloWorld) should go in
/projects/helloWorld/output/
(This is the only file that lives outside of the top level /output).

4) I'd like to remove all the /gcc/link-static/ etc that gets appended to
the path.
All I'm interested in is appedning to the _filename_ some info...e.g.
helloWorld_debug or helloWorld_release_static.
The important thing is that the executables all go to the same output
location, since this is where the data lives that helloWorld needs.
(There is a separate data build process that makes all the data and copies
it in the right place).

In the end, /projects/helloWorld/output would have all you need to run
helloWorld...i.e. it might look something like:

/projects/helloWorld/output/helloWorld_debug
/projects/helloWorld/output/helloWorld_release
/projects/helloWorld/output/TexturesFolder/
/projects/helloWorld/output/AudioFolder/
Etc.

Hope that makes sense...The question is, what jam files do I need to modify
and what rules, to get the desired effects?
I've started building with -d9 to see what actually happens, and there is a
lot of stuff to do with path.jam and virtual-target.jam, etc. but there is a
LOT of stuff in there...I was hoping someone could point me to the right
direction and narrow things down a bit.

Cheers,
Kos.


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