gradle编译出错

来源:互联网 发布:学编程哪个学校好 编辑:程序博客网 时间:2024/06/05 08:52

1.不支持Lambda语法(gradle编译)
解决办法:
在app目录的build.gradle中加上:
android {
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}

defaultConfig {
jackOptions {
enabled true
}
2.
解决办法
gradle.properties中加入:
android.useDeprecatedNdk=true
3.ndk Error:(115) * Android NDK: Aborting . Stop.错误
这里写图片描述

解决办法
修改JDK版本为26
这里写图片描述

3.Error: Your project contains C++ files but it is not using a supported native build

Put this part in build.gradle(Module:app) above buildTypes{}

sourceSets {
main {
jni.srcDirs = []
}
}

buildTypes{
}

4.安装后出错,醉了,我忘了把so库名改过来了。

原创粉丝点击