From f61bd4942a1c6336b8e520fd9f00b8bb2199fa82 Mon Sep 17 00:00:00 2001 From: Stefan Frijters Date: Thu, 19 Feb 2026 01:15:39 +0100 Subject: [PATCH] godot*: move env variable to env for structuredAttrs --- pkgs/development/tools/godot/common.nix | 31 +++++++++++++------------ 1 file changed, 16 insertions(+), 15 deletions(-) diff --git a/pkgs/development/tools/godot/common.nix b/pkgs/development/tools/godot/common.nix index 48eeca61fa6a..54ca97581bef 100644 --- a/pkgs/development/tools/godot/common.nix +++ b/pkgs/development/tools/godot/common.nix @@ -373,14 +373,22 @@ let ++ lib.optional editor "man"; separateDebugInfo = true; - # Set the build name which is part of the version. In official downloads, this - # is set to 'official'. When not specified explicitly, it is set to - # 'custom_build'. Other platforms packaging Godot (Gentoo, Arch, Flatpack - # etc.) usually set this to their name as well. - # - # See also 'methods.py' in the Godot repo and 'build' in - # https://docs.godotengine.org/en/stable/classes/class_engine.html#class-engine-method-get-version-info - BUILD_NAME = "nixpkgs"; + env = { + # Set the build name which is part of the version. In official downloads, this + # is set to 'official'. When not specified explicitly, it is set to + # 'custom_build'. Other platforms packaging Godot (Gentoo, Arch, Flatpack + # etc.) usually set this to their name as well. + # + # See also 'methods.py' in the Godot repo and 'build' in + # https://docs.godotengine.org/en/stable/classes/class_engine.html#class-engine-method-get-version-info + BUILD_NAME = "nixpkgs"; + } + // lib.optionalAttrs stdenv.hostPlatform.isDarwin { + NIX_CFLAGS_COMPILE = toString [ + "-I${lib.getDev harfbuzz-icu}/include/harfbuzz" + "-I${lib.getDev recastnavigation}/include/recastnavigation" + ]; + }; preConfigure = lib.optionalString (editor && withMono) '' # TODO: avoid pulling in dependencies of windows-only project @@ -552,13 +560,6 @@ let pkg-config ]; - env.NIX_CFLAGS_COMPILE = toString ( - lib.optionals stdenv.hostPlatform.isDarwin [ - "-I${lib.getDev harfbuzz-icu}/include/harfbuzz" - "-I${lib.getDev recastnavigation}/include/recastnavigation" - ] - ); - buildInputs = lib.optionals (!withBuiltins) ( [