From: Pedro Ferreira (pedro.ferreira_at_[hidden])
Date: 2005-03-08 06:45:31
On 5 Mar 2005, at 08:29, Vladimir Prus wrote:
> 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
> action name is nice, so I've created BjamActionWrapper class which is
> callable and which __name__ attribute is equal to the action name (see
> action.py file). And since it's callable, I've modified the __call__
> to call bjam and set up the actions.
> What I'm driving at is that if action is callable, then we don't need
> 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
> 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.
I committed a change to the way rules and actions are handled: they are
registered in the action module and then are identified by a id in the
format toolset.rule, just as in BBv2.
I didn't adjust the code you wrote because I haven't managed to get it
running (yet, I'm setting it up on a Linux machine right now), so I'd
appreciate if you take a look at it.
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