From 6f7cb59e04d4b75a6799d8c82bc4ad8ef7331a9f Mon Sep 17 00:00:00 2001 From: LluĂ­s Batlle i Rossell Date: Fri, 24 Feb 2012 22:56:53 +0000 Subject: Making rigs of rods build and run right away. Simpyl run 'rorconfig' first, and 'RoR' then. On linux, disable Caleum rendering. It does not work. Known bug upstream. svn path=/nixpkgs/trunk/; revision=32553 --- pkgs/games/rigsofrods/default.nix | 27 ++++++++------------------- pkgs/games/rigsofrods/paths.patch | 12 ++++++++++++ 2 files changed, 20 insertions(+), 19 deletions(-) create mode 100644 pkgs/games/rigsofrods/paths.patch (limited to 'pkgs/games/rigsofrods') diff --git a/pkgs/games/rigsofrods/default.nix b/pkgs/games/rigsofrods/default.nix index 13d6159528a..480481afe9a 100644 --- a/pkgs/games/rigsofrods/default.nix +++ b/pkgs/games/rigsofrods/default.nix @@ -1,5 +1,5 @@ { fetchsvn, fetchurl, stdenv, wxGTK290, freeimage, cmake, zziplib, mesa, boost, - pkgconfig, libuuid, lua5, openal, ogre, ois, curl, gtk, pixman, mygui, unzip, + pkgconfig, libuuid, openal, ogre, ois, curl, gtk, pixman, mygui, unzip, angelscript, caelum, ogrepaged, mysocketw, libxcb }: @@ -20,7 +20,6 @@ stdenv.mkDerivation rec { enableParallelBuilding = true; cmakeFlags = [ - # "-DROR_USE_LUA=TRUE" "-DLUA_LIBRARIES=${lua5}/lib/liblua.a" "-DROR_USE_CURL=TRUE" "-DROR_USE_MYGUI=TRUE" "-DROR_USE_OPNEAL=TRUE" @@ -29,34 +28,24 @@ stdenv.mkDerivation rec { "-DROR_USE_ANGELSCRIPT=TRUE" "-DROR_USE_SOCKETW=TRUE" ]; - makeFlags = "VERBOSE=1"; installPhase = '' sed -e "s@/usr/local/lib/OGRE@${ogre}/lib/OGRE@" -i ../tools/linux/binaries/plugins.cfg ensureDir $out/share/rigsofrods - cp -r .. $out/share/rigsofrods/build-dir - cp ../tools/linux/binaries/plugins.cfg $out/share/rigsofrods/build-dir/bin + cp -r ../bin/* $out/share/rigsofrods + cp ../tools/linux/binaries/plugins.cfg $out/share/rigsofrods ensureDir $out/bin - ln -s $out/share/rigsofrods/build-dir/bin/{RoR,rorconfig} $out/bin + ln -s $out/share/rigsofrods/{RoR,rorconfig} $out/bin cd $out/share/rigsofrods - mkdir contentpack - cd contentpack + mkdir packs + cd packs unzip "${contentPackSrc}" - - echo First run rorconfig once to create ~/.rigsofrods - echo Then copy $out/share/rigsofrods/build-dir/bin/plugins.cfg to ~/.rigsofrods - echo Then ln $out/share/rigsofrods/contentpack/* to ~/.rigsofrods/packs ''; - patches = [ ./doubleslash.patch ]; - - preConfigure = '' - export NIX_LDFLAGS="$NIX_LDFLAGS -langelscript -lgtk-x11-2.0" - sed -e 's@wxLOCALE_CONV_ENCODING@0@g' -i source/configurator/configurator.cpp - ''; + patches = [ ./doubleslash.patch ./paths.patch ]; buildInputs = [ wxGTK290 freeimage cmake zziplib mesa boost pkgconfig - libuuid lua5 openal ogre ois curl gtk mygui unzip angelscript + libuuid openal ogre ois curl gtk mygui unzip angelscript caelum ogrepaged mysocketw libxcb ]; meta = { diff --git a/pkgs/games/rigsofrods/paths.patch b/pkgs/games/rigsofrods/paths.patch new file mode 100644 index 00000000000..e20b00a7693 --- /dev/null +++ b/pkgs/games/rigsofrods/paths.patch @@ -0,0 +1,12 @@ +diff --git a/source/main/framework/ContentManager.cpp b/source/main/framework/ContentManager.cpp +index 0bfea8c..82cdab9 100644 +--- a/source/main/framework/ContentManager.cpp ++++ b/source/main/framework/ContentManager.cpp +@@ -238,6 +238,7 @@ bool ContentManager::init(void) + #endif // USE_OPENAL + + // and the content ++ ResourceGroupManager::getSingleton().addResourceLocation(SSETTING("Program Path")+"packs", "FileSystem", "Packs", true); + ResourceGroupManager::getSingleton().addResourceLocation(SSETTING("User Path")+"packs", "FileSystem", "Packs", true); + ResourceGroupManager::getSingleton().addResourceLocation(SSETTING("User Path")+"mods", "FileSystem", "Packs", true); + -- cgit 1.4.1