From 9e7181bcbbddce581c37a0ad0f88bb50acdf50b7 Mon Sep 17 00:00:00 2001 From: Sergei Trofimovich Date: Mon, 23 Dec 2024 16:09:10 +0000 Subject: [PATCH] gltron: fix the build against gcc-14 Without the change `gltron` fails to build as: ./src/gltron.c: In function 'main': ./src/gltron.c:13:30: error: passing argument 2 of 'initSubsystems' from incompatible pointer type [-Wincompatible-pointer-types] 13 | initSubsystems(argc, argv); | ^~~~ | | | char ** --- pkgs/by-name/gl/gltron/package.nix | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/pkgs/by-name/gl/gltron/package.nix b/pkgs/by-name/gl/gltron/package.nix index c09c8d7e460c..39ecaceb7c9e 100644 --- a/pkgs/by-name/gl/gltron/package.nix +++ b/pkgs/by-name/gl/gltron/package.nix @@ -20,7 +20,16 @@ stdenv.mkDerivation rec { sha256 = "e0c8ebb41a18a1f8d7302a9c2cb466f5b1dd63e9a9966c769075e6b6bdad8bb0"; }; - patches = [ ./gentoo-prototypes.patch ]; + patches = [ + ./gentoo-prototypes.patch + + # gcc-14 build fix: https://sourceforge.net/p/gltron/patches/7/ + (fetchurl { + name = "gcc-14.patch"; + url = "https://sourceforge.net/p/gltron/patches/7/attachment/gcc-14.patch"; + hash = "sha256-OJAUAM/OQVwxYnIacBkncNxMLn/HDCoysbi+Txe+DC8="; + }) + ]; postPatch = '' # Fix https://sourceforge.net/p/gltron/bugs/15