p7zip: add setup hook

This commit is contained in:
Nikolay Amiantov 2016-12-17 15:04:59 +03:00
parent f9281609ae
commit 0063c8acb4
2 changed files with 7 additions and 0 deletions

View file

@ -25,6 +25,8 @@ stdenv.mkDerivation rec {
enableParallelBuilding = true;
setupHook = ./setup-hook.sh;
meta = {
homepage = http://p7zip.sourceforge.net/;
description = "A port of the 7-zip archiver";

View file

@ -0,0 +1,5 @@
unpackCmdHooks+=(_try7zip)
_try7zip() {
if ! [[ "$curSrc" =~ \.7z$ ]]; then return 1; fi
7z x "$curSrc"
}