Couldn't Load Lua, Stopped Unexpectedly

I just began testing my game on a real device (yay!), but, though it works perfectly on the AVD as well as the Corona Simulator, when I open it on the actual device, I get “Sorry! The application SampleApp (process com.foo.bar.SampleApp) has stopped unexpectedly. Please try again.” I opened ADB logcat and found that I’m getting this error:

I/ActivityThread( 1264): Pub com.foo.bar.SampleApp.files: com.ansca.corona.storage.FileContentProvider

W/dalvikvm( 1264): Exception Ljava/lang/UnsatisfiedLinkError; thrown while initializing Lcom/ansca/corona/JavaToNativeShim;

W/dalvikvm( 1264): Exception Ljava/lang/ExceptionInInitializerError; thrown while initializing Lcom/ansca/corona/CoronaEnvironment;

D/AndroidRuntime( 1264): Shutting down VM

W/dalvikvm( 1264): threadid=1: thread exiting with uncaught exception (group=0x40020560)

E/AndroidRuntime( 1264): FATAL EXCEPTION: main

E/AndroidRuntime( 1264): java.lang.ExceptionInInitializerError

E/AndroidRuntime( 1264): at com.ansca.corona.CoronaView.deleteTempDirectory(CoronaView.java:141)

E/AndroidRuntime( 1264): at com.ansca.corona.CoronaActivity.onCreate(CoronaActivity.java:101)

E/AndroidRuntime( 1264): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1047)

E/AndroidRuntime( 1264): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1618)

E/AndroidRuntime( 1264): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:1670)

E/AndroidRuntime( 1264): at android.app.ActivityThread.access$1500(ActivityThread.java:117)

E/AndroidRuntime( 1264): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:931)

E/AndroidRuntime( 1264): at android.os.Handler.dispatchMessage(Handler.java:99)

E/AndroidRuntime( 1264): at android.os.Looper.loop(Looper.java:130)

E/AndroidRuntime( 1264): at android.app.ActivityThread.main(ActivityThread.java:3695)

E/AndroidRuntime( 1264): at java.lang.reflect.Method.invokeNative(Native Method)

E/AndroidRuntime( 1264): at java.lang.reflect.Method.invoke(Method.java:507)

E/AndroidRuntime( 1264): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:842)

E/AndroidRuntime( 1264): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:600)

E/AndroidRuntime( 1264): at dalvik.system.NativeStart.main(Native Method)

E/AndroidRuntime( 1264): Caused by: java.lang.ExceptionInInitializerError

E/AndroidRuntime( 1264): at com.ansca.corona.CoronaEnvironment.setLuaErrorHandler(CoronaEnvironment.java:379)

E/AndroidRuntime( 1264): at com.ansca.corona.CoronaEnvironment.<clinit>(CoronaEnvironment.java:41)

E/AndroidRuntime( 1264): … 15 more

E/AndroidRuntime( 1264): Caused by: java.lang.UnsatisfiedLinkError: Couldn’t load lua: findLibrary returned null

E/AndroidRuntime( 1264): at java.lang.Runtime.loadLibrary(Runtime.java:429)

E/AndroidRuntime( 1264): at java.lang.System.loadLibrary(System.java:554)

E/AndroidRuntime( 1264): at com.ansca.corona.JavaToNativeShim.<clinit>(JavaToNativeShim.java:118)

E/AndroidRuntime( 1264): … 17 more

W/ActivityManager( 146): Force finishing activity com.foo.bar.SampleApp/com.ansca.corona.CoronaActivity

Of course, the real process name isn’t foo.bar.SampleApp, but it’s the same error :slight_smile:

I’m using the newest version of Corona. Building a sample app from the sample code folder does the same thing. I directly followed every instruction on the guide page, but it’s still not working.

I’m on a (slightly older, but still working well) Huawei-U8652 running Android 2.3.5; it’s the only Android phone I have access to. The minimum Android version on the Corona build panel is 2.2, so I don’t think the Android version is the problem.

  • Caleb

I’ve been building apps (sample and custom) for months and I’ve not gotten an error like this. I got a few where I just crushed the Lua memory and it crashed out, but not like the above.

Caleb, do you want to send me a build to test? It might have to do with the version of Android/Device you have. I have some less than bleeding edge devices (no offence) that are very finicky about what I can run on them.

Let me know if you want me to test it on my devices to give you a control group. I run the gamut from 2.3 to 4.4.2.

I guess I’ll just have to either get a new Android or buy an iOS developer license… It seems to me, if even the Corona sample code app won’t run, it must be a problem with my device. Thanks for the offer, but if you’ve been able to build apps and sample codes with it working, I don’t see that there’s any doubt about whether the problem is with Corona or with my device :D.

Not surprising, but a little disappointing :slight_smile:

  • Caleb

Ok, now I’m for sure confused.

It (as well as the sample app) has stopped working on the emulator, with the same error.

Can I get a reply from the Corona staff?

  • C

I’ve been building apps (sample and custom) for months and I’ve not gotten an error like this. I got a few where I just crushed the Lua memory and it crashed out, but not like the above.

Caleb, do you want to send me a build to test? It might have to do with the version of Android/Device you have. I have some less than bleeding edge devices (no offence) that are very finicky about what I can run on them.

Let me know if you want me to test it on my devices to give you a control group. I run the gamut from 2.3 to 4.4.2.

I guess I’ll just have to either get a new Android or buy an iOS developer license… It seems to me, if even the Corona sample code app won’t run, it must be a problem with my device. Thanks for the offer, but if you’ve been able to build apps and sample codes with it working, I don’t see that there’s any doubt about whether the problem is with Corona or with my device :D.

Not surprising, but a little disappointing :slight_smile:

  • Caleb

Ok, now I’m for sure confused.

It (as well as the sample app) has stopped working on the emulator, with the same error.

Can I get a reply from the Corona staff?

  • C