summary refs log tree commit diff
path: root/pkgs/games/unvanquished
diff options
context:
space:
mode:
authorАлександр Цамутали <astsmtl@yandex.ru>2013-02-24 18:02:53 +0400
committerАлександр Цамутали <astsmtl@yandex.ru>2013-02-24 18:02:53 +0400
commit7d5056f8a3cf76b20d9b24e6644f2fc7fdf4a0f8 (patch)
treebab99da9248b278b93880babefa66571f20529d3 /pkgs/games/unvanquished
parent17d289498fc25dfdb824eeda5ed404a5f82e1aef (diff)
downloadnixlib-7d5056f8a3cf76b20d9b24e6644f2fc7fdf4a0f8.tar
nixlib-7d5056f8a3cf76b20d9b24e6644f2fc7fdf4a0f8.tar.gz
nixlib-7d5056f8a3cf76b20d9b24e6644f2fc7fdf4a0f8.tar.bz2
nixlib-7d5056f8a3cf76b20d9b24e6644f2fc7fdf4a0f8.tar.lz
nixlib-7d5056f8a3cf76b20d9b24e6644f2fc7fdf4a0f8.tar.xz
nixlib-7d5056f8a3cf76b20d9b24e6644f2fc7fdf4a0f8.tar.zst
nixlib-7d5056f8a3cf76b20d9b24e6644f2fc7fdf4a0f8.zip
games/unvanquished: New nixpkg.
Diffstat (limited to 'pkgs/games/unvanquished')
-rw-r--r--pkgs/games/unvanquished/default.nix68
1 files changed, 68 insertions, 0 deletions
diff --git a/pkgs/games/unvanquished/default.nix b/pkgs/games/unvanquished/default.nix
new file mode 100644
index 000000000000..03069f9fe14e
--- /dev/null
+++ b/pkgs/games/unvanquished/default.nix
@@ -0,0 +1,68 @@
+{ stdenv, fetchurl, cmake, mesa, SDL, libjpeg, libpng, glew, libwebp, ncurses
+, gmp, curl, nettle, openal, speex, libogg, libvorbis, libtheora, xvidcore
+, makeWrapper }:
+stdenv.mkDerivation rec {
+  name = "unvanquished-${version}";
+  version = "0.12.0";
+  src = fetchurl {
+    url = "https://github.com/Unvanquished/Unvanquished/archive/v${version}.tar.gz";
+    sha256 = "0spwin0vms1zzkbgzkm423k804nqr5d54xppjbwhdnrd5fdv0gyl";
+  };
+  buildInputs = [ cmake mesa SDL libjpeg libpng glew libwebp ncurses gmp curl
+                  nettle openal speex libogg libvorbis libtheora xvidcore 
+                  makeWrapper ];
+  preConfigure = ''prefix="$prefix/opt"'';
+  postInstall = ''
+    # cp -r ../main "$prefix/Unvanquished/"
+    mkdir -p "$out/bin"
+    substituteInPlace download-pk3.sh --replace /bin/bash ${stdenv.shell}
+    cp -v download-pk3.sh "$out/bin/unvanquished-download-pk3"
+    makeWrapper "$prefix/Unvanquished/daemon" "$out/bin/unvanquished" \
+                --run '[ -f ~/.Unvanquished/main/md5sums ] &&
+                       cd ~/.Unvanquished/main/ &&
+                       md5sum --quiet -c md5sums ||
+                       unvanquished-download-pk3' \
+                --run "cd '$prefix/Unvanquished'"
+    makeWrapper "$prefix/Unvanquished/daemonded" "$out/bin/unvanquished-ded" \
+                --run '[ -f ~/.Unvanquished/main/md5sums ] &&
+                       cd ~/.Unvanquished/main/ &&
+                       md5sum --quiet -c md5sums ||
+                       unvanquished-download-pk3' \
+                --run "cd '$prefix/Unvanquished'"
+  '';
+
+  meta = {
+    description = "A FLOSS FPS combining RTS elements with a futuristic, sci-fi setting.";
+    longDescription = ''
+      Unvanquished is a free, open-source first-person shooter
+      combining real-time strategy elements with a futuristic, sci-fi
+      setting. It is available for Windows, Linux, and Mac OS X.
+
+      Features:
+
+      * Two teams
+        Play as either the technologically advanced humans or the highly
+        adaptable aliens, with a fresh gameplay experience on both
+        sides.
+
+      * Build a base
+        Construct and maintain your base with a variety of useful
+        structures, or group up with teammates to take on the other
+        team.
+
+      * Level up
+        Earn rewards for victories against the other team, whether it's
+        a deadly new weapon or access to a whole new alien form.
+
+      * Customize
+        Compatibility with Quake 3 file formats and modification tools
+        allows for extensive customization of the game and its
+        setting.
+    '';
+    homepage = http://unvanquished.net;
+    #license = "unknown";
+    maintainers = with stdenv.lib.maintainers; [ astsmtl ];
+    # This package can take a lot of disk space, so unavailable from channel
+    #platforms = with stdenv.lib.platforms; linux;
+  };
+}