How to Install XCode 10.2, 10.2.1 on MacOS High Sierra or Mac Mojave Old Version

I am using a Hackintosh for my iOs development. Installing or updating macOS is what I fear most because it regularly breaks operating system compatibility and requires lots of time to fix.

And seem like Apple always ’encourage’ developers to update their machine by increasing minimum support OS version of XCode.

  • Xcode 10.2.1 requires a Mac running macOS 10.14.3 or later.

Now I want to update my codebase to Swift 5, a major release of Swift which brings ABI stability, I have no choice but install XCode 10.2 or above.

After searching for some solutions, I have found one and got it works successfully.

  • Download Xcode 10.2.1 via this link and extract it (https://stackoverflow.com/questions/10335747/how-to-download-xcode-dmg-or-xip-file)
  • Edit Xcode.app/Contents/Info.plist and change the Minimum System Version to 10.13.6
  • Do the same for Xcode.app/Contents/Developer/Applications/Simulator.app/Contents/Info.plist (might require a restart of Xcode and/or Mac OS to make it open the simulator on run)
  • After Minimum System Version modification, if there are still forbidden sign in XCode icon, try to rename Xcode app.
  • If there are problems with the simulator, reboot your Mac

I think I will be stuck with XCode 10.2.1 for a long time and will consider update when the next version of macOS available and stable for Hackintosh. XCode 11 is looking good with SwiftUI but only works with iOS 13 so it’s a must wait.