Boost logo

Boost-Build :

From: Vladimir Prus (ghost_at_[hidden])
Date: 2005-03-05 03:29:37

Hi Pedro,

> > but "import bjam" means the module is only usable with bjam. Which
> > gives two
> > questions:
> >
> > 1. I've added Jamfile loading to the ProjectRegistry code. Do you find
> > it
> > desirable to split the logic into a separate module, so that
> > can
> > be used without bjam? This should be easy -- just moving one class from
> > to another module, but maybe I worry too much?
> If it isn't asking too much, I'd rather have it separate, please: I'd
> really like to be able to create projects just using python.

No problem, done. I have committed by modifications. Please update and take a
look at python/README.txt for instructions. Note that I've tested on Linux,
and more work is needed to enable bjam's Python support on Windows.

I'd appreciate if you try the changes.

> > 2. Another issue is the BjamBuildSystem. Currently it generates the
> > string
> > that is to be executed by bjam. I think now it's time to make it do
> > real
> > calls to bjam. Is that OK with you? In my current version, calls to
> > bjam are
> > done via some kluge.
> Sure. Just go ahead. I'm really looking forward to see it!

I think we need some discussion here. Now the action name stored in the Action
- must be callable
- must provide __name__ attribute which is then passed to build engine

For the make rule, the action is specified in Jamfile, and the above is not
very convenient. I don't think defining a function with the same name as
action name is nice, so I've created BjamActionWrapper class which is
callable and which __name__ attribute is equal to the action name (see the file). And since it's callable, I've modified the __call__ method
to call bjam and set up the actions.

What I'm driving at is that if action is callable, then we don't need do
handle the name, the call can do anything. If we use only the name, then why
require that action is callable? Say the __call__ method can both set up
target variables and then call bjam. What would be the role of
BjamBuildSystem is not clear. Maybe it should be just a factory for
appropriate actions? I really don't know the right approach yet.

> Lately I haven't had time to work consistently on the port but, slowly,
> it's getting there: there already is minimal support for gcc and am
> working on darwin right now.

Actually, you're now hacking on Boost.Build more actively than I ;-) Gcc
support is very good, I hope to try it soon, after making the "exe" available
in Jamfiles.

- Volodya


Boost-Build list run by bdawes at, david.abrahams at, gregod at, cpdaniel at, john at