Exposing hidden APIs android L (SDK 21) in Android Studio

后端 未结 5 2091
粉色の甜心
粉色の甜心 2020-12-20 01:04

I have successfully extracted the class files from an android emulator and replaced them into my android.jar file residing inside my \\platforms\\android-21\\android.jar and

5条回答
  •  庸人自扰
    2020-12-20 01:26

    1. Create folder under ../app, named as 'systemlibs'
    2. Copy your library under 'systemlibs'
    3. add provided files('systemlibs/android.jar') in app/build.gradle dependencies
    4. sync gradle and build
    
    
        dependencies {
            provided files('systemlibs/android.jar')
            compile fileTree(dir: 'libs', include: ['*.jar'])
            testCompile 'junit:junit:4.12'
            compile 'com.android.support:appcompat-v7:23.4.0'
            compile 'com.android.support:design:23.4.0'
        }
    
    

提交回复
热议问题