日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

Unity导出APk出错解决方法二

發(fā)布時間:2025/4/16 编程问答 22 豆豆
生活随笔 收集整理的這篇文章主要介紹了 Unity导出APk出错解决方法二 小編覺得挺不錯的,現(xiàn)在分享給大家,幫大家做個參考.

錯誤提示(需得打開編輯器log文件才能看到全部log,Unity3d只顯示一部分):

Error building Player: CommandInvokationFailure: Unable to convert classes into dex format. See the Console for details. C:/Program Files/Java/jdk1.8.0_05\bin\java.exe -Xmx2048M -Dcom.android.sdkmanager.toolsdir="F:\adt-bundle-windows-x86_64\sdk\tools" -Dfile.encoding=UTF8 -jar "D:\develop\Unity5.3.7\Editor\Data\PlaybackEngines\AndroidPlayer/Tools\sdktools.jar" -warning: Ignoring InnerClasses attribute for an anonymous inner class (com.tendcloud.tenddata.game.ae) that doesn't come with an associated EnclosingMethod attribute. This class was probably produced by a compiler that did not target the modern .class file format. The recommended solution is to recompile the class from source, using an up-to-date compiler and without specifying any "-target" type options. The consequence of ignoring this warning is that reflective operations on this class will incorrectly indicate that it is *not* an inner class.rouble writing output: Too many method references to fit in one dex file: 67088; max is 65536. You may try using multi-dex. If multi-dex is enabled then the list of classes for the main dex list is too large. References by package:4 android.accessibilityservice4 android.accounts106 android.animation451 android.app17 android.app.job2 android.appwidget53 android.arch.core.internal105 android.arch.lifecycle1 android.bluetooth241 android.content55 android.content.pm111 android.content.res58 android.database25 android.database.sqlite256 android.graphics130 android.graphics.drawable3 android.graphics.drawable.shapes3 android.graphics.pdf35 android.hardware5 android.hardware.display11 android.hardware.fingerprint24 android.location259 android.media19 android.media.browse92 android.media.session69 android.net6 android.net.http7 android.net.nsd16 android.net.wifi2 android.nfc2 android.nfc.cardemulation71 android.opengl311 android.os1 android.preference28 android.print5 android.print.pdf18 android.provider8 android.renderscript9 android.security6 android.security.keystore10 android.service.media31 android.support.annotation14 android.support.compat153 android.support.constraint125 android.support.constraint.solver375 android.support.constraint.solver.widgets14 android.support.coreui14 android.support.coreutils216 android.support.customtabs16 android.support.design309 android.support.design.internal1527 android.support.design.widget14 android.support.fragment335 android.support.graphics.drawable14 android.support.graphics.drawable.animated14 android.support.mediacompat843 android.support.transition

?

解決方法:

1.去掉不需要的jar包

2.導(dǎo)出android studio工程使用多個multi-dex:true 選項

官方文檔解決64k限制方法:https://developer.android.com/studio/build/multidex

相關(guān)文章?https://medium.com/@abhpatidar/solving-unity-dex-issue-538e134c8809

?

轉(zhuǎn)載于:https://www.cnblogs.com/mttnor/p/9961855.html

總結(jié)

以上是生活随笔為你收集整理的Unity导出APk出错解决方法二的全部內(nèi)容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網(wǎng)站內(nèi)容還不錯,歡迎將生活随笔推薦給好友。