我正在尝试在 Android Studio 1.1.0 上创建一个 google glass 应用(基于沉浸式),并且出现此错误。
错误:无法标准化文件“C:\Users\admin\AndroidStudioProjects\Sampleapp\app\build\intermediates\mockable-Google Inc.:Glass Development Kit Preview:19.jar”的路径。 文件名、目录名或卷标语法不正确
我之前在 Eclipse 上尝试过,一切都运行良好,但在 Android Studio 中却有点奇怪。
更新
项目:build.gradle
apply plugin: 'com.android.application'
repositories {
jcenter()
flatDir {
dirs 'prebuilt-libs'
}
}
android {
compileSdkVersion "Google Inc.:Glass Development Kit Preview:19"
buildToolsVersion "21.1.2"
defaultConfig {
applicationId "example.com.Sampleapp"
minSdkVersion 19
targetSdkVersion 19
versionCode 1
versionName "1.0"
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_7
targetCompatibility JavaVersion.VERSION_1_7
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
}
最佳答案
如果您使用,则会出现此错误
classpath 'com.android.tools.build:gradle:1.1.0'
Glass 开发支持的最高级别的 Gradle 构建工具是
classpath 'com.android.tools.build:gradle:1.0.1'
关于android - Android Studio 上的 Google Glass 编译错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/29089646/