Download

[ARCore] Error when building ARCore 1.2 in 4.19 from Source

I wanted to try the Augmented Images in Arcore 1.2 but i have an Error when launching to Android Device.

I did follow this Guide
-google-ar-unreal from github
-run setup.bat
-generate project files.bat
-Build UE4 Development for Win64
-create new blank project

All theses steps are OK and gives no error but when launching on device i get:


LogPlayLevel: ********** BUILD COMMAND STARTED **********
LogPlayLevel: Completed Launch On Stage: Build Task, Time: 10.760627
LogPlayLevel: Running: C:\Program Files (x86)\MSBuild\14.0\bin\MSBuild.exe "E:/Program Files/Epic Games/UnrealEngine-4.19-arcore2/Engine/Source/Programs/UnrealBuildTool/UnrealBuildTool.csproj" /verbosity:minimal /nologo /property:Configuration=Development /property:Platform=AnyCPU
LogPlayLevel:     DotNETUtilities -> E:\Program Files\Epic Games\UnrealEngine-4.19-arcore2\Engine\Binaries\DotNET\DotNETUtilities.dll
LogPlayLevel:     UnrealBuildTool -> E:\Program Files\Epic Games\UnrealEngine-4.19-arcore2\Engine\Binaries\DotNET\UnrealBuildTool.exe
LogPlayLevel: Took 0.7651444s to run MSBuild.exe, ExitCode=0
LogPlayLevel: Running: E:\Program Files\Epic Games\UnrealEngine-4.19-arcore2\Engine\Binaries\DotNET\UnrealBuildTool.exe arcore12custom Android Development -Project="E:\Epic Games\arcore12custom\arcore12custom.uproject"  "E:\Epic Games\arcore12custom\arcore12custom.uproject" -NoUBTMakefiles  -remoteini="E:\Epic Games\arcore12custom" -skipdeploy -ini:Game:[/Sc
ript/UnrealEd.ProjectPackagingSettings]:BlueprintNativizationMethod=Disabled -noxge -generatemanifest -NoHotReload
LogPlayLevel:   PLATFORM_ANDROID_NDK_VERSION = 120200
LogPlayLevel:   NDK toolchain: r12b, NDK version: 19, GccVersion: 4.9, ClangVersion: 3.8.256229
LogPlayLevel: Took 4.2952302s to run UnrealBuildTool.exe, ExitCode=0
LogPlayLevel: Running: E:\Program Files\Epic Games\UnrealEngine-4.19-arcore2\Engine\Binaries\DotNET\UnrealBuildTool.exe arcore12custom Android Development -Project="E:\Epic Games\arcore12custom\arcore12custom.uproject"  "E:\Epic Games\arcore12custom\arcore12custom.uproject" -NoUBTMakefiles  -remoteini="E:\Epic Games\arcore12custom" -skipdeploy -ini:Game:[/Sc
ript/UnrealEd.ProjectPackagingSettings]:BlueprintNativizationMethod=Disabled -noxge -NoHotReload -ignorejunk
LogPlayLevel:   PLATFORM_ANDROID_NDK_VERSION = 120200
LogPlayLevel:   NDK toolchain: r12b, NDK version: 19, GccVersion: 4.9, ClangVersion: 3.8.256229
LogPlayLevel:   Compiling Native code with NDK API 'android-19'
LogPlayLevel:   Performing 3 actions (12 in parallel)
LogPlayLevel:   [1/3] clang++.exe Module.GoogleARCoreBase.cpp [armv7-es2]
LogPlayLevel:   In file included from E:/Program Files/Epic Games/UnrealEngine-4.19-arcore2/Engine/Plugins/Runtime/GoogleARCore/Intermediate/Build/Android/arcore12custom/Development/GoogleARCoreBase/Module.GoogleARCoreBase.cpp:3:
LogPlayLevel:   E:\Program Files\Epic Games\UnrealEngine-4.19-arcore2\Engine\Plugins\Runtime\GoogleARCore\Source\GoogleARCoreBase\Private\GoogleARCoreAPI.cpp(14,10) :  fatal error: 'media/NdkImage.h' file not found
LogPlayLevel:   #include "media/NdkImage.h"
LogPlayLevel:            ^
LogPlayLevel:   1 error generated.
LogPlayLevel:   ERROR: UBT ERROR: Failed to produce item: E:\Program Files\Epic Games\UnrealEngine-4.19-arcore2\Engine\Plugins\Runtime\GoogleARCore\Binaries\Android\arcore12custom-GoogleARCoreBase-armv7-es2.a
LogPlayLevel:   Total build time: 16.69 seconds (Local executor: 0.00 seconds)
LogPlayLevel: Took 16.8282246s to run UnrealBuildTool.exe, ExitCode=5
LogPlayLevel: ERROR: Command failed (Result:5): E:\Program Files\Epic Games\UnrealEngine-4.19-arcore2\Engine\Binaries\DotNET\UnrealBuildTool.exe arcore12custom Android Development -Project="E:\Epic Games\arcore12custom\arcore12custom.uproject"  "E:\Epic Games\arcore12custom\arcore12custom.uproject" -NoUBTMakefiles  -remoteini="E:\Epic Games\arcore12custom" -
skipdeploy -ini:Game:[/Script/UnrealEd.ProjectPackagingSettings]:BlueprintNativizationMethod=Disabled -noxge -NoHotReload -ignorejunk. See logfile for details: 'UnrealBuildTool-2018.05.11-11.57.28.txt'
LogPlayLevel:        (see E:\Program Files\Epic Games\UnrealEngine-4.19-arcore2\Engine\Programs\AutomationTool\Saved\Logs\UAT_Log.txt for full exception trace)
LogPlayLevel: AutomationTool exiting with ExitCode=5 (5)
LogPlayLevel: Completed Launch On Stage: Build Task, Time: 21.514258
LogPlayLevel: BUILD FAILED
PackagingResults: Error: Launch failed! Unknown Error
LogWindowsTextInputMethodSystem: Display: IME system now deactivated.
LogWindowsTextInputMethodSystem: Display: IME system now deactivated.

Help would be welcome :slight_smile:

It seems *media/NdkImage.h *is only available on ndk version 24…
changing the NDK api level to *android-24 *seems to solve the problem