From 1cfa81335172fff5f06e6b06664ff261c332fce1 Mon Sep 17 00:00:00 2001 From: Colin Date: Tue, 7 Oct 2025 05:09:05 +0000 Subject: [PATCH] superTuxKart: fix build against cmake 4 --- pkgs/by-name/su/superTuxKart/package.nix | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/pkgs/by-name/su/superTuxKart/package.nix b/pkgs/by-name/su/superTuxKart/package.nix index 7d6763bde477..5b4cf6f8f577 100644 --- a/pkgs/by-name/su/superTuxKart/package.nix +++ b/pkgs/by-name/su/superTuxKart/package.nix @@ -3,6 +3,7 @@ stdenv, fetchFromGitHub, fetchsvn, + fetchpatch, cmake, pkg-config, makeWrapper, @@ -76,6 +77,20 @@ stdenv.mkDerivation rec { hash = "sha256-gqdaVvgNfCN40ZO/9y8+vTeIJPSq6udKxYZ/MAi4ZMM="; }; + patches = [ + # upstreamed patches required to build against cmake 4.0; remove with next release update. + (fetchpatch { + name = "Require-Cmake-3.6-or-higher"; + url = "https://github.com/supertuxkart/stk-code/commit/7d4e8433c124c08c62f5335e2a884aeea71cf184.patch?full_index=1"; + hash = "sha256-5q/Gf1I/maFPQ83NDIa7Sn6gtLfErwxP16fup4SZ+gc="; + }) + (fetchpatch { + name = "Fixed-cmake-4.0-warnings"; + url = "https://github.com/supertuxkart/stk-code/commit/184c80138faf5232c33ff99ffe7706e821be70c2.patch?full_index=1"; + hash = "sha256-5zoDmKBRBC2rAUjgpmyc0ZCObGofjuImqk07Tr5K7Og="; + }) + ]; + postPatch = '' # Deletes all bundled libs in stk-code/lib except those # That couldn't be replaced with system packages