myflashlab / common-dependencies-ANE

In this repository find all the required shared libraries for our Air Native Extensions to make sure your final app will have the minimum required libraries so your app won't be unnecessarily huge in size.
24 stars 10 forks source link

Package error #42

Closed reatailret closed 5 years ago

reatailret commented 5 years ago

Error when package apk whith latest anes from this repo.

Warning: packageName com.google.android.gms.ads.impl used by more than one ANE. Ignoring this entry
dx tool failed:
UNEXPECTED TOP-LEVEL EXCEPTION:
com.android.dx.cf.iface.ParseException: bad class file magic (cafebabe) or version (0034.0000)
        at com.android.dx.cf.direct.DirectClassFile.parse0(DirectClassFile.java:472)
        at com.android.dx.cf.direct.DirectClassFile.parse(DirectClassFile.java:406)
        at com.android.dx.cf.direct.DirectClassFile.parseToInterfacesIfNecessary(DirectClassFile.java:388)
        at com.android.dx.cf.direct.DirectClassFile.getMagic(DirectClassFile.java:251)
        at com.android.dx.command.dexer.Main.processClass(Main.java:709)
        at com.android.dx.command.dexer.Main.processFileBytes(Main.java:678)
        at com.android.dx.command.dexer.Main.access$300(Main.java:83)
        at com.android.dx.command.dexer.Main$1.processFileBytes(Main.java:607)
        at com.android.dx.cf.direct.ClassPathOpener.processArchive(ClassPathOpener.java:284)
        at com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:166)
        at com.android.dx.cf.direct.ClassPathOpener.process(ClassPathOpener.java:144)
        at com.android.dx.command.dexer.Main.processOne(Main.java:637)
        at com.android.dx.command.dexer.Main.processAllFiles(Main.java:506)
        at com.android.dx.command.dexer.Main.runMultiDex(Main.java:335)
        at com.android.dx.command.dexer.Main.run(Main.java:245)
        at com.android.dx.command.dexer.Main.main(Main.java:215)
        at com.android.dx.command.Main.main(Main.java:106)
...while parsing com/google/auto/value/extension/memoized/Memoized.class

1 error; aborting
<extensions>
    <extensionID>com.freshplanet.ane.AirInAppPurchase</extensionID>
    <extensionID>com.myflashlab.air.extensions.webView</extensionID>
    <extensionID>com.adobe.Vibration</extensionID>
    <extensionID>com.freshplanet.ane.AirDeviceId</extensionID>
    <extensionID>com.myflashlab.air.extensions.dependency.overrideAir</extensionID>
    <extensionID>com.myflashlab.air.extensions.dependency.androidSupport.arch</extensionID>
    <extensionID>com.myflashlab.air.extensions.dependency.androidSupport.core</extensionID>
    <extensionID>com.myflashlab.air.extensions.dependency.androidSupport.v4</extensionID>
    <extensionID>com.myflashlab.air.extensions.dependency.firebase.analytics</extensionID>
    <extensionID>com.myflashlab.air.extensions.dependency.firebase.common</extensionID>
    <extensionID>com.myflashlab.air.extensions.dependency.firebase.iid</extensionID>
    <extensionID>com.myflashlab.air.extensions.dependency.firebase.measurement.connector</extensionID>
    <extensionID>com.myflashlab.air.extensions.dependency.googlePlayServices.base</extensionID>
    <extensionID>com.myflashlab.air.extensions.dependency.googlePlayServices.basement</extensionID>
    <extensionID>com.myflashlab.air.extensions.dependency.googlePlayServices.measurementBase</extensionID>
    <extensionID>com.myflashlab.air.extensions.dependency.googlePlayServices.stats</extensionID>
    <extensionID>com.myflashlab.air.extensions.dependency.googlePlayServices.tasks</extensionID>
    <extensionID>com.myflashlab.air.extensions.dependency.firebase.messaging</extensionID>
    <extensionID>adobe.nativeExtension.dataShare</extensionID>

    <extensionID>com.myflashlab.air.extensions.dependency.googlePlayServices.ads</extensionID>
    <extensionID>com.myflashlab.air.extensions.firebase.core</extensionID>
    <extensionID>com.myflashlab.air.extensions.firebase.fcm</extensionID>
  </extensions>

with java 1.6 , 1.7, 1.8 and 10 ! how to solve?

myflashlab commented 5 years ago

Such errors happen when dependency classes are found more than once in your project. As I can see, you are using ANEs from other providers too. They must have hardcoded the dependencies inside their ANEs and that's the source of the problem. We have recently upgraded our Firebase ANE collection and all the dependencies. Please try updating your project and see what happens with the latest version of the ANEs. You may also try using our ANEs instead of other ANE providers to avoid any conflicts.

reatailret commented 5 years ago

Such errors happen when dependency classes are found more than once in your project. As I can see, you are using ANEs from other providers too. They must have hardcoded the dependencies inside their ANEs and that's the source of the problem. We have recently upgraded our Firebase ANE collection and all the dependencies. Please try updating your project and see what happens with the latest version of the ANEs. You may also try using our ANEs instead of other ANE providers to avoid any conflicts.

The question was about the error, not about the warning. DX tool error. If comment out this: <extensionID>com.myflashlab.air.extensions.dependency.firebase.common</extensionID> then there is no error. With the latest ANE from commit

updated dependencies to sync with Firebase V8.0.0

reatailret commented 5 years ago

I found solution adobe issue tracker