git.iko.soy/typeable/nixpkgs
on master help sign in
dxx-rebirth: fix compilation with gcc7
commit2e2063074d8445efdbddbb732441d2ea490d0572 authorPeter Hoeg <peter@hoeg.com> dateWed 7 Mar 2018, 11:56 (9 years ago) parentdc1e064
1 file changed+24−2
pkgs/games/dxx-rebirth/default.nix+24−2
pkgs/games/dxx-rebirth/default.nix+24−2
@@ -1,4 +1,4 @@
1−{ stdenv, fetchurl, scons, pkgconfig
1+{ stdenv, fetchurl, fetchpatch, scons, pkgconfig
22, SDL, SDL_mixer, libGLU_combined, physfs
33}:
44
@@ -17,12 +17,34 @@ in stdenv.mkDerivation rec {
1717 sha256 = "0m9k34zyr8bbni9szip407mffdpwbqszgfggavgqjwq0k9c1w7ka";
1818 };
1919
20+ # TODO: drop these when upgrading to version > 0.59.100
21+ patches = [
22+ (fetchpatch {
23+ name = "dxx-gcc7-fix1.patch";
24+ url = "https://github.com/dxx-rebirth/dxx-rebirth/commit/1ed7cec714c623758e3418ec69eaf3b3ff03e9f6.patch";
25+ sha256 = "026pn8xglmxryaj8555h5rhzkx30lxmksja1fzdlfyb1vll75gq0";
26+ })
27+ (fetchpatch {
28+ name = "dxx-gcc7-fix2.patch";
29+ url = "https://github.com/dxx-rebirth/dxx-rebirth/commit/73057ad8ec6977ac747637db1080686f11b4c3cc.patch";
30+ sha256 = "0s506vdd2djrrm3xl0ygn9ylpg6y8qxii2nnzk3sf9133glp3swy";
31+ })
32+ ];
33+
2034 nativeBuildInputs = [ pkgconfig scons ];
2135
2236 buildInputs = [ libGLU_combined physfs SDL SDL_mixer ];
2337
2438 enableParallelBuilding = true;
2539
40+ buildPhase = ''
41+ runHook preBuild
42+
43+ scons prefix=$out
44+
45+ runHook postBuild
46+ '';
47+
2648 installPhase = ''
2749 runHook preInstall
2850
@@ -37,7 +59,7 @@ in stdenv.mkDerivation rec {
3759 description = "Source Port of the Descent 1 and 2 engines";
3860 homepage = http://www.dxx-rebirth.com/;
3961 license = licenses.free;
40− maintainers = with maintainers; [ viric ];
62+ maintainers = with maintainers; [ viric peterhoeg ];
4163 platforms = with platforms; linux;
4264 };
4365}