Package a VR game for Android with UE 4.21

Hi all,

I followed this procedure to package a VR game on my Android 8.1 phone with UE 4.19:

https://docs.unrealengine.com/en-US/Platforms/GoogleVR/QuickStart
and it works, I can open the app on my phone.

But my projects have been created with UE 4.21 and i’m having problems packaging them. The app starts on my phone but i just get a black screen and it closes after a while, no error message.

If anyone knows the procedure to follow for 4.21, i’d greatly appreciate it. I did not find a way to downgrade my 4.21 projects into 4.19.

Hello Hugues,

I’ve been trying to get a solid repro for
Unreal Engine Issues and Bug Tracker (UE-65983)

What phone are you using?

Also, can you share your log from your phone?
Located on the phone with a directory similar to:
\UE4Game\YourProject\YourProject\Saved\Logs

Hi , thanks for your feed-back.
I’m using a Nexus 5x, with Android 8.1
Strangely enough, i don’t have a folder called /Saved/Logs on my phone.

After I run the .bat file on my computer, this folder and file is created on my phone, plus my app icon:
storage/emulated/0/obb/com.YourCompany.Test_Cardboard/main.1.com.YourCompany.test_Cardboard.obb

I search my phone for a Logs folder but nothing found, can’t find the UE4Game either.

Below I attach a screen shot of my PC screen after running the .bat file when the file is copied to my phone.

Does that help you ?

Hello Hugues,

I’d like to package my project with 4.21 too,but there is also a trouble for me.

My trouble is
“/android-ndk-r13b/toolchains/arm-linux-androideabi-4.9/prebuilt/windows-x86_64/lib/gcc/arm-linux-androideabi/4.9.x/…/…/…/…/arm-linux-androideabi/bin\ld: error: cannot find -llibaristo_interface.so”
It doesn’t report a error until packaging to …-armv7-es2.so

Which version of NDK do you use?And What should I fill the SDK&NDK API LEVEL blank?

Thanks a lot.

Hi, below a printscreen of my Project settings/Android SDK. I believe this answers your 2 questions, let me know if not:

263239-capture.jpg

make sure to enable VR plugins if you haven’t already …on the very top left click Edit then chose Plugins in the drop down menu , then type in VR in the search bar and enable them

yes, I enabled Google VR, Google VR Motion Controller and Google VR transition 2d

I didn’t use the NVPACK,and I wonder that the error reason is cuz I used a customed package rather than the default package(NVPACK).As you see,the error reminded me of cannot find .so library.

Now I have another problem,do u know the path for saving data on android?

Not sure as i could not make it work, but maybe the answer of O above can give you a hint, he says to look into this Android folder for a log: \UE4Game\YourProject\YourProject\Saved\Logs

, I have some info regarding UE-65983. Please see my post here: Android App Crashes on Launch UE4.21 (UE-65983) - Mobile - Epic Developer Community Forums

It seems it may be related to a mismatched JRE reference.

Hello DesertEagle_PWN,

It is not 100% certain, but I believe this is happening on phones without a magnometer or accelerometer or NFC.

What phone are you using?

As shared in the other answerHub issue my phone is a Samsung Galaxy S7 (SM-G930V)