Recently i started a new job where i have to learn to develop iPhone apps, which is pretty cool and interesting, better than android too. But just recently we’ve updated to xcode 4.2, and here lies a few problems, i was part way through a project when we upgraded and then it would no longer deploy to my first gen ipod touch, or the work iPhone 3G we had for testing. Fortunately this was fairly simple to fix, in the build settings near the top there are options for architectures. in the top main one it probably says armv7 ‘$(ARCHS_STANDARD_32_BIT)’ and we want support for armv6 for ipod 1st gen and iPhone3G, click it and select other, now add with the + symbol and type ‘armv6’ without the quotes and click done, it should hopefully say amrv6 ‘$(ARCHS_STANDARD_32_BIT)’ now for all the sub options too, great. Build Active Achitectures Only should be set to No apparrently, and Valid Archetectures should read armv6 armv7.
That should be it for a project started pre xcode 4.2, though its posible that the Compiler for C/C++/Objective-C needs to be set to the other option, which might in turn cause more errors, see how it goes, unless you started the project in 4.2, in which case continue reading in the vain hope something might work.
I thought this was fixed, however the new project that i started in xcode 4.2 still didn’t deploy to my 1st gen ipod, now to fix it i had to change the projectname-info.plist to armv6 only, its an array, item 0 armv6, delete the armv7, others have had success with both in, i had to remove 7. Still not fixed yet, there’s more.
Also ios pre 4 doesn’t recognise a line in the – (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions function of the appdelegate.m file
comment the following line out and add the line underneath, its doing a similar thing but in a way ios 3.1.3 understands
//self.window.rootViewController = self.viewController;
That should work, but it likely will no longer work for ios 5, urgh, i’ve fixed this by using the conditional checks.
float version = [[[UIDevice currentDevice] systemVersion] floatValue];
if (version >= 4.0)
self.window.rootViewController = self.viewController;
This time C/C++/Objective-C had to be set to AppleLLVM Compiler 3.0 for me. Hope this may of helped, if you have any other additions please comment to help others, thanks