Xcode - Building for Multiple Targets Simultaneously

Viewed 8281

I have one Xcode project with multiple targets. During development, it is becoming laborious to compile and install each separately.

Is there a way, through scripting or otherwise; that I can automate the build and install to device of multiple targets at once.

Many thanks in advance!

4 Answers

In Xcode, within Product > Scheme > Manage Schemes, you'll see a list of schemes that were automatically added, i.e. one scheme for each target in the project. Edit the active scheme, then from the Build phase of that scheme add the secondary target. Now when you clean or build this project using the active scheme, it will clean or build both targets.

Note: the active scheme is shown checked on the Product > Scheme menu.

Related