Can't find Xcode install for Metal compiler

Hello,

I’ve just installed UE4, but it seems i can’t launch the program. When i press launch i receive the following message:

“Can’t find Xcode install for Metal compiler. Please install Xcode and run Xcode.app to accept license or ensure active developer directory is set to current Xcode installation using xcode-select.”

I have no idea what this means, and i can’t seem to find anything on my computer relating to “Xcode”.

I hope someone can help me.

Many thanks!

9 Likes

Waiting for the same answer.

3 Likes

You have to install XCode from Apple’s App Store. Unreal uses this to compile your games. Once you install, you have to open Xcode and accept the licensing agreement before Unreal will work.

6 Likes

Opening Terminal and pasting this code worked for me:
sudo xcode-select -s /Applications/Xcode.app/Contents/Developer

157 Likes

This worked for me instantly. Ty!

2 Likes

Same here - thanks for the tip!

Same here – Thanx for the tip!

Sorry not working for me. Help

Download and install Xcode. You may need to move the Xcode application to your application folder on your Mac for UE to begin loading. (If you cant download it from the App store then find the download on Apples website.)

1 Like

worked for me! Thanks. (BigSur, m1 pro, 2020).
Steps:

  1. Install Unreal

  2. Install Xcode

  3. Run Xcode and accept a License

  4. Run Terminal and exec:

    sudo xcode-select -s /Applications/Xcode.app/Contents/Developer

  5. Run Unreal

  6. Create your awesome game and profit!

13 Likes

I had the same problem, I wrote this in the terminal:

sudo xcode-select --reset

2 Likes

Work like charm! Thank you for share!

I’m having the same problem. And after I tried to install Xcode from Apple’s site, I received the msg:

“Xcode can’t be installed on [VolumeName] because macOS version 11 or later is required”
(This machine is on 10.15.7 Catalina and checking under the Apple is says this hardware is up to date. A 2012 MacPro laptop 2.5Gh Dual i5 is probably too old/EOL not supported?)

I also tried the sudo suggestion in Terminal suggested here and received a further error msg:

“[MyUser] is not in the sudoers file. This incident will be reported.”
(I’ll see if I can add it and get past this)

:(. … Any help greatly appreciated. Thank you Community

I have the same issue. I got the following message: Can’t find Xcode install for Metal compiler. Please install Xcode and run Xcode.app to accept license or ensure active developer directory is set to current Xcode installation using Xcode-select.

I opened Terminal and put in: sudo xcode-select -s /Applications/Xcode.app/Contents/Developer
and it asked me to put in password. My laptop password is shown as invalid.

Error Message: xcode-select: error: invalid developer directory ‘/Applications/Xcode.app/Contents/Developer’

I’m using macOS Big Sur v11.4.

Can anyone help??

This worked for me:
Move the Xcode application to your application folder on your Mac for UE to begin loading.

I had to search for an older version of Xcode 12.4 to run on Catalina. It installed to my downloads weirdly. Moved it to Applications and worked.

Have run the sudo commad:
sudo xcode-select -s /Applications/Xcode.app/Contents/Developer

Unreal is now launching but taking a long time to initialize. Hopefully the first time only.
Am missing templates to launch a new project… Is this normal. Should I download from somewhere?

Has anyone had better experience running on Windows than Mac?

I have an extra GPU unit to add to my setup to help run unreal. Anyone else tried this on a Mac?
I am looking to run a GEFORCE RTX 2080Ti in an enclosure.

I also have installed windows on my iMacPro 2017 model but have not tried Unreal on it just yet.
Any tips are welcomed.

1 Like

Have you found a solution? I’ve got the same problem

I ran the code “sudo xcode-select -s /Volumes/Samsung USB/Xcode.app/Contents/Developer” because I have xcode on a usb drive and it returned the error “xcode-select: error: invalid argument ‘USB/Xcode.app/Contents/Developer’
Usage: xcode-select [options]”

this should work it worked for me: write this code is the terminal

sudo xcode-select -s

then go to your Xcode app drag and drop it into the thermal hit enter!!!

2 Likes

I solved this in the following way…

  1. Open Xcode
  2. Go to Xcode preferences (CMD+,)
  3. Find the Location tab
  4. In the last drop down (Command line tools), select the appropriate Xcode version. In my case no version was selected and that was casuing the issue.

Note: The terminal method shown in other answers does the same thing.

5 Likes

Select that “appropriate Xcode version” helped to open the Unreal. But the Xcode itself is the problem: it seems to take all GPU and the Unreal run extremely slow. My iMac also started to keep a quiet hum. That sounds scary.