# Xcode Tips For iOS Security Researchers

**URL:** <https://onehack.st/t/xcode-tips-for-ios-security-researchers/228061>\
**Category:** Tutorials & Methods\
**Tags:** freebies, tips-tricks\
**Created:** [November 7, 2022, 9:50pm UTC](https://onehack.st/t/xcode-tips-for-ios-security-researchers/228061 "2022-11-07T21:50:37Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![WhiteHat](https://onehack.st/user_avatar/onehack.st/whitehat/32/162514_2.png) [@WhiteHat](https://onehack.st/u/WhiteHat)\
**Post date:** [November 7, 2022, 9:50pm UTC](https://onehack.st/t/xcode-tips-for-ios-security-researchers/228061/1 "2022-11-07T21:50:37Z")

</div>

### Reduce Disk Space

- Note: on your own risk

1. If don’t do the watchOS related work, delete:

```auto
/Applications/Xcode.app/Contents/Developer/Platforms/WatchOS.platform/Library/Developer/CoreSimulator/Profiles/Runtimes/watchOS.simruntime

```

1. If don’t do the tvOS related work, delete:

```auto
/Applications/Xcode.app/Contents/Developer/Platforms/AppleTVOS.platform/Library/Developer/CoreSimulator/Profiles/Runtimes/tvOS.simruntime

```

1. If only draw UI by programming, not using `storyboard` etc, delete(better keep it):

```auto
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS.simruntime

```

1. do sim cleaning:

```auto
xcrun simctl delete unavailable

```

1. delete unused device support files:

```auto
~/Library/Developer/Xcode/iOS DeviceSupport
~/Library/Developer/Xcode/watchOS DeviceSupport

```

1. delete `DerivedData`:

```auto
~/Library/Developer/Xcode/DerivedData

```

1. delete `CoreSimulator` cache:

```auto
~/Library/Developer/CoreSimulator/Caches/dyld

```

### Multiple Versions

If don’t care about the UI of Xcode, you don’t need to install two or more Xcode:

1. copy the `XcodeDefault.xctoolchain` from the newer version to

```auto
/Applications/Xcode.app/Contents/Developer/Toolchains/

```

then rename it, and use it later.  
2. copy the `SDK` to:

```auto
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs
/Applications/Xcode.app/Contents/Developer/Platforms/DriverKit.platform/Developer/SDKs

```

and choose the sdk in Xcode’s project config pane.  
3. copy the `DeviceSupport` to:

```auto
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport
/Applications/Xcode.app/Contents/Developer/Platforms/AppleTVOS.platform/DeviceSupport
/Applications/Xcode.app/Contents/Developer/Platforms/WatchOS.platform/DeviceSupport

```

**Enjoy!**
