Bug 4460 - seamless xz decompression support in tar
Summary: seamless xz decompression support in tar
Status: RESOLVED FIXED
Alias: None
Product: Busybox
Classification: Unclassified
Component: Other (show other bugs)
Version: 1.19.x
Hardware: All All
: P5 enhancement
Target Milestone: ---
Assignee: unassigned
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-11-06 18:52 UTC by Michael Tokarev
Modified: 2012-05-27 23:33 UTC (History)
1 user (show)

See Also:
Host:
Target:
Build:


Attachments
implementation (6.71 KB, text/plain)
2011-11-06 18:54 UTC, Michael Tokarev
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Tokarev 2011-11-06 18:52:50 UTC
currently, busybox tar does not recognize xz-compressed archives automatically, the code in that place has "TODO" comment.  The attached patch implements the missing functionality.

Some missing bits:

 tar taf  and  tar tJf  does not work: needs to check magic numbers.  Probably need to review all the data offsets passed to all the decompress_*() routines.

 no compression support, -- buzybox xz does not support compression

Thanks.
Comment 1 Michael Tokarev 2011-11-06 18:54:08 UTC
Created attachment 3740 [details]
implementation
Comment 2 Denys Vlasenko 2012-05-27 23:33:03 UTC
Fixed in git:

commit dfc2473b9ed88039697ac89ee2a4301cdaefcf84
Author: Boris Reisig <boris@boris.ca>
Date:   Thu May 24 09:01:55 2012 +0200

    tar: support -J, --xz explicit compression option

    function                                             old     new   delta
    tar_main                                             868     881     +13
    tar_longopts                                         285     290      +5
    packed_usage                                       29267   29270      +3