aboutsummaryrefslogtreecommitdiff
path: root/pkgs/games/btanks
diff options
context:
space:
mode:
authorPeter Hoeg <peter@hoeg.com>2019-08-19 23:24:08 +0800
committerMatthieu Coudron <coudron@iij.ad.jp>2019-08-20 12:22:50 +0900
commit8b8f03682c4970076ad3eec5957507d680083a4c (patch)
tree4a1f47130b523193e86d6fa03324bfcc9c8a177e /pkgs/games/btanks
parent8ffb3cced1967f30baa4b8c7e7b4f8e84b6490f6 (diff)
btanks: fix building with lua 5.2
Diffstat (limited to 'pkgs/games/btanks')
-rw-r--r--pkgs/games/btanks/default.nix21
1 files changed, 12 insertions, 9 deletions
diff --git a/pkgs/games/btanks/default.nix b/pkgs/games/btanks/default.nix
index ad2cef1ac39a..5bb7cfa215bc 100644
--- a/pkgs/games/btanks/default.nix
+++ b/pkgs/games/btanks/default.nix
@@ -1,5 +1,5 @@
-{ stdenv, fetchurl, fetchpatch, sconsPackages, pkgconfig, SDL, libGLU_combined, zlib, smpeg
-, SDL_image, libvorbis, expat, zip, lua5_1 }:
+{ stdenv, fetchurl, fetchpatch, sconsPackages, pkgconfig, SDL, libGL, zlib, smpeg
+, SDL_image, libvorbis, expat, zip, lua }:
stdenv.mkDerivation rec {
pname = "btanks";
@@ -11,17 +11,20 @@ stdenv.mkDerivation rec {
};
nativeBuildInputs = [ sconsPackages.scons_3_0_1 pkgconfig ];
- buildInputs = [ SDL libGLU_combined zlib smpeg SDL_image libvorbis expat zip lua5_1 ];
- NIX_CFLAGS_COMPILE = "-I${SDL_image}/include/SDL";
+ buildInputs = [ SDL libGL zlib smpeg SDL_image libvorbis expat zip lua ];
+
+ enableParallelBuilding = true;
- prePatch = ''
- substituteInPlace ./engine/SConscript --replace "lua5.1" "lua" \
- --replace "lua5.0" "lua"
- '';
+ NIX_CFLAGS_COMPILE = "-I${SDL_image}/include/SDL";
patches = [
(fetchpatch {
+ url = "https://aur.archlinux.org/cgit/aur.git/plain/lua52.patch?h=btanks";
+ sha256 = "0ip563kz6lhwiims5djrxq3mvb7jx9yzkpsqxxhbi9n6qzz7y2az";
+ name = "lua52.patch";
+ })
+ (fetchpatch {
url = "https://salsa.debian.org/games-team/btanks/raw/master/debian/patches/gcc-4.7.patch";
sha256 = "1dxlk1xh69gj10sqcsyckiakb8an3h41206wby4z44mpmvxc7pi4";
})
@@ -32,8 +35,8 @@ stdenv.mkDerivation rec {
];
meta = with stdenv.lib; {
- homepage = "https://sourceforge.net/projects/btanks/";
description = "Fast 2d tank arcade game";
+ homepage = "https://sourceforge.net/projects/btanks/";
license = licenses.gpl2Plus;
platforms = platforms.linux;
};