[bitbake-devel] [PATCH] siggen: add quotes around variable values to see whitespace

Richard Purdie richard.purdie at linuxfoundation.org
Thu Mar 7 10:48:15 UTC 2013


On Mon, 2013-03-04 at 09:49 -0600, Mark Hatle wrote:
> On 3/2/13 10:50 AM, Martin Jansa wrote:
> > * without this change it's hard to see what's changed:
> >    bitbake-diffsigs sstate-cache/*/sstate-depmodwrapper-cross-cortexa8-vfp-neon-oe-linux-gnueabi-1.0-r0-cortexa8-vfp-neon-*_populate-sysroot.tgz.siginfo
> >    basehash changed from 62f28c13172d38af917716d6d4b15ac5 to 9cf38842bcc79e0a4356856a64141548
> >    Variable TUNE_CCARGS value changed from  -march=armv7-a    -mthumb -mthumb-interwork -mfloat-abi=softfp -mfpu=neon -mtune=cortex-a8  to  -march=armv7-a    -mthumb -mthumb-interwork -mfloat-abi=softfp -mfpu=neon -mtune=cortex-a8
> >    Hash for dependent task depmodwrapper-cross_1.0.bb.do_install changed from 4494cb6c117309a9b4c541ad86c0aac5 to 1e3bcf2d14e5bd30a38350b41bb98db3
> >
> > * with this change, we can see extra trailing space in first version:
> >    basehash changed from 62f28c13172d38af917716d6d4b15ac5 to 9cf38842bcc79e0a4356856a64141548
> >    Variable TUNE_CCARGS value changed from ' -march=armv7-a    -mthumb -mthumb-interwork -mfloat-abi=softfp -mfpu=neon -mtune=cortex-a8 ' to ' -march=armv7-a    -mthumb -mthumb-interwork -mfloat-abi=softfp -mfpu=neon -mtune=cortex-a8'
> >    Hash for dependent task depmodwrapper-cross_1.0.bb.do_install changed from 4494cb6c117309a9b4c541ad86c0aac5 to 1e3bcf2d14e5bd30a38350b41bb98db3
> 
> No objection to this patch, but it does raise the question.  Should we somehow 
> strip the leading and training white space, maybe even multiple spaces (like 
> above) and then use the results to generate the checksum?
>
> If I saw the above, my first comment would be "well that's stupid, the output is 
> the same"..  (Of course performance might be impacted by all of that stripping..)

Bitbake has no idea whether the whitespace means anything in any given
context when its constructing the checksums. Deciding when to strip and
what to strip would be the kind of thing nightmares are made of and
we're not going there. It was a conscious choice it behaves like it does
now and I still believe its the right one.

Cheers,

Richard





More information about the bitbake-devel mailing list