Unable to build Android after building Engine from source

Hi.
I am trying to build Unreal Engine 4.14 from the source for android development.

I followed Building Unreal Engine from Source | Unreal Engine 5.2 Documentation for building Unreal Engine in Visual Studio Community 2015

However, when trying to build the Android specific modules as per the steps mentioned at A new, community-hosted Unreal Engine Wiki - Announcements - Epic Developer Community Forums, I notice the following error:

11>  [269/271] clang++.exe Module.CinematicCamera.cpp [armv7-es2]
11>  [270/271] clang++.exe UMG.generated.cpp [armv7-es2]
11>  [271/271] clang++.exe UE4Client-armv7-es2.so
11>clang++.exe : error : no such file or directory: 'C:/Data/Projects/UnrealEngine/UnrealEngine/Engine/Build/Android/Prebuilt/bsdsignal/lib/armeabi-v7a/libbsdsignal.a'
11>ERROR : UBT error : Failed to produce item: C:\Data\Projects\UnrealEngine\UnrealEngine\Engine\Binaries\Android\UE4Client-armv7-es2.so
11>  Total build time: 1544.52 seconds
11>C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V140\Microsoft.MakeFile.targets(41,5): error MSB3075: The command "..\..\Build\BatchFiles\Build.bat UE4Client Android Development -waitmutex" exited with code 5. Please verify that you have sufficient rights to run this command.

The full build log is attached in this file: build_log.txt .

I have installed the android ndk (r12b), sdk, ant, gradle, jdk etc. as per the CodeWorks r15 installation file in the code. I have the version 4.12 installed/downloaded via the UE launcher and it contains the libbsdsignal.a file.

If I need to proved any other information please let me know.

I got it fixed.
For some reason, codeworks didn’t update the PATH variable in windows correctly.
I had to update the PATH variable manually, and rebuild the windows and android solutions completely.

Thanks, this helped me get on the right track. My steps:

  • Update env variables
  • Restart PC
  • Run setup.bat to download Android development files
  • Rebuild UE4 project for Android | Development

It’s pretty old thread, but I add the comment for future users.

In my case, the Android prebuilt library ‘bsdsignal’ is not copied properly from ‘src’ to ‘lib’ directory.
If you go to that directory, **C:\unreal-engine-path\Engine\Build\Android\Prebuilt\bsdsignal\ ** you can see the build.bat batch file and its contents are:

set NDK_PROJECT_PATH=src
call ndk-build APP_ABI="armeabi-v7a x86" APP_PLATFORM=android-21
copy src\obj\local\armeabi-v7a\libbsdsignal.a lib\armeabi-v7a
copy src\obj\local\x86\libbsdsignal.a lib\x86

As you can see, it copies the lib files from ‘src’ and paste into ‘lib’.
Unfortunately, there is no ‘lib’ folder at that time and operation ‘copy’ does not create it even though it is necessary.

In conclusion, you can fix this problem by creating target folders manually (or modifying the batch script).

EDIT: The following was fixed by starting over with a clean UE4-OVR source build and SDK install.

I am having this issue, which I think is the same as yours, but I can’t figure out how to fix it:

UATHelper: Packaging (Android (ASTC)):
clang++.exe: error: no such file or
directory:
D:/UE4/UE_4.21_OculusVR/Engine/Build/Android/Prebuilt/bsdsignal/lib/armeabi-v7a/libbsdsignal.a

UATHelper: Packaging (Android (ASTC)):
clang++.exe: error: no such file or
directory:
D:/UE4/UE_4.21_OculusVR/Engine/Build/Android/Prebuilt/bsdsignal/lib/x86/libbsdsignal.a

I checked the D:/UE4/UE_4.21_OculusVR/Engine/Build/Android/Prebuilt/bsdsignal/src folder, but I don’t have the obj folder in there (which I assume it tries to copy \local\armeabi-v7a\libbsdsignal.a from).

Could you give me any pointers on how you fixed it?
Thanks!

Can you share which variable exactly you updated?