From: "K. Richard Pixley" <rich.pixley@palm.com>
To: "openembedded-devel@openembedded.org"
<openembedded-devel@openembedded.org>
Subject: Re: getVar. setVar, "d", etc.
Date: Wed, 06 Feb 2008 10:54:46 -0800 [thread overview]
Message-ID: <47AA0276.6020100@palm.com> (raw)
In-Reply-To: <1202300290.8393.6.camel@dax.rpnet.com>
Richard Purdie wrote:
> Once again I should remind people that := is usually a bad idea (see
> recent discussions).
That's counterintuitive and backwards from other build systems. I've
often pulled significant savings out of makefile based systems by
switching from = to :=. The problem being that "x = ${@
a_long_running_function() }" is a killer, especially when
a_long_running_function is deterministic. In that case, := requires
exactly one call during assignment while = requires a fresh call for
each and every reference. The only down side of := assignments is that
one needs to be savvy about sequencing assignments. Luckily, with
conditionals, any sequence of assignments can be expressed.
I used := in this situation specifically because of the sequence
ordering. The assignments in my example are dummies whose sole purpose
is to force the side effects to happen at a predictable and early point
in the run - specifically, before the assignment to SRC_URI. If I don't
force the side effects to happen at := time, then there's no reason to
believe that they will have occurred prior to the expansion of ${PR} in
${SRC_URI}. (And, in fact, changing this doesn't affect my results).
I have discovered that converting the constructions into "python
setting() {" seem to give them consistent contexts. I don't understand
why ${@ ... } lacks that context, but at least I have a way to proceed.
Event handlers also seem to have consistent context so if I can reverse
engineer what events actually exist, or force one to occur at the right
time, then I should be able to get my assignments done early enough.
Neither these differences nor event handlers are very well described in
the manual, btw.
Thanks for your help. I think I'm over my hump now. "python setting()"
and event handlers should get me where I want to go now.
--rich
next prev parent reply other threads:[~2008-02-06 18:54 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-02-04 22:05 getVar. setVar, "d", etc Rich Pixley
2008-02-04 23:05 ` Richard Purdie
2008-02-05 1:35 ` Rich Pixley
2008-02-05 2:37 ` Rich Pixley
2008-02-05 22:03 ` Richard Purdie
2008-02-05 23:13 ` Rich Pixley
2008-02-06 2:29 ` Rich Pixley
2008-02-06 12:18 ` Richard Purdie
2008-02-06 18:54 ` K. Richard Pixley [this message]
2008-02-07 0:54 ` Richard Purdie
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=47AA0276.6020100@palm.com \
--to=rich.pixley@palm.com \
--cc=openembedded-devel@lists.openembedded.org \
--cc=openembedded-devel@openembedded.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.