2021-01-15 05:31:39 +01:00
|
|
|
{ fetchurl, lib, stdenv, allegro, libjpeg, makeWrapper }:
|
2011-03-26 00:33:09 +01:00
|
|
|
|
2019-08-13 23:52:01 +02:00
|
|
|
stdenv.mkDerivation {
|
2011-03-26 00:33:09 +01:00
|
|
|
name = "racer-1.1";
|
|
|
|
|
2018-08-20 21:11:29 +02:00
|
|
|
src = if stdenv.hostPlatform.system == "i686-linux" then fetchurl {
|
2020-04-01 03:11:51 +02:00
|
|
|
url = "http://hippo.nipax.cz/src/racer-1.1.tar.gz";
|
2011-03-26 00:33:09 +01:00
|
|
|
sha256 = "0fll1qkqfcjq87k0jzsilcw701z92lfxn2y5ga1n038772lymxl9";
|
2018-08-20 21:11:29 +02:00
|
|
|
} else if stdenv.hostPlatform.system == "x86_64-linux" then fetchurl {
|
2020-04-01 03:11:51 +02:00
|
|
|
url = "https://hippo.nipax.cz/src/racer-1.1.64.tar.gz";
|
2011-03-26 00:37:44 +01:00
|
|
|
sha256 = "0rjy3gmlhwfkb9zs58j0mc0dar0livwpbc19r6zw5r2k6r7xdan0";
|
|
|
|
} else
|
|
|
|
throw "System not supported";
|
|
|
|
|
2021-02-07 10:17:39 +01:00
|
|
|
nativeBuildInputs = [ makeWrapper ];
|
|
|
|
buildInputs = [ allegro libjpeg ];
|
2011-03-26 00:33:09 +01:00
|
|
|
|
|
|
|
prePatch = ''
|
|
|
|
sed -i s,/usr/local,$out, Makefile src/HGFX.cpp src/STDH.cpp
|
|
|
|
sed -i s,/usr/share,$out/share, src/HGFX.cpp src/STDH.cpp
|
|
|
|
'';
|
|
|
|
|
|
|
|
patches = [ ./mkdir.patch ];
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "Car racing game";
|
2020-04-01 03:11:51 +02:00
|
|
|
homepage = "http://hippo.nipax.cz/download.en.php";
|
2021-01-15 05:31:39 +01:00
|
|
|
license = lib.licenses.gpl2Plus;
|
|
|
|
platforms = lib.platforms.linux;
|
2011-03-26 00:33:09 +01:00
|
|
|
};
|
|
|
|
}
|