diff options
Diffstat (limited to 'nixpkgs/pkgs/games/mars/default.nix')
-rw-r--r-- | nixpkgs/pkgs/games/mars/default.nix | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/games/mars/default.nix b/nixpkgs/pkgs/games/mars/default.nix new file mode 100644 index 000000000000..668605a9ae10 --- /dev/null +++ b/nixpkgs/pkgs/games/mars/default.nix @@ -0,0 +1,37 @@ +{ stdenv, fetchgit, cmake, libGLU_combined, sfml, fribidi, taglib }: +stdenv.mkDerivation rec { + name = "mars-${version}-${rev}"; + version = "0.7.5"; + rev = "c855d04409"; + src = fetchgit { + url = "https://github.com/thelaui/M.A.R.S..git"; + inherit rev; + sha256 = "1r4c5gap1z2zsv4yjd34qriqkxaq4lb4rykapyzkkdf4g36lc3nh"; + }; + buildInputs = [ cmake libGLU_combined sfml fribidi taglib ]; + patches = [ + ./unbind_fix.patch + ./fix-gluortho2d.patch + ]; + installPhase = '' + cd .. + find -name '*.svn' -exec rm -rf {} \; + mkdir -p "$out/share/mars/" + mkdir -p "$out/bin/" + cp -rv data resources credits.txt license.txt "$out/share/mars/" + cp -v mars "$out/bin/mars.bin" + cat << EOF > "$out/bin/mars" + #! ${stdenv.shell} + cd "$out/share/mars/" + exec "$out/bin/mars.bin" "\$@" + EOF + chmod +x "$out/bin/mars" + ''; + meta = with stdenv.lib; { + homepage = http://mars-game.sourceforge.net/; + description = "A game about fighting with ships in a 2D space setting"; + license = licenses.gpl3Plus; + maintainers = [ maintainers.astsmtl ]; + platforms = platforms.linux; + }; +} |