Flutter Doctor : Xcode installation is incomplete

Viewed 14177

I have an app created with Flutter want to build it in IOS. When i want to run simulator or build the I get error ,When I run Flutter doctor I get this error L

Xcode - develop for iOS and macOS
    ✗ Xcode installation is incomplete; a full installation is necessary for iOS development.
4 Answers

I was facing the same issue. I did not installed Xcode from Apple Store. If your scenario is same, you can try below steps,

  1. Open Xcode
  2. Go to Preferences -> Location tab
  3. You will find "Command Line Tools" option. If it is blank, select the Xcode version from list (see image below). It will ask for password or Touchid to update it.
  4. Run flutter doctor again. It should resolve the issue

enter image description here

So, I was facing this same issue, and tried to and copy paste the command already given. Namely

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

But why did it not work? Silly mistake of mine: I have two Xcode versions in my Applications folder. One is called Xcode_12_3_0 and the other Xcode_12_5_1. Make sure that, when you run the command, you also make sure you enter your app's real name. For instance:

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

An answer for us, absent-minded people.

If you already have Xcode and this happens. Just run this command

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

And

sudo xcodebuild -runFirstLaunch

It will automatically show

Related