[OE-core] [PATCH v2] sstate.bbclass: update .siginfo atime

Patrick Ohly patrick.ohly at intel.com
Mon Mar 6 21:46:17 UTC 2017


On Mon, 2017-03-06 at 21:58 +0200, Ed Bartosh wrote:
> On Mon, Mar 06, 2017 at 08:31:55PM +0100, Patrick Ohly wrote:
> > On Mon, 2017-03-06 at 19:50 +0200, Ed Bartosh wrote:
> > > On Mon, Mar 06, 2017 at 04:49:25PM +0000, Burton, Ross wrote:
> > > > On 6 March 2017 at 15:31, Ed Bartosh <ed.bartosh at linux.intel.com> wrote:
> > > > 
> > > > > +       [ -h ${SSTATE_PKG}.siginfo ] && touch -a ${SSTATE_PKG}.siginfo
> > > > >
> > > > 
> > > > $ ( [ -h / ] && echo something ); echo $?
> > > > 1
> > > > 
> > > > If the -h fails then this is still going to cause sstate_unpack_package to
> > > > trap.
> > > 
> > > I don't think it will as '&&' and '||' lists are among other special cases where
> > > shell doesn't exits on error.
> > 
> > True, but if the clause happens to be the last one in a function or
> > script (for example, after restructuring code), then the return code of
> > that becomes non-zero, which isn't intended.
> 
> Exactly because of this I moved my changes up in the function in v2.

And someone else might accidentally move it down again, without
understanding the consequences. It's simply safer to be explicit, IMHO.
Not worth a v3, but perhaps in the future.

-- 
Best Regards, Patrick Ohly

The content of this message is my personal opinion only and although
I am an employee of Intel, the statements I make here in no way
represent Intel's position on the issue, nor am I authorized to speak
on behalf of Intel on this matter.






More information about the Openembedded-core mailing list