summary refs log tree commit diff
path: root/pkgs/games/ultrastardx
diff options
context:
space:
mode:
authorTimo Kaufmann <timokau@zoho.com>2020-09-03 12:49:11 +0200
committerTimo Kaufmann <timokau@zoho.com>2020-09-03 14:52:18 +0200
commitf928b91f349403090d055a613abc527bb442254e (patch)
tree5441b118d7369c63139bf551a8645afe57dd22d5 /pkgs/games/ultrastardx
parent596de92ca7458e47b991472e3da59d30baf8d9c5 (diff)
downloadnixpkgs-f928b91f349403090d055a613abc527bb442254e.tar
nixpkgs-f928b91f349403090d055a613abc527bb442254e.tar.gz
nixpkgs-f928b91f349403090d055a613abc527bb442254e.tar.bz2
nixpkgs-f928b91f349403090d055a613abc527bb442254e.tar.lz
nixpkgs-f928b91f349403090d055a613abc527bb442254e.tar.xz
nixpkgs-f928b91f349403090d055a613abc527bb442254e.tar.zst
nixpkgs-f928b91f349403090d055a613abc527bb442254e.zip
fpc: 3.0.4 -> 3.2.0
There was no 3.1 for some reason. The old sed-based path patching was
broken and resulted in syntax errors since it was a bit over-eager.
Instead of fixing it, I decided to replace it with a patch file which is
easier to inspect and will fail in a more obvious way next time.

The patch is now applied unconditionally, since it actually applies to
all linux platforms. The changes are localized to linux-specific code,
so it does not hurt to apply it on non-linux platforms as well.

Hedgewars needs a small fix to work with the new version. Done in the
same commit to avoid a broken commit.
Diffstat (limited to 'pkgs/games/ultrastardx')
-rw-r--r--pkgs/games/ultrastardx/default.nix35
1 files changed, 31 insertions, 4 deletions
diff --git a/pkgs/games/ultrastardx/default.nix b/pkgs/games/ultrastardx/default.nix
index 7c5f4949d94..b6e1da204ed 100644
--- a/pkgs/games/ultrastardx/default.nix
+++ b/pkgs/games/ultrastardx/default.nix
@@ -1,7 +1,26 @@
-{ stdenv, autoreconfHook, fetchFromGitHub, pkgconfig
-, lua, fpc, pcre, portaudio, freetype, libpng
-, SDL2, SDL2_image, SDL2_gfx, SDL2_mixer, SDL2_net, SDL2_ttf
-, ffmpeg, sqlite, zlib, libX11, libGLU, libGL }:
+{ stdenv
+, autoreconfHook
+, fetchFromGitHub
+, fetchpatch
+, pkgconfig
+, lua
+, fpc
+, pcre
+, portaudio
+, freetype
+, libpng
+, SDL2
+, SDL2_image
+, SDL2_gfx
+, SDL2_mixer
+, SDL2_net, SDL2_ttf
+, ffmpeg
+, sqlite
+, zlib
+, libX11
+, libGLU
+, libGL
+}:
 
 let
   sharedLibs = [
@@ -23,6 +42,14 @@ in stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig autoreconfHook ];
   buildInputs = [ fpc libpng ] ++ sharedLibs;
 
+  patches = [
+    (fetchpatch {
+      name = "fpc-3.2-support.patch";
+      url = "https://github.com/UltraStar-Deluxe/USDX/commit/1b8e8714c1523ef49c2fd689a1545d097a3d76d7.patch";
+      sha256 = "02zmjymj9w1mkpf7armdpf067byvml6lprs1ca4lhpkv45abddp4";
+    })
+  ];
+
   postPatch = ''
     substituteInPlace src/config.inc.in \
       --subst-var-by libpcre_LIBNAME libpcre.so.1