Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

"Incorrect Architecture" when trying to install iPhone app onto my development device

I have an iPhone 3G (running iOS 4.0) that I use to performance-test my app on my old hardware. I used to be able to use the device without issue, even with Xcode 4.

Somehow, though, when I installed the latest build of Xcode4 (4.0.2 build 4A2002a) I lost the ability to install my app on this older device. When I press the Run button, I get

No provisioned iOS devices are available. Connect an iOS device or 
choose an iOS simulator as the destination.

However, nothing's changed on the device (my provisioning profile is still installed and valid) and this whole process works fine for my primary device, an iPhone 4.

I used the Applications screen in the Organizer to manually install the application onto the phone. This looked more promising, as a progress bar started to fill up and indicated that it was copying files onto the device. However, before finishing, it popped up a message:

An unknown error message 'IncorrectArchitecture', was received from the device. 

and the app never shows up on the phone.

My project's deployment target is 3.1.3 and the "Architectures" field in Build Settings is set to "Standard (armv6 armv7)"

Is there something I'm missing here? Why won't it install and what changed between the first release of Xcode4 and the second release that could have caused this?

like image 641
Bill Avatar asked Apr 28 '11 20:04

Bill


1 Answers

In your target settings (not project settings), make sure you have:

  • Architectures: Standard (armv6 armv7)

  • Valid architectures: armv6 armv7

  • Build Active Architecture Only: No

    (though Yes is usually OK in debug builds when you are using a single testing device)

like image 89
Julio Gorgé Avatar answered Nov 14 '22 11:11

Julio Gorgé