I got proguard to work correctly, but the problem is that I have a library project inside my project, so when proguard does its magic the library doesn't recognize the classes (vice-versa).
How to use proguard correctly when I have a library project? how to keep both projects link to each others' classes correctly? Any help is much appreiciated guys.
Here's my App's build file:
apply plugin: 'com.android.application'
android {
compileSdkVersion 21
buildToolsVersion "21.1.2"
defaultConfig {
applicationId "com.ex.test"
minSdkVersion 14
targetSdkVersion 21
versionCode 1
versionName "1.0"
}
buildTypes {
release {
minifyEnabled true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
packagingOptions {
exclude 'META-INF/LICENSE'
exclude 'META-INF/LICENSE-FIREBASE.txt'
exclude 'META-INF/NOTICE'
}
}
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
compile 'com.android.support:appcompat-v7:21.0.2'
compile 'com.android.support:cardview-v7:21.0.2'
compile 'com.android.support:recyclerview-v7:21.0.2'
compile 'com.mcxiaoke.volley:library:1.0.+'
compile 'com.android.support:support-annotations:21.0.2'
compile 'com.android.support:support-v4:21.0.2'
compile project(':chatinglibrary')
compile 'com.squareup.picasso:picasso:2.4.0'
compile 'com.google.android.gms:play-services:6.5.87'
compile 'com.koushikdutta.ion:ion:2.+'
compile 'com.github.amlcurran.showcaseview:library:5.0.0'
compile 'com.afollestad:material-dialogs:0.7.6.0'
}
And here's my lib's build file:
apply plugin: 'com.android.library'
android {
compileSdkVersion 21
buildToolsVersion "21.1.2"
defaultConfig {
minSdkVersion 14
targetSdkVersion 21
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:21.0.3'
compile 'com.firebase:firebase-client-android:2.0.3+'
}