UPDATE If I don’t build for arm64, but do build for x86_64, I can build for Android. This doesn’t help me, as I need to install to quest 2, but it might help identify what’s going on.
Hey! So basically I’ve been attempting to package Android for UE5.2 (specifically 5.2.1 source), however I can’t seem to get it to work at all.
I can easily package for 5.1, and I don’t see many topics at all about people having problems with 5.2 so I’m curious if there is a solution.
No matter what configuration I try with Android Studio or the project settings I always freeze up during the compiling NDK phase.
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): Using 'git status' to determine working set for adaptive non-unity build (A:\UnrealEngine\UE5\UE_5.2_S\UnrealEngine).
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): Android (8490178, based on r450784d) clang version 14.0.6 (https://android.googlesource.com/toolchain/llvm-project 4c603efb0cca074e9238af8b4106c30add4418f6)
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): Target: x86_64-w64-windows-gnu
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): Thread model: posix
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): InstalledDir: C:/Users/Joe/AppData/Local/Android/Sdk/ndk/25.1.8937393/toolchains/llvm/prebuilt/windows-x86_64/bin
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): Android (8490178, based on r450784d) clang version 14.0.6 (https://android.googlesource.com/toolchain/llvm-project 4c603efb0cca074e9238af8b4106c30add4418f6)
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): Target: x86_64-w64-windows-gnu
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): Thread model: posix
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): InstalledDir: C:/Users/Joe/AppData/Local/Android/Sdk/ndk/25.1.8937393/toolchains/llvm/prebuilt/windows-x86_64/bin
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): NDK toolchain: r25b, NDK version: 250200, ClangVersion: 14.0.6
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): Compiling Native 64-bit code with NDK API 'android-26'
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): Unhandled exception: System.IndexOutOfRangeException: Index was outside the bounds of the array.
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): at EpicGames.Core.FileSystemReference.ContainsName(String name, Int32 offset, Int32 length) in A:\UnrealEngine\UE5\UE_5.2_S\UnrealEngine\Engine\Source\Programs\Shared\EpicGames.Core\FileSystemReference.cs:line 168
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): at EpicGames.Core.FileSystemReference.ContainsName(String name, Int32 offset) in A:\UnrealEngine\UE5\UE_5.2_S\UnrealEngine\Engine\Source\Programs\Shared\EpicGames.Core\FileSystemReference.cs:line 155
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): at UnrealBuildTool.LinkEnvironment.<>c__DisplayClass68_0.<.ctor>b__0(FileItem x) in A:\UnrealEngine\UE5\UE_5.2_S\UnrealEngine\Engine\Source\Programs\UnrealBuildTool\System\LinkEnvironment.cs:line 447
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): at System.Linq.Enumerable.WhereListIterator`1.ToList()
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): at System.Linq.Enumerable.ToList[TSource](IEnumerable`1 source)
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): at UnrealBuildTool.LinkEnvironment..ctor(LinkEnvironment Other, UnrealArch OverrideArchitecture) in A:\UnrealEngine\UE5\UE_5.2_S\UnrealEngine\Engine\Source\Programs\UnrealBuildTool\System\LinkEnvironment.cs:line 447
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): at UnrealBuildTool.UEToolChain.LinkAllFiles(LinkEnvironment LinkEnvironment, Boolean bBuildImportLibraryOnly, IActionGraphBuilder Graph) in A:\UnrealEngine\UE5\UE_5.2_S\UnrealEngine\Engine\Source\Programs\UnrealBuildTool\ToolChain\UEToolChain.cs:line 125
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): at UnrealBuildTool.UEBuildBinary.Build(ReadOnlyTargetRules Target, UEToolChain ToolChain, CppCompileEnvironment CompileEnvironment, LinkEnvironment LinkEnvironment, List`1 SpecificFilesToCompile, ISourceFileWorkingSet WorkingSet, DirectoryReference ExeDir, IActionGraphBuilder Graph, ILogger Logger) in A:\UnrealEngine\UE5\UE_5.2_S\UnrealEngine\Engine\Source\Programs\UnrealBuildTool\Configuration\UEBuildBinary.cs:line 221
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): at UnrealBuildTool.UEBuildTarget.Build(BuildConfiguration BuildConfiguration, ISourceFileWorkingSet WorkingSet, TargetDescriptor TargetDescriptor, ILogger Logger, Boolean bInitOnly) in A:\UnrealEngine\UE5\UE_5.2_S\UnrealEngine\Engine\Source\Programs\UnrealBuildTool\Configuration\UEBuildTarget.cs:line 2455
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): at UnrealBuildTool.BuildMode.CreateMakefile(BuildConfiguration BuildConfiguration, TargetDescriptor TargetDescriptor, ISourceFileWorkingSet WorkingSet, ILogger Logger) in A:\UnrealEngine\UE5\UE_5.2_S\UnrealEngine\Engine\Source\Programs\UnrealBuildTool\Modes\BuildMode.cs:line 882
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): at UnrealBuildTool.BuildMode.Build(List`1 TargetDescriptors, BuildConfiguration BuildConfiguration, ISourceFileWorkingSet WorkingSet, BuildOptions Options, FileReference WriteOutdatedActionsFile, ILogger Logger, Boolean bSkipPreBuildTargets) in A:\UnrealEngine\UE5\UE_5.2_S\UnrealEngine\Engine\Source\Programs\UnrealBuildTool\Modes\BuildMode.cs:line 392
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): at UnrealBuildTool.BuildMode.Execute(CommandLineArguments Arguments, ILogger Logger) in A:\UnrealEngine\UE5\UE_5.2_S\UnrealEngine\Engine\Source\Programs\UnrealBuildTool\Modes\BuildMode.cs:line 248
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): at UnrealBuildTool.UnrealBuildTool.Main(String[] ArgumentsArray) in A:\UnrealEngine\UE5\UE_5.2_S\UnrealEngine\Engine\Source\Programs\UnrealBuildTool\UnrealBuildTool.cs:line 599
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): Took 2.6000151000000002s to run dotnet.exe, ExitCode=6
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): UnrealBuildTool failed. See log for more details. (A:\UnrealEngine\UE5\UE_5.2_S\UnrealEngine\Engine\Programs\AutomationTool\Saved\Logs\UBT-ImmersiveClassroom-Android-Development.txt)
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): AutomationTool executed for 0h 0m 4s
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): AutomationTool exiting with ExitCode=6 (6)
UATHelper: Packaging (Android (Multi:ASTC,DXT,ETC2)): BUILD FAILED
If anyone is packaging for Android in UE5.2, it would really help me out if you told me what JDK/NDK/SDK/Build Tools you are using. If you provide screenshots of the SDK manager and the Android SDK screen of the project settings I’d be very appreciative!