From: "Richard Purdie" <richard.purdie@linuxfoundation.org>
To: Trevor Woerner <twoerner@gmail.com>,
Nicolas Dechesne <nicolas.dechesne@linaro.org>
Cc: Yocto list discussion <yocto@yoctoproject.org>
Subject: Re: [yocto] variable and task/function timing
Date: Wed, 11 Dec 2019 15:48:51 +0000 [thread overview]
Message-ID: <a9e3cc548a4794e2497f350f53a7a915ee71fc2d.camel@linuxfoundation.org> (raw)
In-Reply-To: <20191211153955.GA5676@linux-uys3>
On Wed, 2019-12-11 at 10:39 -0500, Trevor Woerner wrote:
> On Wed 2019-12-11 @ 11:06:44 AM, Nicolas Dechesne wrote:
> > > +python do_check_build_type() {
> > > + _buildtype = d.getVar('MESA_BUILD_TYPE')
> > > + if _buildtype not in ['release', 'debug']:
> > > + bb.fatal("unknown build type (%s), please set to
> > > either 'release' or 'debug'" % _buildtype)
> > > + if _buildtype == 'debug':
> > > + d.setVar('MESON_BUILDTYPE', 'debugoptimized')
> > > + bb.plain("setting meson build type to
> > > debugoptimized")
> > > +}
> > > +addtask check_build_type before do_configure
> > > +
> > > EXTRA_OEMESON = " \
> > > -Dshared-glapi=true \
> > > -Dgallium-opencl=disabled \
>
> Whether I move the above to before or after the "inherit meson..."
> line makes no difference. Probably because the variable is being set
> by a task (which, I assume, is too late to have any effect, which is
> a large part of why I wrote this email: when do these tasks get
> called with respect to how variable are being set by all the
> different ways they're being set?)
Tasks run in isolation, if you change the datastore in a task it has no
way to get "seen" by other tasks. They're separate processes.
That is why the setVar in a task has no effect outside that task.
Cheers,
Richard
next prev parent reply other threads:[~2019-12-11 15:48 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-12-11 7:18 variable and task/function timing Trevor Woerner
2019-12-11 10:06 ` [yocto] " Nicolas Dechesne
2019-12-11 15:39 ` Trevor Woerner
2019-12-11 15:48 ` Richard Purdie [this message]
2019-12-11 15:51 ` Nicolas Dechesne
2019-12-11 16:26 ` Trevor Woerner
2019-12-11 15:49 ` Nicolas Dechesne
2019-12-11 16:41 ` Trevor Woerner
2019-12-11 17:37 ` Nicolas Dechesne
2019-12-19 16:16 ` Joel A Cohen
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=a9e3cc548a4794e2497f350f53a7a915ee71fc2d.camel@linuxfoundation.org \
--to=richard.purdie@linuxfoundation.org \
--cc=nicolas.dechesne@linaro.org \
--cc=twoerner@gmail.com \
--cc=yocto@yoctoproject.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox