-
Notifications
You must be signed in to change notification settings - Fork 23
Feature/android build #22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
Thank you for this, the APK works great, but I have tried to put together the Unity project and no matter what I do I get errors when I run my version on the Android device, around the dlopen within the LoadLibrary(). Works perfectly in windows build. I have tried Mono and IL2CPP but always get either dlopen failed library "snes9x_libretro_android.so file" not found when using Mono or Undefined symbol UnityShaderCompilerExtEvent when using IL2CPP. Compiling for Android 4.4 upwards, tried on several different devices. I check if the file exists using WWW in unity and I get a true response and even checked the APK file and all .so files are there. `var www = new UnityWebRequest(fileName);
Fails at the below. `Debug.Log("So Path : " + fileName);
I have tried the following versions of unity. 2019.4.9f1 Just wondering if I am missing something in the UNITY settings / project. Any advice would be much appreciated, Thanks Mike |
Hello, this is a very interesting project. I tried to follow your instruction but I end with a white screen on the virtual TV. On Windows, it works normally. I put the cores .so in Plugins and assigned them with Arm7, enabled External SD Card (and I have the screen with the first boot of the app), and put the games in the StreamingAssets folder. If I monitor errors, I get something about "no local sync point found": I tried on Unity 2109.4 and 2021.3. PS : It lloks like the core is not loaded by ldopen. Any ideas ? Thank you Nicolas |
Hi @nickos64252 I am looking at this project again after a while, I will let you know if I get anything similar. I have been trying to get it to work for VR on Quest2 but just testing on Samsung Phones at the min, but still getting the errors. These are the 2 errors I get.
Mike |
Hi @saintmikie , I am doing pretty much the same thing. I want to put it on Quest/Quest 2, but currently trying to make it run an any Android device. I have the exact same errors, but I have "unable to find libdl" just before. For now, I guess no ".so" are loaded, but i cannot figure out why. Nicolas |
You have to include the android liberto cores, the so-called "so" files have to include in your apk. check at the "lib" folder of your apk and "assets" for the "so" files |
I put the cores "*.so" in the Plugins folder and they are present in the apk lif folder. But I think libdl is not found and that makes them useless. |
Hi, Could it be that they are not in the root of lib. Mike |
"sned9x_libretro_android.so" is there.. but where did you find libdl.so ? I think I by passed that by changing If what you do work, I would like to know your way. I guess you downloaded libdl.so somewhere else, then added it in Plugins and configured it for Armv7. Have you changed anything else ? |
I downloaded the APK above and that works fine on my phone. libdl.so does not seem to exist in the APK above. Just comparing builds now. Mike |
Got a little bit further but now getting the error below. It finds the so file, in my case I have tried 2 , snes9X_libretro_android, fuse_libretro_android, I have also made sure I am using the sames version of unity that the Github Project is set too. 2019.4.9f1. I also use the free asset, InGameDebugConsole for unity. I can get the windows version working fine. |
Hello, I succeeded to make it run and wanted to let you know. 1- libdl 2- core naming 3- rom path Hope it helps Nicolas |
Hi Nicolas, Well I am pretty positive that mine are now being found but now stuck with the Partial Byte Sequence error. Both the libdl.so and rom are being found, but fails when reading it, I don't get the file not found anymore. What version of Unity are you running in, I am using 2019.4.9f1 on Windows. Maybe my libdl.so is the wrong version or something like that, or I am missing something in unity. Mike |
I tried and succeeded on Unity 2019.4.11 and 2021.3.1 |
OMG, it's working. Once changing to "dl" I had to remove the libdl from my project and it is now working, I still get the UnityShader error but it is working. Thank you for the insperation. Mike |
Core downloader sets the core file as native and arm7

Then the shared library will be available globally inside the APK

Enabling SD Card permission

Rom inside Assets/StreamingAssets

Only for the first time you play, the permission will be asked

Playable

APK demo
https://drive.google.com/file/d/144tQuoYxkcMtt7cj5X-HiPV021aKnc9f/view?usp=sharing