nixpkgs/pkgs/games/sgt-puzzles/default.nix
2012-10-18 00:21:42 +04:00

41 lines
996 B
Nix

a :
let
fetchsvn = a.fetchsvn;
version = a.lib.attrByPath ["version"] "r8541" a;
buildInputs = with a; [
gtk pkgconfig libX11 perl
];
in
rec {
src = fetchsvn {
url = svn://svn.tartarus.org/sgt/puzzles;
rev = "9689";
sha256 = "33285a971fee67324f8867de22582931135d8b8ee4cc2c41c46c3ba81eb99cb7";
} + "/";
inherit buildInputs;
configureFlags = [];
makeFlags = ["prefix=$out" "gamesdir=$out/bin"];
neededDirs = ["$out/bin" "$out/share"];
extraDoc = ["puzzles.txt"];
mkMakefiles = a.fullDepEntry ''
perl mkfiles.pl
'' ["minInit" "doUnpack" "addInputs"];
setVars = a.noDepEntry ''
export NIX_LDFLAGS="$NIX_LDFLAGS -lX11"
export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE -Wno-error=variadic-macros"
'';
/* doConfigure should be removed if not needed */
phaseNames = ["addInputs" "setVars" "mkMakefiles" "doMakeInstall"];
name = "sgt-puzzles-" + version;
meta = {
description = "Simon Tatham's portable puzzle collection";
};
}