bitbake: fetch2: fix unpack of .xz files
authorAndré Draszik <andre.draszik@linaro.org>
Tue, 30 Jul 2013 12:56:22 +0000 (12:56 +0000)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Wed, 31 Jul 2013 05:59:59 +0000 (06:59 +0100)
commit9514f4b798bba4c4ad33d03a74e0255a636257ca
tree157a528ad573c9b4ccbcc2984595f433bbb5d5b0
parentfe263502685b003679b8331180dff6df87860186
bitbake: fetch2: fix unpack of .xz files

If a file ends with .xz, it currently gets overwritten during unpack:
The decompress command for .xz files is:
  'xz -dc %s > %s' % (file, efile)
and as efile == file, we end up overwriting file (the source).

Fix this by adding .xz to the list of suffixes that that need to
be removed from a file name for an extract command, leaving the
bare file name. Now, for a given file foo.xz,
file == foo.xz and efile == foo, similar to how .gz .bz2 and .Z
files are treated.

(Bitbake rev: 2cd2d0a48e12ab4358fb967eaf7a56c17993f48d)

Signed-off-by: André Draszik <andre.draszik@linaro.org>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
bitbake/lib/bb/fetch2/__init__.py