symbol(s) not found for architecture armv6
Asked Answered
M

3

5

Please help me from the below error.

I am working on graphs using 3rd party framework (libIPhonecharting), every thing works fine in simulator, but when I am trying to build .app file to install in IPAD Device I get the below error message.

ignoring file /Users/xyz/Desktop/xyzIPAD/library/4.0/Release-iphoneos/libIPhoneCharting.a, file was built for archive which is not the architecture being linked (armv6)

Undefined symbols for architecture armv6: "_OBJC_CLASS_$_DTCStroke", referenced from: objc-class-ref in DemoLineChart.o "_OBJC_CLASS_$_IPCBar3DChart", referenced from: objc-class-ref in DemoBar3DChart.o "_OBJC_CLASS_$_IPCLineChart", referenced from: objc-class-ref in DemoLineChart.o "_OBJC_CLASS_$_DTCDefaultCategoryDataset", referenced from: objc-class-ref in DemoBar3DChart.o objc-class-ref in DemoLineChart.o "_DTC_STROKE_CAP_SQUARE", referenced from: +[DemoLineChart(Private) getRenderWithRender:] in DemoLineChart.o "_OBJC_CLASS_$_IPCTitle", referenced from: objc-class-ref in DemoBar3DChart.o objc-class-ref in DemoLineChart.o "_DTC_STROKE_JOIN_BEVEL", referenced from: +[DemoLineChart(Private) getRenderWithRender:] in DemoLineChart.o ld: symbol(s) not found for architecture armv6 collect2: ld returned 1 exit status

Mullis answered 31/10, 2011 at 11:36 Comment(1)
first check it which one not available then add armv6 for your xcodeDextro
S
18

Here's how I got this problem:

I added a .h, .m and NIB from another project by dragging them onto my project navigator. Xcode didn't add them to the Build Phases properly.

My solution for this problem:

  • Go to the Target in the navigator menu
  • Click on the "Build Phases" tab
  • Add the .m file to "Compile Sources" (either drag it across, or use the + button)
  • Add the .xib to "Copy bundle resources"
  • Clean and build

It works for me thanks a lot to you

Spiritism answered 2/5, 2012 at 14:31 Comment(3)
I had the same issue, and HimanshuAgnihotri's solution solved it.Vivavivace
I had the same Build Phases problem. Watch out for adding files to the project with the target not checked for Target MembershipEll
It frustrated me lot but finally it resolved. Xcode should take responsibility to do this task automatically. Anyway, Thanks Himangshu.Syneresis
C
2

Few questions: Does you external lb have it's own project file? If so make sure that it is configured to build to arm6 and arm7 properly. Do the same for your main project file for good measure. Also, what version of XCOde are you on? There are significant differences between different versions.

Look at the libs scheme (depending on the version of XCode you are using) and make sure that is configured properly for debugging on the iOS device; I assuem you are building to your own device for debugging purposes: this recommendation is because of : "file was built for archive which is not the architecture being linked (armv6)"

After trying each of these things be sure to clean the entire project before each build.

Hope this helps. I feel your pain XCOde is evil.

Cryptonymous answered 31/10, 2011 at 14:38 Comment(6)
Hi thanks for the answer, please clarify the below questions,Mullis
Santosh, it seems like some text got cut off. Please re add the questions.Cryptonymous
1. How to configure the external lb to armv6 & armv7 and doing same to my main project? 2. I am using xcode version 4.1.2 & ipad 4.3 sdk When I added the 3rd party library into my project, the path of the library will be added into "library paths" in build settings. If I remove the path then it doesn't even work in simulator and if I add it back it works fine in simulator. But in both cases it won't work in Device.Mullis
Well, you do the arm configuring for the lib, as you would for your project, assuming it has its own project file. You might also check this out, since it has some information that might useful for you: #5267076 keep the patch the way it works for the sim. Let me know if that helps.Cryptonymous
Hi mdominick, thanks for the link I had already tried all the solutions provided in that link, but still no use.Mullis
Thanks! The libs scheme is not configured properly for xcode 4.3Ailing
W
0

I solved this issue by adding absent framework to target->Build Phases->Link Binary With Libraries

Warrantable answered 21/2, 2013 at 14:21 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.