diff options
Diffstat (limited to 'pkgs/games')
-rw-r--r-- | pkgs/games/2048-in-terminal/default.nix | 4 | ||||
-rw-r--r-- | pkgs/games/armagetronad/default.nix | 2 | ||||
-rw-r--r-- | pkgs/games/dxx-rebirth/assets.nix | 55 | ||||
-rw-r--r-- | pkgs/games/dxx-rebirth/full.nix | 30 | ||||
-rw-r--r-- | pkgs/games/factorio/default.nix | 34 | ||||
-rw-r--r-- | pkgs/games/garden-of-coloured-lights/default.nix | 2 | ||||
-rw-r--r-- | pkgs/games/mnemosyne/default.nix | 34 | ||||
-rw-r--r-- | pkgs/games/openxcom/default.nix | 22 | ||||
-rw-r--r-- | pkgs/games/quakespasm/vulkan.nix | 47 | ||||
-rw-r--r-- | pkgs/games/rogue/default.nix | 2 | ||||
-rw-r--r-- | pkgs/games/ultrastardx/default.nix | 2 | ||||
-rw-r--r-- | pkgs/games/zdoom/bcc-git.nix | 31 | ||||
-rw-r--r-- | pkgs/games/zdoom/bcc-warning-fix.patch | 25 |
13 files changed, 255 insertions, 35 deletions
diff --git a/pkgs/games/2048-in-terminal/default.nix b/pkgs/games/2048-in-terminal/default.nix index 288c852b11e3..5d91bc04114b 100644 --- a/pkgs/games/2048-in-terminal/default.nix +++ b/pkgs/games/2048-in-terminal/default.nix @@ -13,6 +13,10 @@ stdenv.mkDerivation rec { buildInputs = [ ncurses ]; + prePatch = '' + sed -i '1i#include <fcntl.h>\n' save.c + ''; + enableParallelBuilding = true; preInstall = '' diff --git a/pkgs/games/armagetronad/default.nix b/pkgs/games/armagetronad/default.nix index 21f545100b31..0fb75b3d345b 100644 --- a/pkgs/games/armagetronad/default.nix +++ b/pkgs/games/armagetronad/default.nix @@ -15,6 +15,8 @@ stdenv.mkDerivation { NIX_LDFLAGS = [ "-lSDL_image" ]; + enableParallelBuilding = true; + configureFlags = [ "--disable-etc" ]; buildInputs = [ SDL SDL_image libxml2 libjpeg libpng mesa zlib ]; diff --git a/pkgs/games/dxx-rebirth/assets.nix b/pkgs/games/dxx-rebirth/assets.nix new file mode 100644 index 000000000000..1fd64f5b00d0 --- /dev/null +++ b/pkgs/games/dxx-rebirth/assets.nix @@ -0,0 +1,55 @@ +{ stdenv, requireFile, gogUnpackHook }: + +let + generic = ver: source: let + pname = "descent${toString ver}"; + in stdenv.mkDerivation rec { + name = "${pname}-assets-${version}"; + version = "2.0.0.7"; + + src = requireFile rec { + name = "setup_descent12_${version}.exe"; + sha256 = "1r1drbfda6czg21f9qqiiwgnkpszxgmcn5bafp5ljddh34swkn3f"; + message = '' + While the Descent ${toString ver} game engine is free, the game assets are not. + + Please purchase the game on gog.com and download the Windows installer. + + Once you have downloaded the file, please use the following command and re-run the + installation: + + nix-prefetch-url file://\$PWD/${name} + ''; + }; + + nativeBuildInputs = [ gogUnpackHook ]; + + dontBuild = true; + dontFixup = true; + + installPhase = '' + runHook preInstall + + mkdir -p $out/share/{games/${pname},doc/${pname}/examples} + pushd "app/${source}" + mv dosbox*.conf $out/share/doc/${pname}/examples + mv *.txt *.pdf $out/share/doc/${pname} + cp -r * $out/share/games/descent${toString ver} + popd + + runHook postInstall + ''; + + meta = with stdenv.lib; { + description = "Descent ${toString ver} assets from GOG"; + homepage = http://www.dxx-rebirth.com/; + license = licenses.unfree; + maintainers = with maintainers; [ peterhoeg ]; + hydraPlatforms = []; + }; + }; + +in { + descent1-assets = generic 1 "descent"; + descent2-assets = generic 2 "descent 2"; +} diff --git a/pkgs/games/dxx-rebirth/full.nix b/pkgs/games/dxx-rebirth/full.nix new file mode 100644 index 000000000000..baf8b80add10 --- /dev/null +++ b/pkgs/games/dxx-rebirth/full.nix @@ -0,0 +1,30 @@ +{ stdenv, makeWrapper +, dxx-rebirth, descent1-assets, descent2-assets }: + +let + generic = ver: assets: stdenv.mkDerivation rec { + name = "d${toString ver}x-rebirth-full-${assets.version}"; + + nativeBuildInputs = [ makeWrapper ]; + + buildCommand = '' + mkdir -p $out/bin + + makeWrapper ${dxx-rebirth}/bin/d${toString ver}x-rebirth $out/bin/descent${toString ver} \ + --add-flags "-hogdir ${assets}/share/games/descent${toString ver}" + ''; + + meta = with stdenv.lib; { + description = "Descent ${toString ver} using the DXX-Rebirth project engine and game assets from GOG"; + homepage = http://www.dxx-rebirth.com/; + license = with licenses; [ free unfree ]; + maintainers = with maintainers; [ peterhoeg ]; + platforms = with platforms; linux; + hydraPlatforms = []; + }; + }; + +in { + d1x-rebirth-full = generic 1 descent1-assets; + d2x-rebirth-full = generic 2 descent2-assets; +} diff --git a/pkgs/games/factorio/default.nix b/pkgs/games/factorio/default.nix index ac04022a4629..6a5cea0634da 100644 --- a/pkgs/games/factorio/default.nix +++ b/pkgs/games/factorio/default.nix @@ -4,6 +4,7 @@ , releaseType , mods ? [] , username ? "" , password ? "" +, experimental ? false }: assert releaseType == "alpha" @@ -14,19 +15,38 @@ let # NB If you nix-prefetch-url any of these, be sure to add a --name arg, # where the ultimate "_" (before the version) is changed to a "-". + branch = if experimental then "experimental" else "stable"; binDists = { x86_64-linux = let bdist = bdistForArch { inUrl = "linux64"; inTar = "x64"; }; in { - alpha = bdist { sha256 = "1i25q8x80qdpmf00lvml67gyklrfvmr4gfyakrx954bq8giiy4ll"; fetcher = authenticatedFetch; }; - headless = bdist { sha256 = "0v5sypz1q6x6hi6k5cyi06f9ld0cky80l0z64psd3v2ax9hyyh8h"; }; - demo = bdist { sha256 = "0aca8gks7wl7yi821bcca16c94zcc41agin5j0vfz500i0sngzzw"; version = "0.15.36"; }; + alpha = { + stable = bdist { sha256 = "1i25q8x80qdpmf00lvml67gyklrfvmr4gfyakrx954bq8giiy4ll"; fetcher = authenticatedFetch; }; + experimental = bdist { sha256 = "0s7cn5xhzwn793bmvlhlmibhbxdpfmpnpn33k5a4hdprc5gc27rg"; version = "0.16.24"; fetcher = authenticatedFetch; }; + }; + headless = { + stable = bdist { sha256 = "0v5sypz1q6x6hi6k5cyi06f9ld0cky80l0z64psd3v2ax9hyyh8h"; }; + experimental = bdist { sha256 = "1ff4yjybiqr5kw583hmxkbrbxa3haj4bkjj8sx811c3s269gspi2"; version = "0.16.24"; }; + }; + demo = { + stable = bdist { sha256 = "0aca8gks7wl7yi821bcca16c94zcc41agin5j0vfz500i0sngzzw"; version = "0.15.36"; }; + experimental = bdist { }; + }; }; i686-linux = let bdist = bdistForArch { inUrl = "linux32"; inTar = "i386"; }; in { - alpha = bdist { sha256 = "0nnfkxxqnywx1z05xnndgh71gp4izmwdk026nnjih74m2k5j086l"; version = "0.14.23"; nameMut = asGz; }; - headless = bdist { }; - demo = bdist { }; + alpha = { + stable = bdist { sha256 = "0nnfkxxqnywx1z05xnndgh71gp4izmwdk026nnjih74m2k5j086l"; version = "0.14.23"; nameMut = asGz; }; + experimental = bdist { }; + }; + headless = { + stable = bdist { }; + experimental = bdist { }; + }; + demo = { + stable = bdist { }; + experimental = bdist { }; + }; }; }; - actual = binDists.${stdenv.system}.${releaseType} or (throw "Factorio: unsupported platform"); + actual = binDists.${stdenv.system}.${releaseType}.${branch} or (throw "Factorio: unsupported platform"); bdistForArch = arch: { sha256 ? null , version ? "0.15.40" diff --git a/pkgs/games/garden-of-coloured-lights/default.nix b/pkgs/games/garden-of-coloured-lights/default.nix index b8550b3712e3..066cadb13b17 100644 --- a/pkgs/games/garden-of-coloured-lights/default.nix +++ b/pkgs/games/garden-of-coloured-lights/default.nix @@ -20,7 +20,7 @@ stdenv.mkDerivation rec { meta = with stdenv.lib; { description = "Old-school vertical shoot-em-up / bullet hell"; homepage = http://garden.sourceforge.net/drupal/; - maintainers = with maintainers; [ profpatsch ]; + maintainers = with maintainers; [ Profpatsch ]; license = licenses.gpl3; }; diff --git a/pkgs/games/mnemosyne/default.nix b/pkgs/games/mnemosyne/default.nix index 02bd0ba78d18..a5b349334923 100644 --- a/pkgs/games/mnemosyne/default.nix +++ b/pkgs/games/mnemosyne/default.nix @@ -1,30 +1,40 @@ { stdenv , fetchurl -, pythonPackages +, python }: -let - version = "2.3.2"; -in pythonPackages.buildPythonApplication rec { - name = "mnemosyne-${version}"; + +python.pkgs.buildPythonApplication rec { + pname = "mnemosyne"; + version = "2.6"; + src = fetchurl { - url = "http://sourceforge.net/projects/mnemosyne-proj/files/mnemosyne/${name}/Mnemosyne-${version}.tar.gz"; - sha256 = "0jkrw45i4v24p6xyq94z7rz5948h7f5dspgs5mcdaslnlp2accfp"; + url = "mirror://sourceforge/project/mnemosyne-proj/mnemosyne/mnemosyne-${version}/Mnemosyne-${version}.tar.gz"; + sha256 = "0b7b5sk5bfbsg5cyybkv5xw9zw257v3khsn0lwlbxnlhakd0rsg4"; }; - propagatedBuildInputs = with pythonPackages; [ - pyqt4 + + propagatedBuildInputs = with python.pkgs; [ + pyqt5 matplotlib cherrypy + cheroot webob + pillow ]; - preConfigure = '' + + # No tests/ directrory in tarball + doCheck = false; + + prePatch = '' substituteInPlace setup.py --replace /usr $out find . -type f -exec grep -H sys.exec_prefix {} ';' | cut -d: -f1 | xargs sed -i s,sys.exec_prefix,\"$out\", ''; + postInstall = '' mkdir -p $out/share - mv $out/lib/python2.7/site-packages/$out/share/locale $out/share - rm -r $out/lib/python2.7/site-packages/nix + mv $out/${python.sitePackages}/$out/share/locale $out/share + rm -r $out/${python.sitePackages}/nix ''; + meta = { homepage = https://mnemosyne-proj.org/; description = "Spaced-repetition software"; diff --git a/pkgs/games/openxcom/default.nix b/pkgs/games/openxcom/default.nix index 65c2a42922b2..bf451af9ad73 100644 --- a/pkgs/games/openxcom/default.nix +++ b/pkgs/games/openxcom/default.nix @@ -1,22 +1,18 @@ -{stdenv, fetchurl, fetchpatch, cmake, mesa, zlib, openssl, libyamlcpp, boost +{stdenv, fetchFromGitHub, fetchpatch, cmake, mesa, zlib, openssl, libyamlcpp, boost , SDL, SDL_image, SDL_mixer, SDL_gfx }: -let version = "1.0.0"; in +let version = "1.0.0.2018.01.28"; in stdenv.mkDerivation { name = "openxcom-${version}"; - src = fetchurl { - url = http://openxcom.org/file/1726/; - sha256 = "1rmg10nklvf86ckbbssyvbg5cd4p7in5zq3mas2yyffdjk9i40v6"; - name = "openxcom-${version}.tar.gz"; + src = fetchFromGitHub { + owner = "SupSuper"; + repo = "OpenXcom"; + rev = "b148916268a6ce104c3b6b7eb4d9e0487cba5487"; + sha256 = "1128ip3g4aw59f3f23mvlyhl8xckhwjjw9rd7wn7xv51hxdh191c"; }; - buildInputs = [ cmake mesa zlib openssl libyamlcpp boost - SDL SDL_image SDL_mixer SDL_gfx ]; - - patches = [ (fetchpatch { - url = "https://github.com/SupSuper/OpenXcom/commit/49bec0851fc6e5365cac0f71b2c40a80ddf95e77.patch"; - sha256 = "156fk8wz4qc0nmqq3zjb6kw84qirabads2azr6xvlgb3lcn327v2"; - }) ]; + nativeBuildInputs = [ cmake ]; + buildInputs = [ SDL SDL_gfx SDL_image SDL_mixer boost libyamlcpp mesa openssl zlib ]; meta = { description = "Open source clone of UFO: Enemy Unknown"; diff --git a/pkgs/games/quakespasm/vulkan.nix b/pkgs/games/quakespasm/vulkan.nix new file mode 100644 index 000000000000..675c2ab4b4d8 --- /dev/null +++ b/pkgs/games/quakespasm/vulkan.nix @@ -0,0 +1,47 @@ +{ stdenv, SDL2, fetchFromGitHub, makeWrapper, gzip, libvorbis, libmad, vulkan-loader }: +stdenv.mkDerivation rec { + name = "vkquake-${version}"; + majorVersion = "0.97"; + version = "${majorVersion}.3"; + + src = fetchFromGitHub { + owner = "Novum"; + repo = "vkQuake"; + rev = version; + sha256 = "11z9k5aw9ip7ggmgjdnaq4g45pxqiy0xhd4jqqmgzpmfdbjk4x13"; + }; + + sourceRoot = "source/Quake"; + + buildInputs = [ + makeWrapper gzip SDL2 libvorbis libmad vulkan-loader.dev + ]; + + preInstall = '' + mkdir -p "$out/bin" + ''; + + makeFlags = [ "prefix=$(out) bindir=$(out)/bin" ]; + + postFixup = '' + wrapProgram $out/bin/vkquake --prefix LD_LIBRARY_PATH : ${vulkan-loader}/lib + ''; + + enableParallelBuilding = true; + + meta = { + description = "Vulkan Quake port based on QuakeSpasm"; + homepage = src.meta.homepage; + longDescription = '' + vkQuake is a Quake 1 port using Vulkan instead of OpenGL for rendering. + It is based on the popular QuakeSpasm port and runs all mods compatible with it + like Arcane Dimensions or In The Shadows. vkQuake also serves as a Vulkan demo + application that shows basic usage of the API. For example it demonstrates render + passes & sub passes, pipeline barriers & synchronization, compute shaders, push & + specialization constants, CPU/GPU parallelism and memory pooling. + ''; + + platforms = stdenv.lib.platforms.linux; + maintainers = [ stdenv.lib.maintainers.gnidorah ]; + }; +} diff --git a/pkgs/games/rogue/default.nix b/pkgs/games/rogue/default.nix index b246a94715e4..05fd9ab523b6 100644 --- a/pkgs/games/rogue/default.nix +++ b/pkgs/games/rogue/default.nix @@ -5,7 +5,7 @@ stdenv.mkDerivation { src = fetchurl { urls = [ - "http://pkgs.fedoraproject.org/repo/pkgs/rogue/rogue5.4.4-src.tar.gz/033288f46444b06814c81ea69d96e075/rogue5.4.4-src.tar.gz" + "http://src.fedoraproject.org/repo/pkgs/rogue/rogue5.4.4-src.tar.gz/033288f46444b06814c81ea69d96e075/rogue5.4.4-src.tar.gz" "http://ftp.vim.org/ftp/pub/ftp/os/Linux/distr/slitaz/sources/packages-cooking/r/rogue5.4.4-src.tar.gz" "http://rogue.rogueforge.net/files/rogue5.4/rogue5.4.4-src.tar.gz" ]; diff --git a/pkgs/games/ultrastardx/default.nix b/pkgs/games/ultrastardx/default.nix index ce68f190992b..67991987c311 100644 --- a/pkgs/games/ultrastardx/default.nix +++ b/pkgs/games/ultrastardx/default.nix @@ -42,6 +42,6 @@ in stdenv.mkDerivation rec { homepage = http://ultrastardx.sourceforge.net/; description = "Free and open source karaoke game"; license = licenses.gpl2Plus; - maintainers = with maintainers; [ profpatsch ]; + maintainers = with maintainers; [ Profpatsch ]; }; } diff --git a/pkgs/games/zdoom/bcc-git.nix b/pkgs/games/zdoom/bcc-git.nix new file mode 100644 index 000000000000..2a1219e66ea0 --- /dev/null +++ b/pkgs/games/zdoom/bcc-git.nix @@ -0,0 +1,31 @@ +{ stdenv, fetchFromGitHub }: + +stdenv.mkDerivation { + name = "doom-bcc-git-0.8.0.2018.01.04"; + + src = fetchFromGitHub { + owner = "wormt"; + repo = "bcc"; + rev = "d58b44d9f18b28fd732c27113e5607a454506d19"; + sha256 = "1m83ip40ln61qrvb1fbgaqbld2xip9n3k817lwkk1936pml9zcrq"; + }; + + enableParallelBuilding = true; + makeFlags = ["CC=cc"]; + + patches = [ ./bcc-warning-fix.patch ]; + + installPhase = '' + mkdir -p $out/{bin,lib,share/doc} + install -m755 bcc $out/bin/bcc + cp -av doc $out/share/doc/bcc + cp -av lib $out/lib/bcc + ''; + + meta = with stdenv.lib; { + description = "Compiler for Doom/Hexen scripts (ACS, BCS)"; + homepage = https://github.com/wormt/bcc; + license = licenses.mit; + maintainers = with maintainers; [ertes]; + }; +} diff --git a/pkgs/games/zdoom/bcc-warning-fix.patch b/pkgs/games/zdoom/bcc-warning-fix.patch new file mode 100644 index 000000000000..4a352cb1e471 --- /dev/null +++ b/pkgs/games/zdoom/bcc-warning-fix.patch @@ -0,0 +1,25 @@ +From c6ac05c96b7908ccd35f3908fc0f13650b0583c0 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Ertugrul=20S=C3=B6ylemez?= <esz@posteo.de> +Date: Sat, 3 Feb 2018 17:08:54 +0100 +Subject: [PATCH] Remove -Werror + +--- + Makefile | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/Makefile b/Makefile +index bbe2c75..3357d2d 100644 +--- a/Makefile ++++ b/Makefile +@@ -4,7 +4,7 @@ EXE=bcc + BUILD_DIR=build + CC=gcc + INCLUDE=-Isrc -I src/parse +-OPTIONS=-Wall -Werror -Wno-unused -std=c99 -pedantic -Wstrict-aliasing \ ++OPTIONS=-Wall -Wno-unused -std=c99 -pedantic -Wstrict-aliasing \ + -Wstrict-aliasing=2 -Wmissing-field-initializers -D_BSD_SOURCE \ + -D_DEFAULT_SOURCE $(INCLUDE) + VERSION_FILE=$(BUILD_DIR)/version.c +-- +2.15.1 + |