mirror of
https://github.com/SebastianWendel/nixpkgs.git
synced 2024-09-20 12:29:02 +02:00
Add xz support to builderDefs
svn path=/nixpkgs/trunk/; revision=17855
This commit is contained in:
parent
d72c439a26
commit
f237bad7b0
|
@ -22,6 +22,7 @@ let inherit (builtins) head tail trace; in
|
||||||
(hasSuffixHack ".tbz" s) then "tbz2"
|
(hasSuffixHack ".tbz" s) then "tbz2"
|
||||||
else if (hasSuffixHack ".tar.Z" s) then "tZ"
|
else if (hasSuffixHack ".tar.Z" s) then "tZ"
|
||||||
else if (hasSuffixHack ".tar.lzma" s) then "tar.lzma"
|
else if (hasSuffixHack ".tar.lzma" s) then "tar.lzma"
|
||||||
|
else if (hasSuffixHack ".tar.xz" s) then "tar.xz"
|
||||||
else if (hasSuffixHack ".zip" s) || (hasSuffixHack ".ZIP" s) then "zip"
|
else if (hasSuffixHack ".zip" s) || (hasSuffixHack ".ZIP" s) then "zip"
|
||||||
else if (hasSuffixHack "-cvs-export" s) then "cvs-dir"
|
else if (hasSuffixHack "-cvs-export" s) then "cvs-dir"
|
||||||
else if (hasSuffixHack ".nar.bz2" s) then "narbz2"
|
else if (hasSuffixHack ".nar.bz2" s) then "narbz2"
|
||||||
|
@ -212,6 +213,9 @@ let inherit (builtins) head tail trace; in
|
||||||
" else if (archiveType s) == "tar.lzma" then "
|
" else if (archiveType s) == "tar.lzma" then "
|
||||||
unlzma -d -c <'${s}' | tar xv
|
unlzma -d -c <'${s}' | tar xv
|
||||||
cd \"\$(unlzma -d -c <'${s}' | tar t | head -1 | sed -e 's@/.*@@' )\"
|
cd \"\$(unlzma -d -c <'${s}' | tar t | head -1 | sed -e 's@/.*@@' )\"
|
||||||
|
" else if (archiveType s) == "tar.xz" then "
|
||||||
|
xz -d -c <'${s}' | tar xv
|
||||||
|
cd \"\$(xz -d -c <'${s}' | tar t | head -1 | sed -e 's@/.*@@' )\"
|
||||||
" else if (archiveType s) == "zip" then "
|
" else if (archiveType s) == "zip" then "
|
||||||
unzip '${s}'
|
unzip '${s}'
|
||||||
cd \"$( unzip -lqq '${s}' | tail -1 |
|
cd \"$( unzip -lqq '${s}' | tail -1 |
|
||||||
|
|
Loading…
Reference in a new issue