From de1d8091daa2ba4acf33f0872de168aece643b40 Mon Sep 17 00:00:00 2001 From: hacker1024 Date: Mon, 23 Oct 2023 04:56:32 +1100 Subject: [PATCH] flutter: Update FLUTTER_ROOT in SDK symlink derivation --- pkgs/development/compilers/flutter/sdk-symlink.nix | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/pkgs/development/compilers/flutter/sdk-symlink.nix b/pkgs/development/compilers/flutter/sdk-symlink.nix index 6fb4f5edc0ee..c4e3cea5d597 100644 --- a/pkgs/development/compilers/flutter/sdk-symlink.nix +++ b/pkgs/development/compilers/flutter/sdk-symlink.nix @@ -1,4 +1,6 @@ -{ symlinkJoin }: flutter: +{ symlinkJoin +, makeWrapper +}: flutter: let self = @@ -6,6 +8,12 @@ let name = "${flutter.name}-sdk-links"; paths = [ flutter flutter.sdk ]; + nativeBuildInputs = [ makeWrapper ]; + postBuild = '' + wrapProgram "$out/bin/flutter" \ + --set-default FLUTTER_ROOT "$out" + ''; + passthru = flutter.passthru // { # Update the SDK attribute. # This allows any modified SDK files to be included