From 6aae2245d2d657f8cf024c461c0ba56acfd0efcd Mon Sep 17 00:00:00 2001 From: ghpzin Date: Sat, 20 Sep 2025 20:06:37 +0300 Subject: [PATCH] mesa: fix build with gcc15 - remove `rustPlatform.bindgenHook` from `buildInputs`, `rustPlatform.bindgenHook` adds gcc headers to `BINDGEN_EXTRA_CLANG_ARGS` which somehow conflict more with gcc15 than gcc14. Removing hook should let meson use bindgen from cli with clang libraries. Fixes bindgen error building `mesa` with gcc15: ``` FAILED: [code=1] src/nouveau/compiler/nak_bindings.rs /nix/store/rm899xgm82kanr814dk8siwyghyxwphg-rust-bindgen-0.72.0/bin/bindgen ../src/nouveau/compiler/nak_bindings.h ... /build/source/src/nouveau/winsys/./nouveau_bo.h:41:4: error: unknown type name 'atomic_uint_fast32_t' Unable to generate bindings: clang diagnosed error: /build/source/src/nouveau/winsys/./nouveau_bo.h:41:4: error: unknown type name 'atomic_uint_fast32_t' ``` --- pkgs/development/libraries/mesa/default.nix | 2 -- 1 file changed, 2 deletions(-) diff --git a/pkgs/development/libraries/mesa/default.nix b/pkgs/development/libraries/mesa/default.nix index 31e15d8242a3..7c0fc1abfb5d 100644 --- a/pkgs/development/libraries/mesa/default.nix +++ b/pkgs/development/libraries/mesa/default.nix @@ -29,7 +29,6 @@ runCommand, rust-bindgen, rust-cbindgen, - rustPlatform, rustc, spirv-llvm-translator, stdenv, @@ -314,7 +313,6 @@ stdenv.mkDerivation { rustc rust-bindgen rust-cbindgen - rustPlatform.bindgenHook wayland-scanner ] ++ lib.optionals needNativeCLC [