[SOLVED] Cannot untar a tar.xz file

Issues related to applications and software problems
Post Reply
Unisolve
Posts: 13
Joined: 2011/09/24 22:40:20
Contact:

[SOLVED] Cannot untar a tar.xz file

Post by Unisolve » 2011/09/25 19:01:36

Searching the internet says I should do:

tar Jxvf gcc-4.6-20110916.tar.xz

or (with a dash)

tar -Jxvf gcc-4.6-20110916.tar.xz

but I keep getting the error: invalid option...

How do I decompress a gcc source tar ('xz' format)?

(What I'm looking to get is gfortran 4.6, if anyone knows a better way.)

Thanks.

Walter

User avatar
TrevorH
Site Admin
Posts: 33219
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: Cannot untar a tar.xz file

Post by TrevorH » 2011/09/25 19:37:35

[code]
yum install xz
(say Y to the prompt)
unxz gcc-4.6-20110916.tar.xz
tar -xvf gcc-4.6-20110916.tar
xz gcc-4.6-20110916.tar
[/code]

Unisolve
Posts: 13
Joined: 2011/09/24 22:40:20
Contact:

Re: Cannot untar a tar.xz file

Post by Unisolve » 2011/09/25 21:31:23

That did the trick - thanks!

User avatar
AlanBartlett
Forum Moderator
Posts: 9345
Joined: 2007/10/22 11:30:09
Location: ~/Earth/UK/England/Suffolk
Contact:

[SOLVED] Cannot untar a tar.xz file

Post by AlanBartlett » 2011/09/25 22:08:50

Thank you for reporting back.

For posterity (and on your behalf) this thread is marked [SOLVED].

Post Reply