From 4f3a6d8ee2d35941d8092ebce5a094fc5cdae0d4 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Thu, 4 Feb 2016 19:24:27 +0300 Subject: [PATCH] zandronum-bin: fix argv0, add license --- pkgs/games/zandronum/bin.nix | 10 ++++++++-- pkgs/top-level/all-packages.nix | 2 +- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/pkgs/games/zandronum/bin.nix b/pkgs/games/zandronum/bin.nix index cf46877ef713..92f93d8f7785 100644 --- a/pkgs/games/zandronum/bin.nix +++ b/pkgs/games/zandronum/bin.nix @@ -16,6 +16,7 @@ , pango , SDL , zlib +, makeWrapper }: stdenv.mkDerivation rec { @@ -46,6 +47,8 @@ stdenv.mkDerivation rec { zlib ]; + nativeBuildInputs = [ makeWrapper ]; + phases = [ "unpackPhase" "installPhase" ]; sourceRoot = "."; @@ -64,14 +67,17 @@ stdenv.mkDerivation rec { --set-rpath $libPath \ $out/share/zandronum/zandronum-server - ln -s $out/share/zandronum/zandronum $out/bin/zandronum - ln -s $out/share/zandronum/zandronum-server $out/bin/zandronum-server + # If we don't set absolute argv0, zandronum.wad file is not found. + makeWrapper $out/share/zandronum/zandronum $out/bin/zandronum + makeWrapper $out/share/zandronum/zandronum-server $out/bin/zandronum-server ''; meta = { homepage = http://zandronum.com/; description = "multiplayer oriented port, based off Skulltag, for Doom and Doom II by id Software. Binary version for online play."; maintainer = [ stdenv.lib.maintainers.lassulus ]; + # Binary version has different version string than source code version. + license = stdenv.lib.licenses.unfreeRedistributable; platforms = [ "x86_64-linux" ]; }; } diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index b2276b176cad..17cd638ada6f 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -14596,7 +14596,7 @@ let serverOnly = true; }; - zandronum-bin = callPackage ../games/zandronum/bin.nix { }; + zandronum-bin = hiPrio (callPackage ../games/zandronum/bin.nix { }); zangband = callPackage ../games/zangband { };