Commit 8b223a40 authored by lliabraa@chromium.org's avatar lliabraa@chromium.org

In iossim, fix default device value for Xcode 6.

The default was "iPhone", but that's not supported in Xcode 6, so use
"iPhone 5" in that case.

Also remove an unnecessary call to |connect| when printing supported
devices on Xcode 6. This call is not needed and just hangs for a few
seconds so remove it (all that's really needed is to load the
CoreSimulation framework.

BUG=390581
TEST=With Xcode 6 installed, build iossim then run iossim with no
optional paramters (e.g. out/Debug-iphonesimulator/iossim path/to/my.app
TBR=rohitrao@chromium.org

Review URL: https://codereview.chromium.org/379863002

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@282075 0039d316-1c4b-4281-b951-d872f2087c98
parent ad18d9bd
...@@ -177,11 +177,7 @@ void PrintSupportedDevices() { ...@@ -177,11 +177,7 @@ void PrintSupportedDevices() {
// TODO(lliabraa): Once all builders are on Xcode 6 this ifdef can be removed // TODO(lliabraa): Once all builders are on Xcode 6 this ifdef can be removed
// (crbug.com/385030). // (crbug.com/385030).
#if defined(IOSSIM_USE_XCODE_6) #if defined(IOSSIM_USE_XCODE_6)
printf("Retrieving supported devices:\n"); printf("Supported device/SDK combinations:\n");
Class simServiceConnectionManagerClass =
FindClassByName(@"SimServiceConnectionManager");
[[simServiceConnectionManagerClass sharedConnectionManager] connect];
Class simDeviceSetClass = FindClassByName(@"SimDeviceSet"); Class simDeviceSetClass = FindClassByName(@"SimDeviceSet");
id deviceSet = id deviceSet =
[simDeviceSetClass setForSetPath:[simDeviceSetClass defaultSetPath]]; [simDeviceSetClass setForSetPath:[simDeviceSetClass defaultSetPath]];
...@@ -757,7 +753,13 @@ int main(int argc, char* const argv[]) { ...@@ -757,7 +753,13 @@ int main(int argc, char* const argv[]) {
NSString* appPath = nil; NSString* appPath = nil;
NSString* appName = nil; NSString* appName = nil;
NSString* sdkVersion = nil; NSString* sdkVersion = nil;
// TODO(lliabraa): Once all builders are on Xcode 6 this ifdef can be removed
// (crbug.com/385030).
#if defined(IOSSIM_USE_XCODE_6)
NSString* deviceName = @"iPhone 5";
#else
NSString* deviceName = @"iPhone"; NSString* deviceName = @"iPhone";
#endif
NSString* simHomePath = nil; NSString* simHomePath = nil;
NSMutableArray* appArgs = [NSMutableArray array]; NSMutableArray* appArgs = [NSMutableArray array];
NSMutableDictionary* appEnv = [NSMutableDictionary dictionary]; NSMutableDictionary* appEnv = [NSMutableDictionary dictionary];
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment