Re: Dealing with build attributes of targets
Bram Moolenaar <[email protected]>
| Newsgroups | gmane.comp.tools.aap.devel |
|---|---|
| Message-ID | <[email protected]> |
Adriaan de Groot wrote:
> On Thursday 23 October 2003 14:54, you wrote:
> > Adriaan de Groot wrote:
> > > :ltlib { attributes for ltlib, like installvar } target { attributes for
> > > : the
> > > target, like installdir } : { attributes XXX } sources { attributes for
> > > each source individually }
> >
> > I agree that the attributes that come right after the ":" should apply
> > to all the sources that come after it. It's logical.
>
> Yay. It _is_, however, a nasty change if there's 3rd parties using AAP and
> relying on the current behavior.
I wonder if this would really be a problem for someone. I would not
expect attributes after the ":" that would mess up something when it's
added to the sources.
> > I think we should check that this is consistent with other commands, and
> > also for dependencies. (problem with dependencies is that you can't put
> > an attribute at the start: "{attr} target : source", thus it uses
> > "target : {attr} source")
>
> Well, there's also target { attr } : source available, which makes the most
> sense to me for attaching attr to target. If an attr is first in a list of
> things, it applies to all of them. Otherwise, it applies to the thing just
> before it.
I would think it's right. ":attr" also does the same thing now.
> > Besides the missing documentation there is another problem: The
>
> <hunchback>Yesss, masster. I will go fetcchh the braaaiins now.</hunckback>
They don't call me "Vim master" for nothing! :-)
> > attributes should apply to the sources for this build command, but when
> > the source is also used elswhere, the attribute do not necessarily
> > apply. Thus adding the attributes to the node is not a good idea.
> > The attributes should be passed to add_buildrule() and added to the
> > generated dependencies there.
>
> OK. That is more advanced AAP hackery than I can muster quickly, I think.
> Perhaps you can give it a nudge?
It's just a matter of copying the attributes from the dictionary of
attributes to each entry in the list of sources. Don't think there is
any more to it. This can be done in add_buildrule() or in
aap_program(). Not sure where it fits best.
--
MORTICIAN: What?
CUSTOMER: Nothing -- here's your nine pence.
DEAD PERSON: I'm not dead!
MORTICIAN: Here -- he says he's not dead!
CUSTOMER: Yes, he is.
DEAD PERSON: I'm not!
The Quest for the Holy Grail (Monty Python)
/// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net \\\
/// Creator of Vim - Vi IMproved -- http://www.Vim.org \\\
\\\ Project leader for A-A-P -- http://www.A-A-P.org ///
\\\ Help AIDS victims, buy here: http://ICCF-Holland.org/click1.html ///
-------------------------------------------------------
This SF.net email is sponsored by: The SF.net Donation Program.
Do you like what SourceForge.net is doing for the Open
Source Community? Make a contribution, and help us add new
features and functionality. Click here: http://sourceforge.net/donate/