How to build a project on Mac

I’ve successfully built the engine from source on macs before.

However right now I’m doing a very simple prebuilt installed version of 4.27.2 from the epic launcher. I made a C++ project and want to just launch the editor, but Xcode is failing to build. It seems like it’s just stuck forever instead of failing. There does appear to be a shaderCompilerWorker failure.

I’d expect a simple preinstalled version of the engine to work out of the box but it doesn’t for some reason.

I think I ran into the same thing long about 4.26.2. I don’t think the shaderCompilerWorker was the problem because that was happening on successful builds. I didn’t resolve it, just left it behind by moving to 5.0 Preview 1 which doesn’t seem to do this. The telltale sign was that it would say only “Build” up in the XCode status line, instead of Build: Planning" (or something like that). If just “Build” came up, I had to force quit, because trying to stop the compile will force you into a hang and you have to force quit anyway. Upon going back and loading the XCode workspace file, the first time it would usually work and the build would proceed, but any subsequent build without closing and reopening XCode would hang. It was a real pain and I installed VS Code to get around it. This had it’s own set of issues but let me limp by up until the move to 5.0 P1.

At that time, about a month ago, I was trying to run the editor and XCode linked. I now have turned off all hot reload as I read that would be soon deprecated and it never worked correctly on mac. I only build separately, and load the editor from the uproject file. I don’t think this had to do with the hang since I was running out of the IDE for debug (which I have also stopped doing). I just mention it because oddities occurred in XCode or in the Editor when attempting to run that way.

While the results may be similar, it sounds like the difference in what you are experiencing is that XCode will never build for you, whereas for me, it would build once, then hang next time. I didn’t bother with 4.27 at all because we needed to get on with 5.0 features, but possibly the symptoms on mac were worse with that version than 4.26.2.

The only thing I can actually offer is that my version of this problem went away by moving to 5.0 P1. This is on XCode 13.2.1 and macOS 11.6. I no longer have build problems. Many oddities of running XCode/macOS with Unreal seemed to go away (like spurious errors that didn’t stop the compile) with the exception of autocomplete for engine and project classes, the 5.0 workspace project still fails to index your project fully in any usable manner.