File tree 1 file changed +25
-2
lines changed
1 file changed +25
-2
lines changed Original file line number Diff line number Diff line change @@ -6,11 +6,34 @@ allprojects {
6
6
}
7
7
8
8
rootProject. buildDir = ' ../build'
9
+
10
+ // Workaround for building with Flutter 3.24
11
+ // See: https://github.com/flutter/flutter/issues/153281#issuecomment-2292201697
9
12
subprojects {
10
- project. buildDir = " ${ rootProject.buildDir} /${ project.name} "
13
+ afterEvaluate { project ->
14
+ if (project. extensions. findByName(" android" ) != null ) {
15
+ Integer pluginCompileSdk = project. android. compileSdk
16
+ if (pluginCompileSdk != null && pluginCompileSdk < 31 ) {
17
+ project. logger. error(
18
+ " Warning: Overriding compileSdk version in Flutter plugin: "
19
+ + project. name
20
+ + " from "
21
+ + pluginCompileSdk
22
+ + " to 31 (to work around https://issuetracker.google.com/issues/199180389)."
23
+ + " \n If there is not a new version of " + project. name + " , consider filing an issue against "
24
+ + project. name
25
+ + " to increase their compileSdk to the latest (otherwise try updating to the latest version)."
26
+ )
27
+ project. android {
28
+ compileSdk 31
29
+ }
30
+ }
31
+ }
32
+ }
11
33
}
12
34
subprojects {
13
- project. evaluationDependsOn(' :app' )
35
+ project. buildDir = " ${ rootProject.buildDir} /${ project.name} "
36
+ project. evaluationDependsOn(" :app" )
14
37
}
15
38
16
39
tasks. register(" clean" , Delete ) {
You can’t perform that action at this time.
0 commit comments