請確保您的sdk中有一個v7目錄,我認爲已有足夠的'Android支持庫'(在其他部分)。事實證明,我錯過了支持庫的本地Maven倉庫(extras; android; m2repository)'Studio發現實際上並修復了Gradle依賴關係。使用gradle構建然後工作。 $貓的應用程序/的build.gradle
apply plugin: 'com.android.application'
android {
compileSdkVersion 23
buildToolsVersion "23.0.2"
defaultConfig {
applicationId "pat.example.com.gdbdemo"
minSdkVersion 15
targetSdkVersion 23
versionCode 1
versionName "1.0"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'com.android.support:appcompat-v7:23.2.1'
}
您是否將jar添加到libs文件夾? – Raghunandan
yes android-support-v7-appcompat.jar – Sun
@AbrahimNeil:查看[無法找到新的Android ActionBar支持的Theme.AppCompat.Light](http://stackoverflow.com/questions/17870881/cant-find-theme -appcompat-light-for-new-android-actionbar-support)可能會幫你 –