Dx bad class file magic (cafebabe) or version (0033.0000) with ADK14

前端 未结 18 1970
攒了一身酷
攒了一身酷 2020-11-27 05:00

Since moving to ADK14, I have been unable to build new apks for release on my Windows 7 system.

Building fails with \"conversion to dalvik format failed with error 1

18条回答
  •  一生所求
    2020-11-27 05:50

    For me this problem resided in too old build tools version installed (the build tools were behind the platform tools and sdk versions I was using). So what I did to fix the error:

    • I downloaded the latest version of the build tools from Android SDK manager
    • I am using ADT. Still, the latest version of the build tools was not used andthe error persisted. So I added the line sdk.buildtools=22.0.1 in the project.propertiesfiles in all my projects and libraries. Now the error is gone.

    PS: The only drawback being that I hardcoded the version and in future updates I will not automatically use it.

提交回复
热议问题