Skip to content

Commit

Permalink
warzone2100: 2.1.5 -> 2.2.2
Browse files Browse the repository at this point in the history
  • Loading branch information
abbradar committed Jan 7, 2017
1 parent 7e3ed8b commit 6a55b52
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 16 deletions.
31 changes: 16 additions & 15 deletions pkgs/games/warzone2100/default.nix
@@ -1,7 +1,5 @@
{ stdenv, fetchurl, bison, flex, gettext, pkgconfig, libpng
, libtheora, openal, physfs, mesa, fribidi, fontconfig
, freetype, qt4, glew, libogg, libvorbis, zlib, libX11
, libXrandr, zip, unzip, which, perl
{ stdenv, lib, fetchurl, perl, unzip, zip, which, pkgconfig
, qtbase, qtscript, SDL2, libtheora, openal, glew, physfs, fribidi
, withVideos ? false
}:

Expand All @@ -14,28 +12,31 @@ let
in

stdenv.mkDerivation rec {
version = "3.1.5";
version = "3.2.2";
name = "${pname}-${version}";

src = fetchurl {
url = "mirror://sourceforge/${pname}/releases/${version}/${name}.tar.xz";
sha256 = "0hm49i2knvvg3wlnryv7h4m84s3qa7jfyym5yy6365sx8wzcrai1";
sha256 = "064xfxwkqpvqyy7kz46cwi71mxmimxi4wgjly9g51wwxkvz8snmg";
};
buildInputs = [ bison flex gettext pkgconfig libpng libtheora openal
physfs mesa fribidi fontconfig freetype qt4
glew libogg libvorbis zlib libX11 libXrandr zip
unzip perl
];
patchPhase = ''

buildInputs = [ qtbase qtscript SDL2 libtheora openal glew physfs fribidi ];
nativeBuildInputs = [ perl zip unzip pkgconfig ];

postPatch = ''
substituteInPlace lib/exceptionhandler/dumpinfo.cpp \
--replace "which %s" "${which}/bin/which %s"
substituteInPlace lib/exceptionhandler/exceptionhandler.cpp \
--replace "which %s" "${which}/bin/which %s"
'';
configureFlags = "--with-backend=qt --with-distributor=NixOS";

NIX_CFLAGS_COMPILE = "-fpermissive"; # GL header minor incompatibility
configureFlags = [ "--with-distributor=NixOS" ];

hardeningDisable = [ "format" ];

enableParallelBuilding = true;

postInstall = stdenv.lib.optionalString withVideos "cp ${sequences_src} $out/share/warzone2100/sequences.wz";
postInstall = lib.optionalString withVideos "cp ${sequences_src} $out/share/warzone2100/sequences.wz";

meta = with stdenv.lib; {
description = "A free RTS game, originally developed by Pumpkin Studios";
Expand Down
2 changes: 1 addition & 1 deletion pkgs/top-level/all-packages.nix
Expand Up @@ -16338,7 +16338,7 @@ in
libjpeg = libjpeg62;
};

warzone2100 = callPackage ../games/warzone2100 { };
warzone2100 = qt5.callPackage ../games/warzone2100 { };

wesnoth = callPackage ../games/wesnoth { };

Expand Down

0 comments on commit 6a55b52

Please sign in to comment.