Skip to content

Targeting Specific Xcode & SDK Versions

kokoabim edited this page Jun 18, 2012 · 5 revisions

Determine Xcode Location(s)

To target a specific Xcode/SDK version, if not already known, you will need to know Xcode's location on the system. To do so, in Terminal type system_profiler SPDeveloperToolsDataType. Xcode's location will be the Location: property.

Verify Developer Tools (i.e. Xcode) Directory Is Correct

After determining Xcode's location, in Terminal type xcode-select --print-path. Does the output of this command match the location given when determining Xcode's location (as above)? If not, in Terminal type: sudo xcode-select --switch (xcode_developer_path) to set the Developer Tools directory (i.e. Xcode's Developer subdirectory) location. Note: replace (xcode_developer_path) to the location of Xcode determined.

Target Xcode Version Before iOSOpenDev Installation

When multiple versions of Xcode are installed, you can indicate which version the iOSOpenDev Installer will use.

  • As root, in Terminal, type: xcode-select --switch (xcode_developer_path). Example: xcode-select --switch /Applications/Xcode-4.4DP5.app/Contents/Developer.
  • Run iOSOpenDev Installer.

Target Xcode Version After iOSOpenDev Installation

After iOSOpenDev has been installed, you can setup additional Xcode versions using the iod-setup tool.

  • In Terminal, type: iod-setup sdk -d (xcode_developer_path). Example: iod-setup sdk -d /Applications/Xcode-4.5DP1.app/Contents/Developer.

Target SDK Version (Must Be After iOSOpenDev Installation)

  • In Terminal, type: iod-setup sdk -sdk (sdk_name). Examples: iod-setup sdk -sdk iphoneos, iod-setup sdk -sdk iphoneos6.0, iod-setup sdk -sdk iphonesimulator.

Target Both Xcode & SDK Versions (Must Be After iOSOpenDev Installation)

  • In Terminal, type: iod-setup sdk -d (xcode_developer_path) -sdk (sdk_name). Example: iod-setup sdk -d /Applications/Xcode-4.5DP1.app/Contents/Developer -sdk iphoneos6.0.