bravekingzhang / dim

封装的一个腾讯云im,以便于flutter开发者可以方便继承im到自己的应用中
Other
64 stars 22 forks source link

flutter build apk 报错 #22

Open mengsiyitiaojie opened 4 years ago

mengsiyitiaojie commented 4 years ago

FAILURE: Build failed with an exception.

BUILD FAILED in 0s

The plugin dim could not be built due to the issue above.

fangmd commented 4 years ago

网络问题吧

InTheClodus commented 4 years ago

我今天打包也遇到了这个问题我是这么解决的:

打开 External Libraries-->Flutter Plugins-->dim-0.2.8-->android-->gradle.wrapper-->打开 gradle-wrapper.properties文件,将 distributionUrl=https\://services.gradle.org/distributions/gradle-4.4-all.zip修改为 distributionUrl=https\://services.gradle.org/distributions/gradle-5.6.2-all.zip 然后在打开 ..-->android-->build.gradle文件将

compileSdkVersion 27
    defaultConfig {
        minSdkVersion 16
        testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
    }

修改为

compileSdkVersion 30
 defaultConfig {
        minSdkVersion 19
        testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
    }

我通过这个方式修改源文件就可以编译正常,如果你还在用,希望可以帮到你