Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Moving to iOS6 I get this linker error with almost all external packages

Tags:

ios6

linker

armv7

"file was built for archive which is not the architecture being linked (armv7s)"

do I need to wait for people to release new binaries or I have a way out,
I get this for GoogleAnalytics Restkit ...

EDIT: problem with Restkit solved with their latest commit, just pull from github,

like image 922
Ali Avatar asked Sep 13 '12 01:09

Ali


2 Answers

Yes, they will have to release binaries which are compiled for armv7s architecture to support the new iPhone 5 A6 processor. In the meantime, you can temporarily compile against only armv7 to continue development on iOS 6 on your current device until those other libraries are updated.

  • Go to Target -> Build Settings -> Architectures
  • Choose "Other..."
  • Add "armv7"
  • Remove $(ARCHS_STANDARD_32_BIT)
  • Done
  • Clean & Build
like image 84
ozz Avatar answered Oct 15 '22 18:10

ozz


EDIT: Problem with Restkit solved, check out the latest commit from github: git://github.com/RestKit/RestKit.git

EDIT: Problem with Google Analytics also solved as of Version 1.5.1 just download the new version.

Just do not forget to remove old binaries, and clean then build.

For things like 'RestKit' that you have the source code, if you clean them separately and then build (making sure that the Architecture includes Armv7s) it works just fine, you get the binaries that you need and then linked properly to your app.

For reason's beyond my understanding, when I changed the target from iOS device to iPhone 6.0 Simulator and did a clean and then build, I could link against Google Analytics as well,

Still building for the "iOS device" (not the simulator) does not work, I get linker errors.

like image 27
Ali Avatar answered Oct 15 '22 17:10

Ali