From 0ca1d4e52a1efcc46c326be7d7b332ec1a2b1ae3 Mon Sep 17 00:00:00 2001 From: Mitko-Kerezov Date: Wed, 13 Apr 2016 09:05:59 +0300 Subject: [PATCH] Pass -destination when building for iOS Simulator Instead of passing architectures pass `-destination` parameter. This prevents a bug in Xcode 7.2 http://www.openradar.me/23857648 --- lib/services/ios-project-service.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/services/ios-project-service.ts b/lib/services/ios-project-service.ts index 345535ae5b..4be3879e18 100644 --- a/lib/services/ios-project-service.ts +++ b/lib/services/ios-project-service.ts @@ -30,6 +30,7 @@ export class IOSProjectService extends projectServiceBaseLib.PlatformProjectServ private $errors: IErrors, private $logger: ILogger, private $iOSEmulatorServices: Mobile.IEmulatorPlatformServices, + private $iOSSimResolver: Mobile.IiOSSimResolver, private $options: IOptions, private $injector: IInjector, $projectDataService: IProjectDataService, @@ -200,10 +201,10 @@ export class IOSProjectService extends projectServiceBaseLib.PlatformProjectServ args = args.concat((buildConfig && buildConfig.architectures) || defaultArchitectures); } else { + let currentSimulator = this.$iOSSimResolver.iOSSim.getRunningSimulator(); args = basicArgs.concat([ "-sdk", "iphonesimulator", - "-arch", "i386", - "VALID_ARCHS=\"i386\"", + "-destination", `platform=iOS Simulator,name=${this.$iOSSimResolver.iOSSim.getSimulatorName(currentSimulator && currentSimulator.name)}`, "CONFIGURATION_BUILD_DIR=" + path.join(projectRoot, "build", "emulator"), "CODE_SIGN_IDENTITY=" ]);