Samsung Gear VR Build Error

Hi everyone!

I have a Samsung Gear VR. I watched this tutorial below and applied step by step

But i got this error when i build the game. How can i fix that problem?


UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): UEDeployAndroid.RunCommandLineProgramWithException: Updating project.properties, local.properties, and build.xml for downloader_library...
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): UEDeployAndroid.RunCommandLineProgramWithException: Updating project.properties, local.properties, and build.xml for play-services-ads-9.2.0...
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): UEDeployAndroid.RunCommandLineProgramWithException: Updating project.properties, local.properties, and build.xml for play-services-ads-lite-9.2.0...
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): UEDeployAndroid.RunCommandLineProgramWithException: Updating project.properties, local.properties, and build.xml for play-services-auth-9.2.0...
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): UEDeployAndroid.RunCommandLineProgramWithException: Updating project.properties, local.properties, and build.xml for play-services-auth-base-9.2.0...
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): UEDeployAndroid.RunCommandLineProgramWithException: Updating project.properties, local.properties, and build.xml for play-services-base-9.2.0...
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): UEDeployAndroid.RunCommandLineProgramWithException: Updating project.properties, local.properties, and build.xml for play-services-basement-9.2.0...
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): UEDeployAndroid.RunCommandLineProgramWithException: Updating project.properties, local.properties, and build.xml for play-services-clearcut-9.2.0...
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): UEDeployAndroid.RunCommandLineProgramWithException: Updating project.properties, local.properties, and build.xml for play-services-drive-9.2.0...
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): UEDeployAndroid.RunCommandLineProgramWithException: Updating project.properties, local.properties, and build.xml for play-services-games-9.2.0...
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): UEDeployAndroid.RunCommandLineProgramWithException: Updating project.properties, local.properties, and build.xml for play-services-gass-9.2.0...
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): UEDeployAndroid.RunCommandLineProgramWithException: Updating project.properties, local.properties, and build.xml for play-services-nearby-9.2.0...
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): UEDeployAndroid.RunCommandLineProgramWithException: Updating project.properties, local.properties, and build.xml for play-services-plus-9.2.0...
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): UEDeployAndroid.RunCommandLineProgramWithException: Updating project.properties, local.properties, and build.xml for play-services-tasks-9.2.0...
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): UEDeployAndroid.RunCommandLineProgramWithException: Updating project.properties, local.properties, and build.xml for support-v4-23.0.0...
UATHelper: Packaging (Android (ETC2)): Error: Target id 'android-19' is not valid. Use 'android.bat list targets' to get the target ids.
UATHelper: Packaging (Android (ETC2)): UEDeployAndroid.UpdateGameActivity: 
UATHelper: Packaging (Android (ETC2)): ==== Writing new GameActivity.java file to C:\Users\ARG-3D-BRC\Desktop\VR_Test_Projesi\VR_Test_Projesi\Intermediate/Android/APK\src\com\epicgames\ue4\GameActivity.java ====
UATHelper: Packaging (Android (ETC2)): UEDeployAndroid.MakeApk: 
UATHelper: Packaging (Android (ETC2)): Copying new .so C:\Program Files (x86)\Epic Games\4.14\Engine\Binaries\Android\UE4Game-armv7-es2.so file to jni folder...
UATHelper: Packaging (Android (ETC2)): UEDeployAndroid.RunCommandLineProgramWithException: Preparing native code for debugging...
UATHelper: Packaging (Android (ETC2)): Program.Main: ERROR: AutomationTool terminated with exception: ERROR: C:/Program Files/Java/android-ndk-r13b/ndk-build.cmd failed with args APP_ABI="armeabi-v7a " NDK_DEBUG=1
UATHelper: Packaging (Android (ETC2)): Program.Main: AutomationTool exiting with ExitCode=1 (Error_Unknown)
UATHelper: Packaging (Android (ETC2)): BUILD FAILED
PackagingResults:Error: Error Unknown Error

Any answer? :smiley:

Are you able to build a blank project ok? If not then it’s probably something with your android sdk setup.

Perhaps try following these instructions: https://docs.unrealengine.com/latest/INT/Platforms/GearVR/QuickStart/index.html to see if something basic is exporting fine first?

It doesn’t look like you have android platform 19 installed. That is what the error message is about. You can run SDK Manager.exe in android-sdk-windows and select to install it, but android-19 and android-21 should have been selected already if you used the Codeworks for Android installer in Engine/Extras/AndroidWorks.

File->Package Project->Packaging Settings find Platforms Title and click android sdk title check location of android sdk path (if you use android sdk before unreal engine this path like this “C:\Users\admin\AppData\Local\Android\sdk” ) change this directory (C:\NVPACK\android-sdk-windows if you install CodeWorks for Android 1R6)
if dont install find in C:\Users\admin\AppData\Local\Android\sdk SDK Manager.exe run it find api level 19 install it