Build failed after updating tools for Android L

前端 未结 3 773
醉话见心
醉话见心 2021-02-07 07:39

I cannot build my project after updating the tools. I get this error in Android Studio.

/build/exploded-aar/com.android.support/support-v4/21.0.0-rc1/And

相关标签:
3条回答
  • 2021-02-07 07:58

    Did you update your build.gradle file to reflect these changes?

    compileSdkVersion is set to 'android-L'
    minSdkVersion is set to 'L'
    targetSdkVersion is set to 'L'
    

    Source: http://developer.android.com/preview/setup-sdk.html

    0 讨论(0)
  • 2021-02-07 08:02

    This solved the issue for me and I was able to build the app.

    compile('com.android.support:support-v4:19.1.0'){
        force = true
    }
    
    0 讨论(0)
  • 2021-02-07 08:10

    In your app/build.gradle file, change
    compile 'com.android.support:support-v4:+'
    to
    compile 'com.android.support:support-v4:19.1.0'

    The '+' means that it will look for the newest version of the dependency. If you download the L preview, the latest version will be the support library for L - which isn't going to work for a project whose target is API 19.

    0 讨论(0)
提交回复
热议问题