Reputation: 7147
Changed my deployment target to from 8.0 to 7.0.
Using Xcode 6 with latest iOS8 as base sdk. Getting this error when building for iOS7.1 device:
ld: can't link with a main executable file '/Users/Name/Library/Developer/Xcode/DerivedData/Clumsy_Bird-gotvuaeuyvrkzvfqpzsuxpmifimu/Build/Products/Debug-iphoneos/Clumsy Bird.app/Clumsy Bird' for architecture armv7 clang: error: linker command failed with exit code 1 (use -v to see invocation)
How to solve this?
Upvotes: 25
Views: 16185
Reputation: 892
Build settings > IOS deployment target Make sure these values are identical in app and test app targets. Works for me. screen here
Upvotes: 25
Reputation: 18932
I had a mismatch in values between on "Build Active Architecture Only" which was "Yes" for my test app, but "No" for my unit test target. Make sure these values are identical.
Upvotes: 27
Reputation: 131
I followed steps provided by "Evgeny" above, but my project build only when I unchecked "Allow testing Host Application APIs". Thanks "Evgeny"!
Upvotes: 10
Reputation: 37349
Upvotes: 78