From: Richard Purdie <richard.purdie@linuxfoundation.org>
To: McClintock Matthew-B29882 <B29882@freescale.com>,
Patches and discussions about the oe-core layer
<openembedded-core@lists.openembedded.org>
Subject: Re: [PATCH] bitbake.conf/sstate.bbclass: Change PATH when installing sstate files to avoid issues
Date: Wed, 21 Mar 2012 21:12:49 +0000 [thread overview]
Message-ID: <1332364369.9740.185.camel@ted> (raw)
In-Reply-To: <CAEsOVNcy6kwQQ0oank6gO4yOSuUM6NNG0fYk752sQvYWy+9GDA@mail.gmail.com>
On Wed, 2012-03-21 at 17:54 +0000, McClintock Matthew-B29882 wrote:
> On Wed, Mar 21, 2012 at 5:44 AM, Richard Purdie
> <richard.purdie@linuxfoundation.org> wrote:
> > This resolves issues related to pigz-native when installing from sstate that people
> > have been seeing. It also gives us a way to solve issues like the gzip-native race
> > during sstate package creation covered in Yocto #1774.
> >
> > Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
> > ---
> > diff --git a/meta/classes/sstate.bbclass b/meta/classes/sstate.bbclass
> > index 0d16d11..1570654 100644
> > --- a/meta/classes/sstate.bbclass
> > +++ b/meta/classes/sstate.bbclass
> > @@ -153,6 +153,12 @@ def sstate_installpkg(ss, d):
> > bb.mkdirhier(dir)
> > oe.path.remove(dir)
> >
> > + # We're adding binaries into the sysroots, we don't want to execute them
> > + # whilst they're half installed or being installed so we need to
> > + # remove the sysroots from PATH
> > + savedpath = d.getVar("PATH")
> > + d.setVar("PATH", "${ORIGPATH}")
> > +
> > sstateinst = d.expand("${WORKDIR}/sstate-install-%s/" % ss['name'])
> > sstatepkg = d.getVar('SSTATE_PKG', True) + '_' + ss['name'] + ".tgz"
> >
> > @@ -190,6 +196,8 @@ def sstate_installpkg(ss, d):
> > # conflict with another writer
> > os.remove(fixmefn)
> >
> > + d.setVar("PATH", savedpath)
> > +
>
> So we always use the host tar and gzip here? Isn't there a reason we
> build tar-native explicitly? Could be fine if it's not needed for
> sstate-cache...
I had to hit the archives but:
http://git.yoctoproject.org/cgit.cgi/poky/commit/?id=577dd4b3e5d4861c31824d920fa170ba3a585f63
so yes, there is a good reason we might want to use our tar and I just
broken our old versions of tar workaround :(. We did check that tar code
for races and its relatively safe. The gzip situation is of course not
so safe and we have the open bugs to prove it :(.
So I should probably revert this patch although I'm reluctant since I
can think of other ways we can break the sysroots which this patch very
neatly solves.
The only other option would be to explicitly allow tar through some
linking/PATH magic :/.
Cheers,
Richard
next prev parent reply other threads:[~2012-03-21 21:21 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-03-21 10:44 [PATCH] bitbake.conf/sstate.bbclass: Change PATH when installing sstate files to avoid issues Richard Purdie
2012-03-21 17:54 ` McClintock Matthew-B29882
2012-03-21 21:12 ` Richard Purdie [this message]
2012-03-22 3:28 ` McClintock Matthew-B29882
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=1332364369.9740.185.camel@ted \
--to=richard.purdie@linuxfoundation.org \
--cc=B29882@freescale.com \
--cc=openembedded-core@lists.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox