[OE-core] [PATCH] busybox: Guard against interrupted compiles
Richard Purdie
richard.purdie at linuxfoundation.org
Mon Jan 23 13:05:48 UTC 2017
On Mon, 2017-01-23 at 13:56 +0100, Mario Domenech Goulart wrote:
> Hi,
>
> On Mon, 23 Jan 2017 12:35:52 +0000 Richard Purdie <richard.purdie at lin
> uxfoundation.org> wrote:
>
> >
> > On Mon, 2017-01-23 at 12:26 +0000, Richard Purdie wrote:
> > >
> > > diff --git a/meta/recipes-core/busybox/busybox.inc
> > > b/meta/recipes-
> > > core/busybox/busybox.inc
> > > index 1f4a48c..f247e8d 100644
> > > --- a/meta/recipes-core/busybox/busybox.inc
> > > +++ b/meta/recipes-core/busybox/busybox.inc
> > > @@ -141,6 +141,10 @@ do_compile() {
> > > unset CFLAGS CPPFLAGS CXXFLAGS LDFLAGS
> > > if [ "${BUSYBOX_SPLIT_SUID}" = "1" -a x`grep
> > > "CONFIG_FEATURE_INDIVIDUAL=y" .config` = x ]; then
> > > # split the .config into two parts, and make two busybox
> > > binaries
> > > + if [ -e .config.org ]; then
> > > + # Need to guard again an interrupted
> > > do_compile - restore any backup
> > > + cp .config.orig .config
> > > + fi
> > I have fixed the typo...
> Wouldn't it be better to have something like
>
> cp .config.orig .config || true
>
> instead, to prevent race conditions?
Prevent which race condition? I'd hope at this point we're the only
thing touching the .config file?
Cheers,
Richard
More information about the Openembedded-core
mailing list