Paul A.
Paul A.

Reputation: 597

iOS: Installing Xcode 4.5.2, deploying on iOS 5.1 and 6.0

I currently run Xcode 4.3.3 and developing an app which is currently deployed to iOS > 5.0. Xcode 4.3.3 cannot install to iOS 6.0 and I want to upgrade. I would like to learn about your experiences and what issues that came up when you upgraded to the new Xcode 4.5.2 and to iOS 6. Will this upgrade break or cause any issues installing to iOS 5.1 as I do not want to upgrade my phone to iOS 6 yet?

Can two versions of Xcode exist together so in case there's a problem, I can go back to the previous one that works?

Upvotes: 2

Views: 2850

Answers (1)

Kevin
Kevin

Reputation: 56129

If I recall correctly:

  • XCode will change the deployment target to 6.0, you will need to change it back to 5.0.
  • XCode will change the valid architectures to armv7 armv7s, you will need to ensure all your binary libraries contain a 7s slice, if not you will need to upgrade them or remove the armv7s entry.
  • XCode will add a black image as the -568@2x default. You will need to either provide your own image and adapt your program to accommodate both screen sizes or remove it.

Benefits:

// new dictionary literals:
NSDictionary *dict = @{
    key1 : val1,
    key2 : val2,
    ...
};
// new dictionary accessors, assignment on mutables only
id var = dict[key];
mutableDict[key] = val;

//new array literals and accessors
NSArray *arr = @[a, b, c];
id var = arr[i];
mutableArr[i] = j;

// NSNumber boxing
NSNumber x = @1;
NSNumber y = @(EnumName);
NSNumber z = @YES;
NSNumber w = @(localIntOrDouble);

// Boxing makes dicts even more convenient:
id var  = dictionary[@(EnumName)]; //vs:
id var2 = [dictionary objectForKey:[NSNumber numberWithInt:EnumName]];

And there is a refactoring tool to convert for you.

Upvotes: 2

Related Questions