summary refs log tree commit diff
path: root/pkgs/games/torcs
diff options
context:
space:
mode:
authorrushmorem <rushmore@webenchanter.com>2016-09-30 13:45:04 +0200
committerrushmorem <rushmore@webenchanter.com>2016-09-30 13:58:13 +0200
commitd332b914ce02ebccb3273f4e80aecf95472e6bd4 (patch)
tree72e9f69fa5b3ba7c14c723de5ba2fa959b30274b /pkgs/games/torcs
parent73dd89205c8b4936b78f2ab402240fa65f709cbb (diff)
downloadnixpkgs-d332b914ce02ebccb3273f4e80aecf95472e6bd4.tar
nixpkgs-d332b914ce02ebccb3273f4e80aecf95472e6bd4.tar.gz
nixpkgs-d332b914ce02ebccb3273f4e80aecf95472e6bd4.tar.bz2
nixpkgs-d332b914ce02ebccb3273f4e80aecf95472e6bd4.tar.lz
nixpkgs-d332b914ce02ebccb3273f4e80aecf95472e6bd4.tar.xz
nixpkgs-d332b914ce02ebccb3273f4e80aecf95472e6bd4.tar.zst
nixpkgs-d332b914ce02ebccb3273f4e80aecf95472e6bd4.zip
torcs: 1.3.5 -> 1.3.7
This change also wraps `torcs` with `mesa` to fix the runtime
crush due to this dependancy which was missing.
Diffstat (limited to 'pkgs/games/torcs')
-rw-r--r--pkgs/games/torcs/default.nix13
1 files changed, 9 insertions, 4 deletions
diff --git a/pkgs/games/torcs/default.nix b/pkgs/games/torcs/default.nix
index 1b1e877d274..1ea94a5d2ce 100644
--- a/pkgs/games/torcs/default.nix
+++ b/pkgs/games/torcs/default.nix
@@ -1,13 +1,13 @@
 { fetchurl, stdenv, mesa, freeglut, libX11, plib, openal, freealut, libXrandr, xproto,
 libXext, libSM, libICE, libXi, libXt, libXrender, libXxf86vm, libvorbis,
-libpng, zlib, bash }:
+libpng, zlib, bash, makeWrapper }:
 
 stdenv.mkDerivation rec {
-  name = "torcs-1.3.5";
+  name = "torcs-1.3.7";
 
   src = fetchurl {
     url = "mirror://sourceforge/torcs/${name}.tar.bz2";
-    sha256 = "170ff98smkkv1sk4nbz9w0alhmmbr32djmgbc08lcfhf0lj2ni38";
+    sha256 = "0kdq0sc7dsfzlr0ggbxggcbkivc6yp30nqwjwcaxg9295s3b06wa";
   };
 
   patchPhase = ''
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   '';
 
   buildInputs = [ mesa freeglut libX11 plib openal freealut libXrandr xproto
-    libXext libSM libICE libXi libXt libXrender libXxf86vm libpng zlib libvorbis ];
+    libXext libSM libICE libXi libXt libXrender libXxf86vm libpng zlib libvorbis makeWrapper ];
 
   nativeBuildInputs = [ bash ];
 
@@ -23,6 +23,11 @@ stdenv.mkDerivation rec {
 
   hardeningDisable = [ "format" ];
 
+  postInstall = ''
+    wrapProgram $out/bin/torcs \
+      --prefix LD_LIBRARY_PATH : ${mesa}/lib
+  '';
+
   meta = {
     description = "Car racing game";
     homepage = http://torcs.sourceforge.net/;