diff --git a/pkgs/by-name/mu/mupdf/package.nix b/pkgs/by-name/mu/mupdf/package.nix index cd1bea612afa..492322fd7f9b 100644 --- a/pkgs/by-name/mu/mupdf/package.nix +++ b/pkgs/by-name/mu/mupdf/package.nix @@ -55,7 +55,15 @@ let hash = "sha256-0fuE0lm9rlAaok2Qe0V1uUrgP4AjMWgp3eTbw8G6PMM="; }; - patches = [ ]; + patches = [ + # Fix build with gcc15 + # https://github.com/freeglut/freeglut/pull/187 + (fetchpatch { + name = "freeglut-fix-fgPlatformDestroyContext-prototype-for-C23.patch"; + url = "https://github.com/freeglut/freeglut/commit/800772e993a3ceffa01ccf3fca449d3279cde338.patch"; + hash = "sha256-agXw3JHq81tx5514kkorvuU5mX4E3AV930hy1OJl4L0="; + }) + ]; # cmake 4 compatibility, upstream is dead postPatch = ''