summaryrefslogtreecommitdiffstats
path: root/pkgs/games/crack-attack
diff options
context:
space:
mode:
authorLluís Batlle i Rossell <viric@vicerveza.homeunix.net>2010-09-28 22:37:27 +0000
committerLluís Batlle i Rossell <viric@vicerveza.homeunix.net>2010-09-28 22:37:27 +0000
commitcecffb9df5b322c8708c6b02bc193eec9f707f3f (patch)
treeb3a1edf5e18ea8c3476a71252d54a1d6522dd9bd /pkgs/games/crack-attack
parentfea2d56f0945f4a29591feb478b10b8f426934f4 (diff)
Adding crack-attack
(patch sent by Piotr Pietraszkiewicz) svn path=/nixpkgs/trunk/; revision=23987
Diffstat (limited to 'pkgs/games/crack-attack')
-rw-r--r--pkgs/games/crack-attack/crack-attack-1.1.14-gcc43.patch10
-rw-r--r--pkgs/games/crack-attack/crack-attack-1.1.14-glut.patch10
-rw-r--r--pkgs/games/crack-attack/default.nix27
3 files changed, 47 insertions, 0 deletions
diff --git a/pkgs/games/crack-attack/crack-attack-1.1.14-gcc43.patch b/pkgs/games/crack-attack/crack-attack-1.1.14-gcc43.patch
new file mode 100644
index 000000000000..fb2910d128ee
--- /dev/null
+++ b/pkgs/games/crack-attack/crack-attack-1.1.14-gcc43.patch
@@ -0,0 +1,10 @@
+--- crack-attack-1.1.14/src/Game.h
++++ crack-attack-1.1.14/src/Game.h
+@@ -34,6 +34,7 @@
+ #include <climits>
+ #include <cstdlib>
+ #include <cmath>
++#include <cstring>
+
+ #ifdef __MINGW32__
+ # include <windows.h>
diff --git a/pkgs/games/crack-attack/crack-attack-1.1.14-glut.patch b/pkgs/games/crack-attack/crack-attack-1.1.14-glut.patch
new file mode 100644
index 000000000000..4daea4c53a28
--- /dev/null
+++ b/pkgs/games/crack-attack/crack-attack-1.1.14-glut.patch
@@ -0,0 +1,10 @@
+--- crack-attack-1.1.14/src/Attack.cxx
++++ crack-attack-1.1.14/src/Attack.cxx
+@@ -83,6 +83,7 @@
+ int height = -1, width = -1;
+
+ player_name[0] = '\0';
++ glutInit(&argc, argv);
+ parseCommandLine(argc, argv, mode, port, host_name, player_name, height, width);
+ run_crack_attack(mode, port, host_name, player_name, height, width);
+
diff --git a/pkgs/games/crack-attack/default.nix b/pkgs/games/crack-attack/default.nix
new file mode 100644
index 000000000000..7e90d448a8be
--- /dev/null
+++ b/pkgs/games/crack-attack/default.nix
@@ -0,0 +1,27 @@
+{ stdenv, fetchurl, pkgconfig, gtk, freeglut, SDL, mesa, libXi, libXmu}:
+
+stdenv.mkDerivation {
+ name = "crack-attack-1.1.14";
+
+ src = fetchurl {
+ url = mirror://savannah/crack-attack/crack-attack-1.1.14.tar.gz;
+ sha256 = "1sakj9a2q05brpd7lkqxi8q30bccycdzd96ns00s6jbxrzjlijkm";
+ };
+
+ buildInputs =
+ [
+ pkgconfig gtk freeglut SDL mesa libXi libXmu
+ ];
+
+ meta = {
+ description = "A fast-paced puzzle game inspired by the classic Super NES title Tetris Attack!";
+ homepage = http://www.nongnu.org/crack-attack/;
+ license = "GPLv2";
+ platforms = stdenv.lib.platforms.linux;
+ };
+
+ patches = [
+ ./crack-attack-1.1.14-gcc43.patch
+ ./crack-attack-1.1.14-glut.patch
+ ];
+}