flutter: 3.7.12 -> 3.10.0

This commit is contained in:
hacker1024 2023-05-12 02:17:28 +10:00
parent 49ce83d5b4
commit 7f36f6e96b
3 changed files with 83 additions and 81 deletions

View File

@ -6,43 +6,46 @@ let
let files = builtins.attrNames (builtins.readDir dir);
in map (f: dir + ("/" + f)) files;
mkFlutter = { version, engineVersion, dartVersion, hash, dartHash, patches }:
let args = {
inherit version engineVersion patches;
let
args = {
inherit version engineVersion patches;
dart = dart.override {
version = dartVersion;
sources = {
"${dartVersion}-x86_64-linux" = fetchzip {
url = "https://storage.googleapis.com/dart-archive/channels/stable/release/${dartVersion}/sdk/dartsdk-linux-x64-release.zip";
sha256 = dartHash.x86_64-linux;
};
"${dartVersion}-aarch64-linux" = fetchzip {
url = "https://storage.googleapis.com/dart-archive/channels/stable/release/${dartVersion}/sdk/dartsdk-linux-arm64-release.zip";
sha256 = dartHash.aarch64-linux;
dart = dart.override {
version = dartVersion;
sources = {
"${dartVersion}-x86_64-linux" = fetchzip {
url = "https://storage.googleapis.com/dart-archive/channels/stable/release/${dartVersion}/sdk/dartsdk-linux-x64-release.zip";
sha256 = dartHash.x86_64-linux;
};
"${dartVersion}-aarch64-linux" = fetchzip {
url = "https://storage.googleapis.com/dart-archive/channels/stable/release/${dartVersion}/sdk/dartsdk-linux-arm64-release.zip";
sha256 = dartHash.aarch64-linux;
};
};
};
src = fetchzip {
url = "https://storage.googleapis.com/flutter_infra_release/releases/stable/linux/flutter_linux_${version}-stable.tar.xz";
sha256 = hash;
};
};
src = fetchzip {
url = "https://storage.googleapis.com/flutter_infra_release/releases/stable/linux/flutter_linux_${version}-stable.tar.xz";
sha256 = hash;
in
(mkCustomFlutter args).overrideAttrs (prev: next: {
passthru = next.passthru // rec {
inherit wrapFlutter mkCustomFlutter mkFlutter;
buildFlutterApplication = callPackage ../../../build-support/flutter {
# Package a minimal version of Flutter that only uses Linux desktop release artifacts.
flutter = wrapFlutter
(mkCustomFlutter (args // {
includedEngineArtifacts = {
common = [ "flutter_patched_sdk_product" ];
platform.linux = lib.optionals stdenv.hostPlatform.isLinux
(lib.genAttrs ((lib.optional stdenv.hostPlatform.isx86_64 "x64") ++ (lib.optional stdenv.hostPlatform.isAarch64 "arm64"))
(architecture: [ "release" ]));
};
}));
};
};
}; in (mkCustomFlutter args).overrideAttrs (prev: next: {
passthru = next.passthru // rec {
inherit wrapFlutter mkCustomFlutter mkFlutter;
buildFlutterApplication = callPackage ../../../build-support/flutter {
# Package a minimal version of Flutter that only uses Linux desktop release artifacts.
flutter = wrapFlutter
(mkCustomFlutter (args // {
includedEngineArtifacts = {
common = [ "flutter_patched_sdk_product" ];
platform.linux = lib.optionals stdenv.hostPlatform.isLinux
(lib.genAttrs ((lib.optional stdenv.hostPlatform.isx86_64 "x64") ++ (lib.optional stdenv.hostPlatform.isAarch64 "arm64"))
(architecture: [ "release" ]));
};
}));
};
};
});
});
flutter2Patches = getPatches ./patches/flutter2;
flutter3Patches = getPatches ./patches/flutter3;
@ -50,13 +53,13 @@ in
{
inherit wrapFlutter;
stable = mkFlutter {
version = "3.7.12";
engineVersion = "1a65d409c7a1438a34d21b60bf30a6fd5db59314";
dartVersion = "2.19.6";
hash = "sha256-5ExDBQXIpoZ5NwS66seY3m9/V8xDiyq/RdzldAyHdEE=";
version = "3.10.0";
engineVersion = "d44b5a94c976fbb65815374f61ab5392a220b084";
dartVersion = "3.0.0";
hash = "sha256-3cRVPNrph9QUUnAdQhd5TOp2i1zFRxJ+OhqxXrJ+ncU=";
dartHash = {
x86_64-linux = "sha256-4ezRuwhQHVCxZg5WbzU/tBUDvZVpfCo6coDE4K0UzXo=";
aarch64-linux = "sha256-pYmClIqOo0sRPOkrcF4xQbo0mHlrr1TkhT1fnNyYNck=";
x86_64-linux = "sha256-AhvAt2c0URzL+MSIXlwbkuWNuhKbWvUpoyiYf1vXfcc=";
aarch64-linux = "sha256-bo4kZtNpj91JaCW8+GD4bQ60oOWQ7daj4C7cAHwLMtw=";
};
patches = flutter3Patches;
};

View File

@ -56,22 +56,23 @@ let
{
base = [
({ archive = "artifacts.zip"; } // lib.optionalAttrs (arch == "arm64") {
# For some reason, the arm64 artifacts are missing shader code.
# For some reason, the arm64 artifacts are missing shader code in Flutter < 3.10.0.
postPatch = ''
if [ -d shader_lib ]; then
The shader_lib directory has been included in the artifact archive.
This patch should be removed.
if [ ! -d shader_lib ]; then
ln -s ${lib.findSingle
(pkg: lib.getName pkg == "flutter-artifact-linux-x64-artifacts")
(throw "Could not find the x64 artifact archive.")
(throw "Could not find the correct x64 artifact archive.")
artifactDerivations.platform.linux.x64.base
}/shader_lib .
fi
ln -s ${lib.findSingle
(pkg: lib.getName pkg == "flutter-artifact-linux-x64-artifacts")
(throw "Could not find the x64 artifact archive.")
(throw "Could not find the correct x64 artifact archive.")
artifactDerivations.platform.linux.x64.base
}/shader_lib .
'';
})
{ archive = "font-subset.zip"; }
linux-flutter-gtk
(linux-flutter-gtk // {
# https://github.com/flutter/flutter/commit/9d94a51b607600a39c14470c35c676eb3e30eed6
variant = "debug";
})
];
variants = lib.genAttrs [ "debug" "profile" "release" ] (variant: [
linux-flutter-gtk

View File

@ -1,73 +1,71 @@
{
"1a65d409c7a1438a34d21b60bf30a6fd5db59314" = {
"flutter_patched_sdk.zip" = "sha256-Pvsjttm5OwpJ/pW4UQXvvEiJYCM5CoZZfVXz5jef37k=";
"flutter_patched_sdk_product.zip" = "sha256-fhj2uUOrLwrzHrM6RNVpPNize5Qu6mLQDcSzLT2TbRA=";
"d44b5a94c976fbb65815374f61ab5392a220b084" = {
"flutter_patched_sdk.zip" = "sha256-uLMzCF3dsBeSZnoY9YQ2bBQhw+hUAksoDKEWr3TCnhk=";
"flutter_patched_sdk_product.zip" = "sha256-0NbvAGSK0VgU6jSyboyhviP9H+wID7JoTS6xMqbZs2w=";
"android-arm" = {
"artifacts.zip" = "sha256-KDMiI6SQoZHfFV5LJJZ7VOGyEKC4UxzRc777j4BbXgM=";
"artifacts.zip" = "sha256-NZde8sVeknhR6bxchb/RURNIlKnJw6j5PZAWmmjiZvM=";
};
"android-arm-profile" = {
"artifacts.zip" = "sha256-MErLoGJWXg4yJ6b6c5bqP8Nat6O7eYSfM71mMNAAQf4=";
"linux-x64.zip" = "sha256-0TZQ05HR7NRqHzeoHZ/sOrjKiSvCpMUH85YXXzV4URg=";
"artifacts.zip" = "sha256-BTs1tuSdjVP8zAGCxV+uQ7sAAbCt0dML4g7/85IOFEs=";
"linux-x64.zip" = "sha256-GpjP5omeAjHBLZjJQdUMUnPoEgYBLppicLPUTY0fHqM=";
};
"android-arm-release" = {
"artifacts.zip" = "sha256-hU4S4FOqUGokByZ47nzOqQ4A9QFshruqrpJvJUBHUho=";
"linux-x64.zip" = "sha256-AqNlqjOht+c2sdW5ReoF66ZJWJl1W4vGKbQ3YyderRY=";
"artifacts.zip" = "sha256-ip2GnYkKq8aLWjVPk9no3aOf0c3k1h9foznhgLpZ17U=";
"linux-x64.zip" = "sha256-mGnmbraE98rqKRdO6keoITOaNCP0K3iYNRadihwOpxc=";
};
"android-arm64" = {
"artifacts.zip" = "sha256-ApNg3Uu9gyGNsx7sdpTCz1yADVAI5ZuNHgvgiuH9IpQ=";
"artifacts.zip" = "sha256-Sl7S/TNZWrlM4Z9UGN5rgGfpKk4UWKz6CKlQbz1qcZ4=";
};
"android-arm64-profile" = {
"artifacts.zip" = "sha256-D/8+WKPIkOaV3PwkCHiJROFlokm4lWWmtPQb93Yqwr0=";
"linux-x64.zip" = "sha256-S0RHLov6/C22VvGdvZV87Ybaxun8YBrw1gTgNklRcM0=";
"artifacts.zip" = "sha256-zNZtTxM8254y+KKSVYlBUYyIV2J04XN1cmnSjkQLJs8=";
"linux-x64.zip" = "sha256-M8AbEwFV2zedeqMoNeb+2UbR7i9I9rGh6LXBQcPO4iA=";
};
"android-arm64-release" = {
"artifacts.zip" = "sha256-OoYqHtwmT+VWJ+G+sMXM5+ux3h1Fnyo9Vj2za9cm5eE=";
"linux-x64.zip" = "sha256-NuXclg1a+Ofw5AWJ1tajpn2jYEZw6DluWxrFVL8rPfg=";
"artifacts.zip" = "sha256-PdnAIcYccdRs3r6M8rwmgl2x+TsBPMRF/iAEgwLbt/4=";
"linux-x64.zip" = "sha256-kmLkKXBj/70B3v5GJ50trTlV8epj16jOlQrh1U4/pVA=";
};
"android-x86" = {
"artifacts.zip" = "sha256-nN66nIrcbJHq2S4oIT5e2NCv7mS5Kw+HBv3ReHs+d3Y=";
"artifacts.zip" = "sha256-J1kgvNvdWo05HMHJMlVFECLMVnoCqUm1oP4K394w+xc=";
};
"android-x86-jit-release" = {
"artifacts.zip" = "sha256-A8F6K78Ykp1rMsUmjD7B9nFFPAubZnqAqgWSzbNCRwk=";
"artifacts.zip" = "sha256-Tz/veYh/73px0eH0FOXbN4G8fVjXmEHv7G8lRm3YLtY=";
};
"android-x64" = {
"artifacts.zip" = "sha256-hrBvnzCj/24h5kat96avlgXi6WhMsos5aPlkgxOYo8Q=";
"artifacts.zip" = "sha256-+WT7oT31XwE+ykLbiAUvnKw+WVR0VeFXPGpcMUHbsTg=";
};
"android-x64-profile" = {
"artifacts.zip" = "sha256-xzSj/2ah9aQoosaNGkSWFP3bMNJqRSFc0+78XEBHwzM=";
"linux-x64.zip" = "sha256-HfBiz1JWlBQ8KEfmf8uDlVzFlDt3+VF2VeY82tsMjHs=";
"artifacts.zip" = "sha256-f298VAJoZ2x+w0bxma7wu5h7Bn6+kCdrHh5qtjhhhhc=";
"linux-x64.zip" = "sha256-73Br9XgafwmagxAf61NSHn4BHn4q90pHJYEXCfAG8qY=";
};
"android-x64-release" = {
"artifacts.zip" = "sha256-TcfMeA+8Uf9yRrYdEIsjip0cKmSUm2Ow1tkoE9803XY=";
"linux-x64.zip" = "sha256-D6efb6pj9+xjPnJu3O+ZCmwfatBzasuFZEFRntAiU9U=";
"artifacts.zip" = "sha256-63hQCvObPmIxTcKyBQlXgGY6FfKp9PrbBY0RkSr1D/U=";
"linux-x64.zip" = "sha256-i5WQeePNxUNAbVR06Lz2XCXvZZTJxaFB6txtpVn2h9I=";
};
"linux-arm64" = {
"artifacts.zip" = "sha256-xyKVaEFb5gVkVrPzDrOql5BmXGO0FnCSeXOoQ10ZFrw=";
"font-subset.zip" = "sha256-Ulwb6q2SzB4suMJhAM3zAwWOzlEImlu9Ha+w5u4QqIU=";
"linux-arm64-flutter-gtk.zip" = "sha256-SiYOH++py4zeoD3BkNayqy/C9Zz9OiYQ5+u+pDLIpWg=";
"artifacts.zip" = "sha256-LTdVexuy7cL6dJqdM14YteI7Jo/z5wYOHakbX/BiV38=";
"font-subset.zip" = "sha256-cqLjvl3maO6NpN47/e718xyuSL8L8cHqU6ybuwlD+fA=";
};
"linux-arm64-debug" = {
"linux-arm64-flutter-gtk.zip" = "sha256-SiYOH++py4zeoD3BkNayqy/C9Zz9OiYQ5+u+pDLIpWg=";
"linux-arm64-flutter-gtk.zip" = "sha256-SRlKQllg5UWHk2kOIQ6ZwbqG5FoeFGCl2F9tTI+XVOE=";
};
"linux-arm64-profile" = {
"linux-arm64-flutter-gtk.zip" = "sha256-xB0eqrBYD7vhOwYUgJwNaBftNZJgdwxA9AUpEfX0iFs=";
"linux-arm64-flutter-gtk.zip" = "sha256-4wERBO+eimsSKFt8/P6mQqgzv+HURK+O/YFHAUHpklA=";
};
"linux-arm64-release" = {
"linux-arm64-flutter-gtk.zip" = "sha256-aHLKV129WIRsLUG6xTMwCKB4eXD3jonqinjI8KSsOus=";
"linux-arm64-flutter-gtk.zip" = "sha256-1XHdFiW//1Yd+qOLrRlk0vma99HlGDC/RA0An8db/oY=";
};
"linux-x64" = {
"artifacts.zip" = "sha256-+zIABFXUpiqn3OMoLcU4NDLxZ1y9z0r46iCTNRHAkz8=";
"font-subset.zip" = "sha256-W4SRPvA4rraVqN1ehbY6MFL7ZIWDHVJhjlLtxyUJJKY=";
"linux-x64-flutter-gtk.zip" = "sha256-boICnuJF4zqGb7kaN5haO/df9hC9KeJidt3uIK06S7M=";
"artifacts.zip" = "sha256-Bl0BRxUfVqNX6y7HdUXu5lIFzMLB2GUJauhOLEeInEE=";
"font-subset.zip" = "sha256-v02HV8QOqwdv30RiHpKu8ujTXOQmupGr9HCfpBUvrKM=";
};
"linux-x64-debug" = {
"linux-x64-flutter-gtk.zip" = "sha256-boICnuJF4zqGb7kaN5haO/df9hC9KeJidt3uIK06S7M=";
"linux-x64-flutter-gtk.zip" = "sha256-xjScsvWgPO8qeccw5BGzNrMLNzn5O+CvOpoPkvlrX0o=";
};
"linux-x64-profile" = {
"linux-x64-flutter-gtk.zip" = "sha256-AnkLMPW3mwiXdiDz3Zo802QZRi+8EMCy4Mx2ODSbMOU=";
"linux-x64-flutter-gtk.zip" = "sha256-52nMjoHQZ/ve7yJW9d8YK02U8mowe9xHZpkTwbGq9vU=";
};
"linux-x64-release" = {
"linux-x64-flutter-gtk.zip" = "sha256-RAsgupVF18IxLaP8tJ7XRQ8y/um46nlpA8fDITPwLqY=";
"linux-x64-flutter-gtk.zip" = "sha256-SA7Th1Qasaj4Q5wFr89Rv8PNQx6s6zvHsDxT1EKKZV0=";
};
};
"57d3bac3dd5cb5b0e464ab70e7bc8a0d8cf083ab" = {