games/warsow: Updated to 1.0.

This commit is contained in:
Александр Цамутали 2012-09-24 02:27:34 +04:00
parent 48395bd3e4
commit 400db72f1d

View File

@ -1,32 +1,33 @@
{ stdenv, fetchurl, unzip, pkgconfig, zlib, curl, libjpeg, libvorbis { stdenv, fetchurl, unzip, pkgconfig, zlib, curl, libjpeg, libpng, libvorbis
, libXxf86dga, libXxf86vm, libXinerama, SDL, mesa, openal , libtheora, libXxf86dga, libXxf86vm, libXinerama, SDL, mesa, openal
}: }:
stdenv.mkDerivation rec { stdenv.mkDerivation rec {
name = "warsow-${version}"; name = "warsow-${version}";
version = "0.62"; version = "1.0";
mversion = "0.61"; # sometimes only engine is updated mversion = "1.0"; # sometimes only engine is updated
src1 = fetchurl { src1 = fetchurl {
url = "http://www.zcdn.org/dl/warsow_${version}_sdk.zip"; url = "http://www.warsow.net/download?dl=sdk";
sha256 = "0nb1z55lzmwarnn71dcyg9b3k7r7wxagqxks8a7rnlq7acsnra71"; name = "warsow_${version}_sdk.tar.gz";
sha256 = "08hfhx3ggb8v8lsb62ki5rhdhscg8j9sndlnllinf85da1f4nf9f";
}; };
src2 = fetchurl { src2 = fetchurl {
url = "http://www.zcdn.org/dl/warsow_${mversion}_unified.zip"; url = "http://www.warsow.net/download?dl=linux";
sha256 = "1b5bv4dsly7i7c4fqlkckv4da1knxl9m3kg8nlgkgr8waczgvazv"; name = "warsow_${mversion}_unified.tar.gz";
sha256 = "1v455v4lpqda7lf2yviasdrlibvb6bsyxcadgl8bd4jcvr8x4czr";
}; };
unpackPhase = '' unpackPhase = ''
mkdir warsow_${version}_sdk tar xf "$src1"
cd warsow_${version}_sdk cd warsow_${version}_sdk
unzip $src1 tar xf "$src2"
unzip $src2
mkdir -p source/release/ mkdir -p source/release/
mv warsow_${mversion}_unified/basewsw source/release/ mv warsow_${mversion}/basewsw source/release/
cd source cd source
''; '';
patchPhase = '' patchPhase = ''
substituteInPlace snd_openal/snd_main.c --replace libopenal.so.1 ${openal}/lib/libopenal.so.1 substituteInPlace snd_openal/snd_main.c --replace libopenal.so.1 ${openal}/lib/libopenal.so.1
''; '';
buildInputs = [ unzip pkgconfig zlib curl libjpeg libvorbis libXxf86dga buildInputs = [ unzip pkgconfig zlib curl libjpeg libpng libvorbis libtheora
libXxf86vm libXinerama SDL mesa openal ]; libXxf86dga libXxf86vm libXinerama SDL mesa openal ];
installPhase = '' installPhase = ''
dest=$out/opt/warsow dest=$out/opt/warsow
cd release cd release