I use Android Studio and I have several libraries that I use there.
I have:
android-query-full.0.25.10.jar
gson-2.2.4-sources.jar
slide-menu.jar
I have defined in the build.gradle
file to compile the entire libs directory like this:
dependencies {
compile 'com.android.support:support-v4:13.0.+'
compile fileTree(dir: 'libs', include: '*.jar')
}
All these working great.
Now I want to add another library "PullToRefresh"
I have packaged the Res
and Src
folders to a single jar file with the source code from eclipse (as I did with SlideMenu.jar) and added the newly created jar as a library to my project next to all others.
when I try to build my project I get the following error from gradle:
Gradle: : duplicate files during packaging of APK C:\Code\TestProject\Test\build\apk\Endilo-debug-unaligned.apk
Gradle: Execution failed for task ':Endilo:packageDebug'.
> Duplicate files copied in APK res/values/attrs.xml
File 1: C:\Code\TestProject\Test\libs\PullToRefresh.jar
File 2: C:\Code\TestProject\Test\libs\PullToRefresh.jar
This is very weird as I get duplicates from the same jar file.. what is happening here!?