[lfs-support] LFS-7.2 host system tar version

nettxzl nettxzl at gmail.com
Fri Nov 23 17:07:11 PST 2012

On 11/24/12, Bruce Dubbs <bruce.dubbs at gmail.com> wrote:
> nettxzl wrote:
>> (Sorry if this comes through twice. My first attempt seems to have
>> vanished.)
>> Hi,
>> I was starting the gcc-4.7.1 (Pass 1) build in Chap. 5 and I was
>> trying to unpack the files compressed with xz following the command
>> given there:
>> tar -Jxf ../mpfr-3.1.1.tar.xz
>> but I got this error message:
>> tar: invalid option -- J
>> I guessed my host system tar is too old, but it is tar-1.19 and this
>> is newer than the minimum version, tar-1.18, stated in the host system
>> requirements.
>> It's not a problem because I can unpack the files in two steps: first
>> with xz, then with tar.
>> But I think you may want to update the tar version in the host system
>> requirements.
>> I checked the tar release info at
>> http://www.gnu.org/software/tar/#releases
>> -J was only introduced as a new short option in tar-1.21 as an alias for
>> --lzma.
>> And in tar-1.22, the --xz option was introduced to support xz
>> compression, while the short option -J was reassigned as a shortcut
>> for --xz.
> You do not need to specify the compression type to tar when unpacking.
> tar -xf filename
> will do it.  It's another issue if you don't have the xz libraries.
>    -- Bruce

Hi,  good to know. I tried it out

tar -xf filename.xz

but it does not unpack and I get the error messages

tar: This does not look like a tar archive
tar: Skipping to next header
tar: Error exit delayed from previous errors

(Your suggestion does work for packages with extensions gz and bz2.)

I do have xz installed, and my tar is 1.19 which is above the minimum
version stated in the host system requirements. So I'm still wondering
what I'm missing in my system.

As I said it's not a problem, but I'm curious why it does not work,
since I seem to have the requirements.


More information about the lfs-support mailing list