buildhistory.bbclass: Improve robustness in image file listing
authorOtavio Salvador <otavio@ossystems.com.br>
Thu, 23 Jan 2014 12:11:05 +0000 (10:11 -0200)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Tue, 28 Jan 2014 11:32:50 +0000 (11:32 +0000)
commit5c28ebc74660431934a0f1723405dd7732347856
tree6d7cd9aa55645abbc5ae31cb09331b747dc6e24d
parent27761e40249cd912b870371cc182df552ce4a730
buildhistory.bbclass: Improve robustness in image file listing

The filenames sometimes may have strange names. With the 'awk' script
it handled a limited number of spaces in the filename and a package
installing a file named "test file with spaces" would have its name
truncated.

This patch uses the find's printf formating to simplify the code and
properly handle this case. From a testing image, the only diff produced
is:

,----[ files-in-image.txt diff ]
| --rwxr-xr-x root       root                0 ./usr/bin/test\ file\ with\
| +-rwxr-xr-x root       root                0 ./usr/bin/test file with spaces
`----

The options used are available since findutils 4.2.5, released in 19
Nov 2004, making it available in all supported host distributions.

(From OE-Core rev: b09e24449c1c9ae335732dd070eacf66777556a1)

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/classes/buildhistory.bbclass