TLDR:
- It’s better to use APFS case insensitive file system (just APFS by default) if you want to build the Mac UE from source on your external drive.
- If you use APFS case sensitive file system. There is a reference error at /Engine/Source/Runtime/Launch/Private/Mac/LaunchMac.cpp, line 10. Change “LaunchCppToSwift.h“ to “LaunchCPPToSwift.h“
- And also after successful build in case sensitive file system, it will prompt you “can only run case insensitive file system“. So use the APFS without case sensitive label is the key.
- For the default exFat format, Mac will generate garbage files and block the UnrealBuildTool compiling. Either format to APFS or turn off the following features only for :
The Try and Error Part:
I have tried the source build recently with UE5.7.4.
Download the source code zip file from github.
Since the build file size is large, so I decide to build on my external ssd drive on macbook pro with m1max chip.
following the readme, run Setup.sh, Generate bla bla bla.sh, open the xcode, build shader worker.
But the UnrealEditor target is failed.
Last night it was late, I can not resolve this error:
Showing All Messages
/Volumes/MacExt/UE5.74Src/Engine/Source/Runtime/Launch/Private/Mac/LaunchMac.cpp:10:10: fatal error: 'Apple/LaunchCppToSwift.h' file not found
10 | #include "Apple/LaunchCppToSwift.h"
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
And in the Launch project, I do find this file
In first glance it seems normal, or is it?
But suddenly i have noticed the difference. It’s the “CPP“ vs “Cpp“.
So I modify the LaunchMac.cpp file, change the Apple/LaunchCppToSwift.h to Apple/LaunchCPPToSwift.h and it build successfully.
The root cause is unix/linux file system is case sensitive. It is not a problem in Windows because it’s a historical remained back compatibility to still maintain case insensitive file system. But it proves i’m wrong after the successfully build
Unfortunately, it pops the following error:
So i tried again and formatted my external drive to APFS (without case sensitive label) and success.
Another thing is the exFAT format.
By default, most of the external drive is exFAT for compatibility. But in MacOS, it will generate a ._ prefix file for each new file. So when I tried to build the UE source on exFAT, the compiler throws a lot of errors when building the UnrealBuildTool. It complain about there are so many duplication or import not found in like “._SampleDotNetSourceCode.cs“ file. After reformat the ssd to APFS with case sensitive same as the system drive, it does not compain.
Also you can Google it to turn the auto generate feature off on external drive only. This feature on Mac will generate the .DS_Store, *._ files as metafiles to boost the file system speed.


