【发布时间】:2017-02-04 06:25:05
【问题描述】:
我将一个旧的 Eclipse 项目导入到 Android Studio 中,我正在尽最大努力让它编译,同时仍然支持 SdkVersion 4。
build.gradle:
apply plugin: 'com.android.application'
android {
compileSdkVersion 21
buildToolsVersion '21.0.0'
defaultConfig {
applicationId "com.name.name"
minSdkVersion 4
targetSdkVersion 21
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt'
}
}
}
dependencies {
compile 'com.android.support:support-v4:21.0.0'
}
错误:
Information:Gradle tasks [:app:generateDebugSources, :app:generateDebugAndroidTestSources, :app:mockableAndroidJar, :app:prepareDebugUnitTestDependencies]
C:\Users\me\WORK\ORIGINAL\original_gradle_made\app\build\intermediates\res\merged\debug\values\values.xml
Error:(206) Error retrieving parent for item: No resource found that matches the given name 'android:WindowTitleBackground'.
Error:(206) Error retrieving parent for item: No resource found that matches the given name 'android:WindowTitleBackground'.
Error:Execution failed for task ':app:processDebugResources'.
> com.android.ide.common.process.ProcessException: Failed to execute aapt
有人知道我缺少什么或需要更改吗?
【问题讨论】:
-
minSdkVersion 4 不确定是否存在 2017 年您的目标受众太多,至少使用 14 或 15 // 为什么要将 min 用作 4 ?如果对我来说似乎是一个框架错误@_@
标签: android eclipse android-studio merge android-support-library