Game crashes on the most android devices


#1

Hello! Few days ago I have released my first game on the Google Play. And as there is saying, I have targeted SDK v.27 (26 doesn’t work properly as well). Since that, the half of the devices started to crash on launch with an error: java.lang.UnsatisfiedLinkError at org.haxe.lime.GameActivity.onCreate (GameActivity.java:118).
Initially this game was made with Openfl 2.2.8, lime 2.2.2, haxe 3.1.3, SDK v.19 and everything was working well with that combo. Can someone give some advice how to fix that problem? I have found some suggestions to update NDK, but unfortunately that didn’t help too, lots of cominations SDK/NDK were tried.


#2

What versions are you using now? Are you using any native extensions? Is this something you can reproduce locally? Is there anything these devices have in common?

Our minimum version of Android did change, we moved from API 10 (Android 2.3.3) to API 14 (Android 4.0.1), though I wonder if we need to make this even newer


#3

Hello Joshua! Now I’m using:

  • haxe 3.1.3
  • openfl 2.2.8
  • lime 2.2.2
  • jdk 1.8.0_45
  • ndk 11.2
  • sdk 19 (min sdk 17)
  • actuate 1.8.6
  • native extensions extension-admob/1.6.4, extension-wake-lock/1.0.1

This combination works fine on Android 4.4 and Android 7.0
But when I’m setting target sdk v25+, Android 7.0 starting to crash with the error above.


#4

When i look at GameActivity.java, there is on the line 118: System.loadLibrary (“lime”). So the problem may starts there. I was trying to update lime to the newer version, but since then all my attempts to build the game failing. Also at the google dev console i see that the similar issue is on Android v8.0 too.


#5

I haven’t had any issues with the Android devices tested, but I’ll try and broaden the number of devices we are testing against. I did notice one thing – we updated our minimum Android SDK/NDK requirement to API 14 (due to changes in SDL) but this wasn’t reflected in the Lime tools. As a result, we were setting platform API 14 as the minimum in our native builds, but API 8 on the Java side. This could have caused some potential problems.

It’s possible to do this manually by setting <config:android minimum-sdk-version="14" />, but it could also be somehow related to API 26 changes. Since that’s going to become the required target SDK (or greater) this year by Google, I’ll do more testing with it


#6

Thank you, Joshua! Any help would be awesome. Looks like all is left for me, is try to update to the latest OpenFL version with new Lime, but i just afraid there will be lots of work, as my current code, that uses TileSheets, probably will not work.


#7

I just found the more detailed description of the error:

AndroidRuntime: java.lang.UnsatisfiedLinkError: dlopen failed: library “/home/joshua/Development/Android/android-ndk-r8b/platforms/android-9/arch-arm/usr/lib/libc.so” not found


#8

Are you using any native extensions?

Can you try using a newer Android NDK version, such as r13b? HXCPP isn’t compatible with r16 or 17 yet