2

I currently run into a problem after I updated my xcode to 4.6.

At the beginning, I got lots of linking errors. With the help from other posts, I am be able to solve them. However, new problems always come whenever I solved the previous one.

Right now, I am stuck at "Undefined symbols for architecture armv7" when I try to build the game on devices with release mode (release and debug modes work for simulator, and debug mode works for devices). I have already researched this problem online, but none of the solutions could solve my situation. That's why I want to start a new post.

Let me explain the situation in details:

  1. All the errors are happened at calling methods in libraries.
  2. my libraries works fine with architecture armv7 before (xcode 4.5)
  3. The current value for Architectures in project file is "Standard (armv7, armv7s)
  4. The current value for Current Architecture is "armv7 armv7s armv6"

This is a sample error:

Even though I only showed errors related to libReceiptVerification.multi.a, errors actually happen at other libraries.

//************* From this line **************

Undefined symbols for architecture armv7:

"_OBJC_CLASS_$_NSMutableOrderedSet", referenced from: objc-class-ref in libarclite_iphoneos.a(arclite.o)

"_CFStringCreateWithBytes", referenced from: -[JKSerializer serializeObject:options:encodeOption:block:delegate:selector:error:] in libReceiptVerification.multi.a(JSONKit.o) _jk_cachedObjects in libReceiptVerification.multi.a(JSONKit.o)

"_CFStringCreateWithBytesNoCopy", referenced from: -[JKSerializer serializeObject:options:encodeOption:block:delegate:selector:error:] in libReceiptVerification.multi.a(JSONKit.o)

"_CFDataSetLength", referenced from: __NSStringObjectFromJSONString in libReceiptVerification.multi.a(JSONKit.o)

// *************** Ending Here ***********

So, does anyone has any clue on this problem? Thanks for your help in advance.

2 Answers 2

1

I am having the same problem Solved by setting

Implicitly link Objective-C Runtime Support to NO

You can find it under Project->Build Settings->Apple LLVM Compiler 4.2-Language.

Or search for Implicitly link Objective-C Runtime Support in project->Build Settings

0

Check out the library targets for libarclite, JSONKit and everything else and make sure they also have the identical architecture values set for their Release builds.

Also that "Build Active Architecture Only" is checked to NO for Release targets.

3
  • Thanks for your reply :) "Build Active Architecture Only" is already NO for release mode. And all the targets are set with the same values. The problem is still occurs. Feb 20, 2013 at 19:33
  • did you also do a project clean and restart Xcode for good measure? Feb 20, 2013 at 19:49
  • Oh yes, I clean build before I posted. I not only restarted xcode, but also restarted the mac. :( No luck so far... Feb 20, 2013 at 19:56

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.