Can't package on Mac in 4.18 (MetalRHI)

Hello,
I have a project that I’m trying to package on MacOS High Sierra using XCode 8.3.3 but I’m getting an error at the linking stage:

[1/5] Link Dwarrows
Undefined symbols for architecture x86_64:
      "_OBJC_CLASS_$_MTLCaptureManager", referenced from:
         objc-class-ref in UE4-MetalRHI.a(Module.MetalRHI.cpp.o)

I’ve tried adding MetalRHI, RHI, and RenderCore to my .Build.cs file, but it didn’t work out.


Additional info: The project is a C++ project that does compile & package on 4.18.1 for Windows 64, and it WAS packaging on Mac in 4.14 (other versions were skipped).

The engine build is 4.18.1 from the launcher.


What am I missing here? Any help is appreciated, thanks!

I have the same issue on a new 4.18.1 project on macOS Sierra and XCode 8.3.1. Blueprint project only.
Works fine on windows.

I haven’t been able to figure this out yet, have you had any luck with it?

I built on another mac with the newest XCode (9.2 I think), so not technically solved buy bypassed.
I should try to update XCode on my mac with the issue and build again.

This worked! Thanks very much :smiley:

I was avoiding the latest xcode because of the Metal “Falling back to runtime compiled shaders, which are slower” issue in High Sierra, but there’s a workaround I didn’t know about (here).

As mentioned by Loeiz, updating XCode to the latest version on the app store resolved the issue.