summary refs log tree commit diff
path: root/pkgs/games
diff options
context:
space:
mode:
authorVladimír Čunát <vcunat@gmail.com>2013-04-11 23:31:33 +0200
committerVladimír Čunát <vcunat@gmail.com>2013-04-11 23:31:33 +0200
commit8249695b618204efe142e2de9db289f989d270ad (patch)
treedad41af95ba4d16bc6640503d003d36d9e1debf2 /pkgs/games
parent7d9607f1511bfe496fcd77ef735e7fc7f1c6eb9f (diff)
parent6640000cb7148ba39bbdcca8e0cd7f5c224bce57 (diff)
downloadnixlib-8249695b618204efe142e2de9db289f989d270ad.tar
nixlib-8249695b618204efe142e2de9db289f989d270ad.tar.gz
nixlib-8249695b618204efe142e2de9db289f989d270ad.tar.bz2
nixlib-8249695b618204efe142e2de9db289f989d270ad.tar.lz
nixlib-8249695b618204efe142e2de9db289f989d270ad.tar.xz
nixlib-8249695b618204efe142e2de9db289f989d270ad.tar.zst
nixlib-8249695b618204efe142e2de9db289f989d270ad.zip
Merge branch 'master' into x-updates
Needed that to fix the tarball.
Diffstat (limited to 'pkgs/games')
-rw-r--r--pkgs/games/d1x-rebirth/default.nix23
-rw-r--r--pkgs/games/d2x-rebirth/default.nix23
-rw-r--r--pkgs/games/dhewm3/default.nix33
-rw-r--r--pkgs/games/openlierox/default.nix81
4 files changed, 111 insertions, 49 deletions
diff --git a/pkgs/games/d1x-rebirth/default.nix b/pkgs/games/d1x-rebirth/default.nix
new file mode 100644
index 000000000000..471eca78cf1b
--- /dev/null
+++ b/pkgs/games/d1x-rebirth/default.nix
@@ -0,0 +1,23 @@
+{stdenv, fetchurl, scons, pkgconfig, SDL, mesa, physfs, SDL_mixer }:
+
+stdenv.mkDerivation rec {
+  name = "d1x-rebirth-0.57.3";
+  src = fetchurl {
+    url = "http://www.dxx-rebirth.com/download/dxx/d1x-rebirth_v0.57.3-src.tar.gz";
+    sha256 = "07dbjza5flsczdsas0adb5xhn13gmhlpixa8ycp8hjm20y9kw1za";
+  };
+
+  buildInputs = [ scons pkgconfig SDL mesa physfs SDL_mixer ];
+
+  installPhase = ''
+    scons prefix=$out install
+  '';
+
+  meta = {
+    homepage = http://www.dxx-rebirth.com/;
+    description = "Source Port of the Descent 1 engine";
+    license = "BSD"; # Parallax license, like BSD I think
+    platforms = with stdenv.lib.platforms; linux;
+    maintainers = with stdenv.lib.maintainers; [viric];
+  };
+}
diff --git a/pkgs/games/d2x-rebirth/default.nix b/pkgs/games/d2x-rebirth/default.nix
new file mode 100644
index 000000000000..b52e29951983
--- /dev/null
+++ b/pkgs/games/d2x-rebirth/default.nix
@@ -0,0 +1,23 @@
+{stdenv, fetchurl, scons, pkgconfig, SDL, mesa, physfs, SDL_mixer }:
+
+stdenv.mkDerivation rec {
+  name = "d2x-rebirth-0.57.3";
+  src = fetchurl {
+    url = "http://www.dxx-rebirth.com/download/dxx/d2x-rebirth_v0.57.3-src.tar.gz";
+    sha256 = "0yyandmxz12bbpnd746nddjlqh5i7dylwm006shixis3w3giz77c";
+  };
+
+  buildInputs = [ scons pkgconfig SDL mesa physfs SDL_mixer ];
+
+  installPhase = ''
+    scons prefix=$out install
+  '';
+
+  meta = {
+    homepage = http://www.dxx-rebirth.com/;
+    description = "Source Port of the Descent 2 engine";
+    license = "BSD"; # Parallax license, like BSD I think
+    platforms = with stdenv.lib.platforms; linux;
+    maintainers = with stdenv.lib.maintainers; [viric];
+  };
+}
diff --git a/pkgs/games/dhewm3/default.nix b/pkgs/games/dhewm3/default.nix
new file mode 100644
index 000000000000..6036d7fabd55
--- /dev/null
+++ b/pkgs/games/dhewm3/default.nix
@@ -0,0 +1,33 @@
+{stdenv, fetchurl, unzip, cmake, SDL, mesa, zlib, libjpeg, libogg, libvorbis
+, openalSoft, curl }:
+
+stdenv.mkDerivation rec {
+  hash = "92a41322f4aa8bd45395d8088721c9a2bf43c79b";
+  name = "dhewm3-20130113-${hash}";
+  src = fetchurl {
+    url = "https://github.com/dhewm/dhewm3/zipball/${hash}";
+    sha256 = "0c17k60xhimpqi1xi9s1l7jbc97pqjnk4lgwyjb0agc3dkr73zwd";
+  };
+
+  # Add mesa linking
+  patchPhase = ''
+    sed -i 's/\<idlib\()\?\)$/idlib GL\1/' CMakeLists.txt
+  '';
+
+  unpackPhase = ''
+    unzip ${src}
+    cd */neo
+  '';
+
+  buildInputs = [ unzip cmake SDL mesa zlib libjpeg libogg libvorbis openalSoft
+    curl ];
+
+  enableParallelBuilding = true;
+
+  meta = {
+    homepage = https://github.com/dhewm/dhewm3;
+    description = "Doom 3 port to SDL";
+    license = "GPLv3";
+  };
+
+}
diff --git a/pkgs/games/openlierox/default.nix b/pkgs/games/openlierox/default.nix
index 751941bdfc1e..0c7e46ae0740 100644
--- a/pkgs/games/openlierox/default.nix
+++ b/pkgs/games/openlierox/default.nix
@@ -1,56 +1,39 @@
-a :  
-let 
-  fetchurl = a.fetchurl;
-
-  version = a.lib.attrByPath ["version"] "0.57beta8" a; 
-  buildInputs = with a; [
-    libX11 xproto gd SDL SDL_image SDL_mixer zlib libxml2
-    pkgconfig
-  ];
-
-in
-rec {
+{ stdenv, fetchurl, libX11, xproto, gd, SDL, SDL_image, SDL_mixer, zlib
+, libxml2, pkgconfig, curl, cmake, libzip }:
+
+stdenv.mkDerivation {
+  name = "openlierox-0.58rc3";
+
   src = fetchurl {
-    url = "http://downloads.sourceforge.net/project/openlierox/openlierox/OpenLieroX%200.57%20Beta8/OpenLieroX_0.57_beta8.src.tar.bz2";
-    sha256 = "1a3p03bi5v2mca7323mrckab9wsj83fjfcr6akrh9a6nlljcdn8d";
+    url = "mirror://sourceforge/openlierox/OpenLieroX_0.58_rc3.src.tar.bz2";
+    sha256 = "1k35xppfqi3qfysv81xq3hj4qdy9j2ciinbkfdcmwclcsf3nh94z";
   };
 
-  inherit buildInputs;
-  configureFlags = [];
-
-  /* doConfigure should be removed if not needed */
-  phaseNames = ["doInstall"];
-
-  setParams = a.noDepEntry (''
-    export SYSTEM_DATA_DIR="$out/share"
-    export BIN_DIR="$out/bin"
-    export DOC_DIR="$out/share/doc"
-    export PIXMAP_DIR="$out/share/pixmap"
-
-    export HAWKNL_BUILTIN=1
-    export LIBZIP_BUILTIN=1
-    export X11=1
-    export DEBUG=1
-  '');
-  
-  doBuild=a.fullDepEntry (''
-    sed -re 's/ -1/ 255 /g' -i *.sh
-
-    source functions.sh
-    export INCLUDE_PATH=$(echo $NIX_CFLAGS_COMPILE | grep_param -I)
-    
-    bash compile.sh
-  '') ["doUnpack" "addInputs" "setParams"];
-
-  doInstall = a.fullDepEntry (''
-    mkdir -p $BIN_DIR $SYSTEM_DATA_DIR $DOC_DIR $PIXMAP_DIR
-    bash install.sh
-  '') ["doBuild" "addInputs" "setParams" "defEnsureDir"];
-      
-  name = "openlierox-" + version;
+  NIX_CFLAGS_COMPILE = "-I${libxml2}/include/libxml2";
+
+  # The breakpad fails to build on x86_64, and it's only to report bugs upstream
+  cmakeFlags = [ "-DBREAKPAD=0" ];
+
+  preConfigure = ''
+    cmakeFlags="$cmakeFlags -DSYSTEM_DATA_DIR=$out/share"
+  '';
+
+  patchPhase = ''
+    sed -i s,curl/types.h,curl/curl.h, include/HTTP.h src/common/HTTP.cpp
+  '';
+
+  installPhase = ''
+    ensureDir $out/bin $out/share/OpenLieroX
+    cp bin/* $out/bin
+    cp -R ../share/gamedir/* $out/share/OpenLieroX
+  '';
+
+  buildInputs = [ libX11 xproto gd SDL SDL_image SDL_mixer zlib libxml2
+    pkgconfig curl cmake libzip ];
+
   meta = {
+    homepage = http://openlierox.net;
     description = "Real-time game with Worms-like shooting";
-    maintainers = [
-    ];
+    license = "LGPLv2+";
   };
 }