From 664464a5dd9e603944943543506e16a0d80349aa Mon Sep 17 00:00:00 2001 From: Sergei Trofimovich Date: Sun, 26 Jan 2025 22:22:45 +0000 Subject: [PATCH] libburn: backport upstream C23 fix Without the change the build against c23 compiler (like `gcc-15`) fails as: libburn> test/poll.c: In function 'main': libburn> test/poll.c:67:27: error: assignment to '__sighandler_t' {aka 'void (*)(int)'} from incompatible pointer type 'void (*)(void)' [] libburn> 67 | newact.sa_handler = catch_int; libburn> | ^ --- pkgs/by-name/li/libburn/package.nix | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/pkgs/by-name/li/libburn/package.nix b/pkgs/by-name/li/libburn/package.nix index 4f3e60bf90ce..4d4901901ac5 100644 --- a/pkgs/by-name/li/libburn/package.nix +++ b/pkgs/by-name/li/libburn/package.nix @@ -2,6 +2,7 @@ lib, stdenv, fetchFromGitea, + fetchpatch, autoreconfHook, pkg-config, }: @@ -18,6 +19,15 @@ stdenv.mkDerivation (finalAttrs: { hash = "sha256-Xo45X4374FXvlrJ4Q0PahYvuWXO0k3N0ke0mbURYt54="; }; + patches = [ + # Fix the build against C23 compilers (like gcc-15): + (fetchpatch { + name = "c23.patch"; + url = "https://dev.lovelyhq.com/libburnia/libburn/commit/d537f9dd35282df834a311ead5f113af67d223b3.patch"; + hash = "sha256-aouU/6AchLhzMzvkVvUnFHWfebYTrkEJ6P3fF5pvE9M="; + }) + ]; + nativeBuildInputs = [ autoreconfHook pkg-config