Commit 75ef9d02 authored by Mikkel Nygaard Ravn's avatar Mikkel Nygaard Ravn Committed by GitHub

Avoid building x86 jar for profile and release modes (#11486)

parent 7df854ad
...@@ -222,14 +222,14 @@ class FlutterPlugin implements Plugin<Project> { ...@@ -222,14 +222,14 @@ class FlutterPlugin implements Plugin<Project> {
} }
project.android.applicationVariants.all { variant -> project.android.applicationVariants.all { variant ->
if (project.tasks.findByName('flutterBuildX86Jar')) { String flutterBuildMode = buildModeFor(variant.buildType)
if (flutterBuildMode == 'debug' && project.tasks.findByName('flutterBuildX86Jar')) {
Task task = project.tasks.findByName("compile${variant.name.capitalize()}JavaWithJavac") Task task = project.tasks.findByName("compile${variant.name.capitalize()}JavaWithJavac")
if (task) { if (task) {
task.dependsOn project.flutterBuildX86Jar task.dependsOn project.flutterBuildX86Jar
} }
} }
String flutterBuildMode = buildModeFor(variant.buildType)
GenerateDependencies dependenciesTask = project.tasks.create(name: "flutterDependencies${variant.name.capitalize()}", type: GenerateDependencies) { GenerateDependencies dependenciesTask = project.tasks.create(name: "flutterDependencies${variant.name.capitalize()}", type: GenerateDependencies) {
flutterRoot this.flutterRoot flutterRoot this.flutterRoot
flutterExecutable this.flutterExecutable flutterExecutable this.flutterExecutable
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment