IL2CPP Build Fails - il2cpp.exe didn't catch InvalidOperationException

Hi,

I’m trying to migrate us over to 2018.1 and so far all seems pretty solid – but I’m having trouble getting builds working when targeting Mac with IL2CPP. My editor version is 2018.1.1f1 and I’m running the editor on macOS.

Settings are correct as far as I can tell and based on the APIs we use and are able to build with in prior versions (had never tried to build with IL2CPP prior though). Settings are as follows:

Scripting Runtime Version: “.NET 4.x Equiv”
Scripting Backend: “IL2CPP”
API Compatibility Level: “.NET 4.x”
C++ Compiler Config: “Release” (have tried Debug as well, and the log linked below is as verbose as it gets it seems…?)

Full log pasted here: Mac IL2CPP build fails (editor version 2018.1.1f1 on macOS) - Pastebin.com

In the log I subbed my actual username for ‘username’ (real username is all lowercase and contains no numerics, spaces, or special characters – only a…z) and I subbed ‘projectName’ in place of the real project name (which is also all lowercase, no numerics/spaces/special chars – contains only a…z).

Any guidance on further debugging steps or fixes would be much appreciated! :slight_smile: Ty!!

It looks like il2cpp.exe cannot locate the Xcode installation on your machine. It assumes Xcode is installed in /Applications/Xcode. I don’t believe this setting can be configured now. Do you have Xcode installed in a different location?

Thank you! I actually didn’t have Xcode installed at all, instead I just install the CLI Tools (maybe renamed to something else these days via ~ “xcode-select --install” or similar). Is mainly just because it’s a much faster setup, but also because I previously rarely actually needed the full 5.5GB of toolchain.

After the full Xcode install I was able to make a IL2CPP build without issue.

I’m not sure if the entire Xcode install is needed, or if the “CLI Tools” stuff covers what’s actually needed, but low-value suggestion would be to handle that error with human-readable “xcode version X required and not found - please install” or similar. :slight_smile:

Thank you very much, much appreciated – now to see if any runtime performance change, hopefully for the better if anything! =D

1 Like

We’ll look into a better error message, thanks!