Boost logo

Boost-Build :

From: Vladimir Prus (ghost_at_[hidden])
Date: 2003-01-23 05:33:02


Jürgen Hunold wrote:
> Hi !
>
> First of all, I want to thank Vladimir for the great work.
> I've tried the qt-toolset on some small project and it works fine.
>
> Vladimir, the description for external Libraries was very helpful.
> I was able to link against external libraries succesfully. All that
> prevents me from *really' using bjam is the following bug:

[...]

Jürgen,

first off, thanks for providing such a good bug report. I'll respond in
as much detail as I can, but note that the last paragraph of this email
are enough to solve the issue.

The problem can be explained by the following output from
bjam --v2 --debug-generators

*** construct LIB
from { test_a.CPP }
from { ../include/test_a.H }
properties: [snip]

# here we're trying to build liba/liba

Later on:
*** construct OBJ (may return multiple targets)
from { ../include/test_a.H }
properties: [snip]
[snip]
FAILURE

The build system was unable to convert "H" source to anything. The reason
is simple: moccing is allowed *only* if you have <uses>qt in properties and
there's no that property when creating liba/liba.

This can be easily fixed: Just add <uses>qt to "requirements" section of
top-level Jamfile.

But how comes that property is not there? While main/test_a inherits
the "default-build" property and uses it for constructing itself,
it removes "<uses>qt" when building "../liba/liba". The reason is that
"<uses>" is a free feature (like <include> and <cxxflags>). Boost.Build
has no idea if targets with different free properties are different or not.
Assume that a version with different free property already exists. Should it
be used? Or should we build a brand new version? Because there's no good
answer, free features are not propagated (see the manual for details).

If you specify free properties on the command line, they *will* be applied
to all the targets in Jamfile at "." and all projects references via
"build-project".

I also think that "default-build" should have the same effect as if the
properties are specified on the command line. It means, that adding
"build-project liba ;" should work. It does not, and that's a bug.

But note that if your application uses qt, then <uses>qt should be in
properties *always*, which means that you should add it to requirements
of top-level project. Otherwise, somebody will run "bjam debug" and will
be very surprised.
I've added comments to existing issue BB10 and will write another email about it.

- 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