When trying to create an OpenStreetMapView from git: //github.com/osmdroid/osmdroid, I get this error:
failed to find target with hash string android-23: D:\Users\myusername\AppData\Local\Android
How can i fix this? Previous questions like this suggest checking that Android 23 is not installed, but in my case it is.
The following is the relevant information:
ANDROID_HOME D:\Users\myusername\AppData\Local\Android\sdk
D:\Users\myusername\AppData\Local\Android\sdk\platforms\ contains the directory \ android-23 \ (as well as android-19, android-21, android-22, android-MNC)
build.gradle
apply plugin: 'com.android.application' android { compileSdkVersion 23 buildToolsVersion "23.0.1" defaultConfig { applicationId "org.osmdroid.example" minSdkVersion 8 targetSdkVersion 23 versionCode 16 versionName "4.4-SNAPSHOT" } buildTypes { release { minifyEnabled false proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' } } packagingOptions { exclude 'META-INF/LICENSE' exclude 'META-INF/DEPENDENCIES' exclude 'META-INF/NOTICE' } lintOptions { abortOnError false } } dependencies { compile 'android.support:compatibility-v4:23+' compile project(':osmdroid-android') //compile 'org.osmdroid:osmdroid-third-party:4.4-SNAPSHOT' }
I tried to change targetSdkVersion and compileSdkVersion to 22. This causes the error message to change to "android-22" instead of "android-23".
SDK Manager: 
android gradle android-build
Al Lelopath Oct 29 '15 at 2:52 2015-10-29 14:52
source share