From 5a19f3468b18331d4b6b970843298b95422dc7b5 Mon Sep 17 00:00:00 2001 From: Tyler-Larkin Date: Mon, 17 Feb 2025 14:26:31 -0800 Subject: [PATCH] chore(): Added Desugaring to canary project --- build-support/build_canary.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/build-support/build_canary.sh b/build-support/build_canary.sh index dad5cc223a..65d9f68c89 100755 --- a/build-support/build_canary.sh +++ b/build-support/build_canary.sh @@ -38,6 +38,9 @@ sed -i '' -e "s/sourceCompatibility = .*/sourceCompatibility = JavaVersion.VERSI sed -i '' -e "s/targetCompatibility = .*/targetCompatibility = JavaVersion.VERSION_17/" ./android/app/build.gradle.kts # TODO(equartey): remove this line after the next stable release (3.22.0 or 4.0) sed -i '' -e '/kotlinOptions {/,/}/ s/jvmTarget = .*/jvmTarget = JavaVersion.VERSION_17.toString()/' ./android/app/build.gradle.kts + +sed -i '' -e "s/compileOptions {.*/compileOptions {\n\t\tisCoreLibraryDesugaringEnabled = true/" ./android/app/build.gradle.kts +sed -i '' -e "s/flutter {.*/dependencies {\n\tcoreLibraryDesugaring(\"com.android.tools:desugar_jdk_libs:2.0.3\")\n}\n\nflutter {/" ./android/app/build.gradle.kts cat ./android/app/build.gradle.kts sed -i '' -e "s#distributionUrl=.*#distributionUrl=https\\://services.gradle.org/distributions/gradle-8.9-all.zip#" ./android/gradle/wrapper/gradle-wrapper.properties