方法如下:
1.?開啟老的Xcode安裝路徑(你可以去AppleDevCenter下載老版本的Xcodedmg包,解壓出來對應的SDK包。):Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs.這個路徑中安裝了你當前Xcode的所有BaseSDK(例如“iPhoneOS6.1.sdk”),同樣的你只需將這個sdk備份一份複製到新的xcode相同目錄下即可。
2.安裝完新版Xcode5後同樣將備份的sdk拷到對應路徑:Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs下即可。
3.重啟你的Xcode,開啟ProjectTargets->BuildSettings->BaseSDK,設定為對應的sdk即可(例如ios6)
?這時候你可能會發現執行起來的模擬器還是ios7的,要想模擬器是ios6的,同樣的只需要到路徑/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs下將對應的simulator備份的新得xcode路徑下即可。
方法如下:
1.?開啟老的Xcode安裝路徑(你可以去AppleDevCenter下載老版本的Xcodedmg包,解壓出來對應的SDK包。):Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs.這個路徑中安裝了你當前Xcode的所有BaseSDK(例如“iPhoneOS6.1.sdk”),同樣的你只需將這個sdk備份一份複製到新的xcode相同目錄下即可。
2.安裝完新版Xcode5後同樣將備份的sdk拷到對應路徑:Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs下即可。
3.重啟你的Xcode,開啟ProjectTargets->BuildSettings->BaseSDK,設定為對應的sdk即可(例如ios6)
?這時候你可能會發現執行起來的模擬器還是ios7的,要想模擬器是ios6的,同樣的只需要到路徑/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs下將對應的simulator備份的新得xcode路徑下即可。