HaxeExtension/extension-locale

lime rebuild android error

Closed this issue · 8 comments

HI! I can't rebuild android ndll's.

Error

Error: error running arm-linux-androideabi-g++ -o../ndll/Android/libopenflLocaleExtension.so ...

Hi, you don't need to rebuild for android (android version of this extension does not requires you to rebuild, as is pure JAVA code).

Yes, I just realized. But lime don't include java source from include.xml. After including <haxelib name="openfl-locale" /> in main application.xml all works

This is strange... it should include that directly. Which version of Lime and OpenFL are you using?

➜  1,0,0  haxelib list | grep -E "openfl|lime"
lime-samples: [2.3.0]
lime: 2.3.1 2.4.4 2.4.5 [2.4.6]
openfl-locale: [1.0.0]
openfl-samples: [2.2.2]
openfl: 3.0.1 3.1.0 [3.1.1]

mmm, I'm testing here with same version and it's working fine :/
Can you provide the output / error you're getting?

lime clean android
lime test android -debug
application.xml with out openfl-locale library, only haxe-ga

07-08 01:16:19.800: W/System.err(27325): java.lang.ClassNotFoundException: Didn't find class "localeExtension.Locale" on path: DexPathList[[zip file "/data/app/md.deep.KidsMosiac-2/base.apk"],nativeLibraryDirectories=[/data/app/md.deep.KidsMosiac-2/lib/arm, /vendor/lib, /system/lib]]
07-08 01:16:20.057: W/System.err(27325):    at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:56)
07-08 01:16:20.057: W/System.err(27325):    at java.lang.ClassLoader.loadClass(ClassLoader.java:511)
07-08 01:16:20.057: W/System.err(27325):    at java.lang.ClassLoader.loadClass(ClassLoader.java:469)
07-08 01:16:20.057: W/System.err(27325):    at org.haxe.HXCPP.main(Native Method)
07-08 01:16:20.057: W/System.err(27325):    at org.haxe.HXCPP.run(HXCPP.java:23)
07-08 01:16:20.057: W/System.err(27325):    at org.haxe.lime.GameActivity.onCreate(GameActivity.java:123)
07-08 01:16:20.057: W/System.err(27325):    at android.app.Activity.performCreate(Activity.java:5933)
07-08 01:16:20.057: W/System.err(27325):    at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1105)
07-08 01:16:20.057: W/System.err(27325):    at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2282)
07-08 01:16:20.057: W/System.err(27325):    at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2391)
07-08 01:16:20.057: W/System.err(27325):    at android.app.ActivityThread.access$900(ActivityThread.java:147)
07-08 01:16:20.057: W/System.err(27325):    at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1296)
07-08 01:16:20.058: W/System.err(27325):    at android.os.Handler.dispatchMessage(Handler.java:102)
07-08 01:16:20.058: W/System.err(27325):    at android.os.Looper.loop(Looper.java:135)
07-08 01:16:20.058: W/System.err(27325):    at android.app.ActivityThread.main(ActivityThread.java:5256)
07-08 01:16:20.058: W/System.err(27325):    at java.lang.reflect.Method.invoke(Native Method)
07-08 01:16:20.058: W/System.err(27325):    at java.lang.reflect.Method.invoke(Method.java:372)
07-08 01:16:20.058: W/System.err(27325):    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:898)
07-08 01:16:20.058: W/System.err(27325):    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:693)
07-08 01:16:20.058: W/System.err(27325):    Suppressed: java.lang.ClassNotFoundException: localeExtension.Locale
07-08 01:16:20.061: W/System.err(27325):        at java.lang.Class.classForName(Native Method)
07-08 01:16:20.061: W/System.err(27325):        at java.lang.BootClassLoader.findClass(ClassLoader.java:781)
07-08 01:16:20.061: W/System.err(27325):        at java.lang.BootClassLoader.loadClass(ClassLoader.java:841)
07-08 01:16:20.061: W/System.err(27325):        at java.lang.ClassLoader.loadClass(ClassLoader.java:504)
07-08 01:16:20.061: W/System.err(27325):        ... 17 more
07-08 01:16:20.061: W/System.err(27325):    Caused by: java.lang.NoClassDefFoundError: Class not found using the boot class loader; no stack available
07-08 01:16:20.063: E/HXCPP(27325): Called from *::closure extension/locale/Locale.hx line 7
07-08 01:16:20.063: E/HXCPP(27325): Called from openfl._legacy.utils.JNI::createStaticMethod openfl/_legacy/utils/JNI.hx line 123
07-08 01:16:20.063: E/HXCPP(27325): Called from extern::cffi C:/HaxeToolkit/haxe/lib/hxcpp/3,2,102/src/hx/Lib.cpp line 159
07-08 01:16:20.063: E/Exception(27325): JNI Exception

Ups, issue was for haxe-ga 😫 but I posted it here (fail)

Never mind... In any case both are related.
Are you using this with a Lime project or with an OpenFL project?

I'm testing it with a clean OpenFL project including haxe-ga without issues. Maybe you can send a failinf sample so I can test it here.