Dex'ing

14 views
Skip to first unread message

Johan Lindquist

unread,
Oct 20, 2016, 4:51:32 PM10/20/16
to Maven Android Developers
Hi all,

I am looking at creating a dex'd jar as a result of a build (a JAR project) and I can see the dex goal being executed (and the classes.dex created) but it seems it fails due to:

[ERROR] Failed to execute goal com.simpligility.maven.plugins:android-maven-plugin:4.4.1:dex (make-dex-jar) on project player-android-impl: Execution make-dex-jar of goal com.simpligility.maven.plugins:android-maven-plugin:4.4.1:dex failed: For artifact {player-android-impl:player-android-impl:1.5.0-SNAPSHOT:jar}: An attached artifact must have a different ID than its corresponding main artifact. -> [Help 1]

Assume it is attaching the classes.dex but without a classifier?

Also, should it be possible to declare a project with packaging 'dex' and the plugin would sort out a dex'd file as the main artifact?

Cheers,

Johan

Manfred Moser

unread,
Oct 21, 2016, 6:57:24 PM10/21/16
to maven-androi...@googlegroups.com


Johan Lindquist wrote on 20.10.2016 13:51:

> Hi all,
>
>
> I am looking at creating a dex'd jar as a result of a build (a JAR project) and I can see the dex goal being executed (and the classes.dex created) but it seems it fails due to:
>
>
> [ERROR] Failed to execute goal com.simpligility.maven.plugins:android-maven-plugin:4.4.1:dex (make-dex-jar) on project player-android-impl: Execution make-dex-jar of goal com.simpligility.maven.plugins:android-maven-plugin:4.4.1:dex failed: For artifact {player-android-impl:player-android-impl:1.5.0-SNAPSHOT:jar}: An attached artifact must have a different ID than its corresponding main artifact. -> [Help 1]
>
>
> Assume it is attaching the classes.dex but without a classifier?


Not sure

> Also, should it be possible to declare a project with packaging 'dex' and the plugin would sort out a dex'd file as the main artifact?

No... dex is not a packaging type we implement .. only aar, apk, apklib are there.

Manfred
Reply all
Reply to author
Forward
0 new messages