1

Im working on a library A, which has dependency on library B(jar lib) in gradle file:

compile files('libs/B.jar')

Library B has assets inside like pictures, dex files etc. When i build library A, i see exactly the same assets inside it. Problem is that i don't want to have duplicated assets inside A. This cause following error when building apk, which has dependency on both libs A and B:

Error:Execution failed for task ':app:transformResourcesWithMergeJavaResForDebug'.

com.android.build.api.transform.TransformException: com.android.builder.packaging.DuplicateFileException: Duplicate files copied in APK assets/dex/d.dex File1: Documents/projects/TestProjects/SampleApp/app/libs/B.jar File2: Documents/projects/TestProjects/SampleApp/app/libs/A.jar

How can i exclude assets from A?

Feusp
  • 99
  • 8
  • Possible duplicate of [How do I resolve "Duplicate files copied in APK META-INF/\*"](http://stackoverflow.com/questions/33923461/how-do-i-resolve-duplicate-files-copied-in-apk-meta-inf) – JafarKhQ Feb 26 '16 at 15:43

0 Answers0