1200字范文,内容丰富有趣,写作的好帮手!
1200字范文 > android 库编译报错 Android Studio编译项目报错

android 库编译报错 Android Studio编译项目报错

时间:2023-01-13 14:37:15

相关推荐

android 库编译报错 Android Studio编译项目报错

编译项目时报以下错误:

Error:Executionfailedfortask':app:dexDebug'.

>mon.internal.LoggedErrorException:Failedtoruncommand:

D:\ProgramFiles\Android\sdk\build-tools\21.1.1\dx.bat--dex--no-optimize--outputE:\AndroidStudio\51Community\app\build\intermediates\dex\debug--input-list=E:\AndroidStudio\51Community\app\build\intermediates\tmp\dex\debug\inputList.txt

ErrorCode:

2

Output:

UNEXPECTEDTOP-LEVELEXCEPTION:

com.android.dex.DexException:MultipledexfilesdefineLcom/nineoldandroids/animation/Animator$AnimatorListener;

atcom.android.dx.merge.DexMerger.readSortableTypes(DexMerger.java:596)

atcom.android.dx.merge.DexMerger.getSortedTypes(DexMerger.java:554)

atcom.android.dx.merge.DexMerger.mergeClassDefs(DexMerger.java:535)

atcom.android.dx.merge.DexMerger.mergeDexes(DexMerger.java:171)

atcom.android.dx.merge.DexMerger.merge(DexMerger.java:189)

atmand.dexer.Main.mergeLibraryDexBuffers(Main.java:454)

atmand.dexer.Main.runMonoDex(Main.java:302)

atmand.dexer.Main.run(Main.java:245)

atmand.dexer.Main.main(Main.java:214)

atmand.Main.main(Main.java:106)

E:\AndroidStudio\51Community\app\build\intermediates\tmp\dex\debug\inputList.txt 文件显示如下:

E:\AndroidStudio\51Community\app\build\intermediates\classes\debug

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\classes-3e64b59e9a0df6c480be227c6f859ef16d9fa29b.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\support-annotations-21.0.3-a6066fa93aeaf35db8806181b83af09f6972c97d.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\SocialSDK_tencentWB_3-de96bcd1f2a7e38e2356e51bcc36a068eaa354b2.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\SocialSDK_Sina-16245d5f54c6e6c5cb005ae155b795a51594dbb6.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\SocialSDK_sms-0b7b179efb72fe16318676789c68cf07009a3bcd.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\SocialSDK_email-9c56268928f119a2de6614ec6cededc6e8500ca6.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\SocialSDK_WeiXin_2-db741d212d08db982fb162cc85c83fc853cceb76.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\classes-519e71cd9a8c1c0dbb09ce29a3236dd15b14f68e.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\httpmime-4.1.3-ed4be30de5188272cabf1739b9b3faeceb7f1019.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\SocialSDK_QQZone_3-a6601bc0f8daf7674d38312a83ed58529d0a3cb8.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\SocialSDK_WeiXin_1-49222bc4425231616cecc2bb2f2b4897d7375886.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\SocialSDK_tencentWB_1-ec27441784e6380716c7df9f6a5ef41f646ca8a7.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\classes-48863ad07c8d68a998797d3daebb94ccb1c7c539.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\umeng-fb-v4.3.2-8b999ff10e30c139f7caa63dff6f875181f36516.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\SocialSDK_QQZone_1-e1279488dbb4b20f19b597fa9de0acb910448bc7.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\nineoldandroids-2.4.0-f60e1c63c466d26972cc42490e9ab5105010b7cf.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\SocialSDK_tencentWB_2-ffd8a45c04f67f51c56162fd664f44d4de6883c9.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\recyleview-8a22ef883fe1ddbd937b3ac73397d85f62b8ecbf.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\classes-b2e7fde87261cd72693a008b7cbd7aa27a7a7752.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\gson-2.2.4-d0fdfebc63a8cafabcc39ba6fadd4d90efab2c36.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\internal_impl-21.0.3-e206bf6f13a92165806e02b822761e75db5c83ce.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\umeng_sdk-9d5400cabc34822e0fc15eaaadfbd5312def96f2.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\afinal_0.5.1_bin-4f741513cedaaeeb95c13d4a4956578d14a7b4d2.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\classes-e6bd9492e6c05b11aa1b9a34f6e8c0d94a11aa39.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\umeng_social_sdk-6325a739a22f002c02f6a42a7961781c91d43090.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\classes-6093142cb1b1b87b59b1f5a83b414881ebd59482.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\SocialSDK_QQZone_2-bc9f014996659e1da8b65bb5c4ef8ffdd95d6949.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\classes-930d86bee9c2a4c4a2e347d6017b06c1b05dcec7.jar

E:\AndroidStudio\51Community\app\build\intermediates\pre-dexed\debug\classes-bba7203e62a28bd635e91f02764b30644c0d26b3.jar

问题所在:引入的两个库中,都用到NineOldAndroids类库,一个库引入NineOldAndroids.jar,另一个库中有NineOldAndroids的源码。

解决办法:删除一个库对NineOldAndroids的引用,让这个库引用另一个库。

本内容不代表本网观点和政治立场,如有侵犯你的权益请联系我们处理。
网友评论
网友评论仅供其表达个人看法,并不表明网站立场。