【发布时间】:2018-03-30 14:38:31
【问题描述】:
我曾尝试通过使用此论坛上以前的帖子来解决此问题,但都没有奏效。有人可以告诉我究竟是什么问题以及如何为这个 gradle 解决它吗?
apply plugin: 'com.android.application'
android {
compileSdkVersion 26
buildToolsVersion "26.0.1"
defaultConfig {
applicationId "org.tensorflow.lite.demo"
minSdkVersion 15
targetSdkVersion 26
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
// Remove this block.
jackOptions {
enabled true
}
}
lintOptions {
abortOnError false
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
aaptOptions {
noCompress "tflite"
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
}
repositories {
maven {
url 'https://google.bintray.com/tensorflow'
}
}
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2',
{
exclude group: 'com.android.support', module: 'support-annotations'
})
compile 'org.tensorflow:tensorflow-lite:+'
testCompile 'junit:junit:4.12'
}
错误:(1,0)=: 未找到 ID 为 com.android.application 的插件
我已经尝试过的帖子:Error:(1, 0) Plugin with id 'com.android.application' not found - no build.gradle file
【问题讨论】:
-
你能显示另一个 build.gradle 文件吗??
标签: android