So, I am trying to build and run an App on my iPhone 5 device. But "suddenly" (Was working fine until I ran archive
to submit to iTunes connect) it is failing with errors. The app is using CorePlot graphing library and the error seems to be occurring in that library.
So, the error is
Text
ld: warning: ignoring file path/to/libCorePlot-CocoaTouch.a, file was built for archive which is not the architecture being linked (armv7): path/to/libCorePlot-CocoaTouch.a
I can understand the error. It basically says that the library was built not for armv7 architecture.
However, to confirm this I ran this terminal command against the static library.
lipo -info libCorePlot-CocoaTouch.a
and the result is,
Architectures in the fat file: libCorePlot-CocoaTouch.a are: armv7 armv7s i386 x86_64 arm64
I can't see a reason why this isn't running. The project compiles and runs on simulator but when I change to device it starts to fail.
What have I tried so far?
- Seeking for solutions on Google - Failed
- Cleaning project and running it again.
- Quitting XCode and restarting it.
- Shutting down Macbook and then restarting it.
- Downloading CorePlot 1.5.1 source files and rebuilding the binary files.
After all above steps and many more. I have same error again and again. I don't know what am I done wrong.
Environment Specs:
- MacBook Pro running OSX 10.9.2
- XCode 5.1.1
- Project > Build Settings > Architectures > Standard architectures (armv7, armvts, arm64)
- Base SDK > Latest iOS (iOS 7.1)
- iPhone 5 with iOS 7.1.1
If it helps, I am sharing the exact binary I am using right now with my app.
Any idea about what am I doing wrong? I know there is like a silly mistake somewhere. But not sure where. Any extra info please comment. I will provide it straight away. I was about to upload my App to iTunes connect.