简体   繁体   English

无法构建已发布的 APK

[英]Could not build released APK

my flutter application is worked fine with flutter run but when i come to build an APK it failed with an error我的 flutter 应用程序在flutter run时运行良好,但是当我构建 APK 时它失败并出现错误

A problem occurred configuring root project 'android_intent'.配置根项目“android_intent”时出现问题。 SDK location not found.未找到 SDK 位置。 Define location with sdk.dir in the local.properties file or with an > ANDROID_HOME environment variable.使用 local.properties 文件中的 sdk.dir 或使用 > ANDROID_HOME 环境变量定义位置。

i don't know what a android_intent and i tried everything but i couldn't solve it我不知道什么是android_intent我尝试了所有方法但我无法解决它

im using我在用着

dependencies {
    classpath 'com.android.tools.build:gradle:3.5.1'
    classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
    // Add the google services classpath
    classpath 'com.google.gms:google-services:4.3.3'
}

and my locale.properties is that我的locale.properties

sdk.dir=E:\\development\\android-sdk
flutter.sdk=E:\\development\\flutter
flutter.buildMode=release
flutter.versionName=1.3.0

and my sitting.gradle contains include ':app' at the top和我的sitting.gradle在顶部包含include ':app'

any way i could build my sdk??有什么办法可以构建我的 sdk?

It gives the error of you not having an environment variable set up, try this:它给出了你没有设置环境变量的错误,试试这个:

MyComputer -> Properties -> Advanced sys settings -> Environment Variables -> 

Add ANDROID_HOME=C:...\android-sdk_folder添加 ANDROID_HOME=C:...\android-sdk_folder

Also there may be a problem with one of your packages.您的其中一个包裹也可能有问题。 Make sure they are all up to date.确保它们都是最新的。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM