The error suggests it's a problem with duplicate AndroidManifest.xml 
 (which there are, one in the main project, one in the aar library project).

What have I done wrong?  Surely this is something the build system can 
handle?  (the AAR was generated by Android Studio too).


Executing tasks: [:test_class:assembleDebug]

:test_class:compileDebugNdk
:test_class:preBuild
:test_class:preDebugBuild
:test_class:checkDebugManifest
:test_class:prepareDebugDependencies
:test_class:compileDebugAidl
:test_class:compileDebugRenderscript
:test_class:generateDebugBuildConfig
:test_class:mergeDebugAssets
:test_class:generateDebugResValues UP-TO-DATE
:test_class:generateDebugResources
:test_class:mergeDebugResources
:test_class:processDebugManifest
:test_class:processDebugResources
:test_class:generateDebugSources
:test_class:compileDebugJava
:test_class:preDexDebug
:test_class:dexDebug
:test_class:processDebugJavaRes UP-TO-DATE
:test_class:validateDebugSigning
:test_class:packageDebugError: duplicate files during packaging of APK 
C:\Users\Mark\AndroidStudioProjects\TestApp\test_class\build\apk\test_class-debug-unaligned.apk
Path in archive: AndroidManifest.xml
Origin 1: 
C:\Users\Mark\AndroidStudioProjects\TestApp\test_class\build\libs\test_class-debug.ap_
Origin 2: 
C:\Users\Mark\AndroidStudioProjects\TestApp\test_class\libs\rsslib.aar
You can ignore those files in your build.gradle:
android {
  packagingOptions {
    exclude 'AndroidManifest.xml'
  }
}
 FAILED

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':test_class:packageDebug'.
> Duplicate files copied in APK AndroidManifest.xml
File 1: 
C:\Users\Mark\AndroidStudioProjects\TestApp\test_class\build\libs\test_class-debug.ap_
File 2: 
C:\Users\Mark\AndroidStudioProjects\TestApp\test_class\build\libs\test_class-debug.ap_


* Try:
Run with --stacktrace option to get the stack trace. Run with --info or 
--debug option to get more log output.

BUILD FAILED

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Android Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to