Running a program on an iOS 5.1 device cannot find the SDK with Xcode 4.5

When I run my project on iOS 5.1 simulator, it shows

yld: lazy symbol binding failed: Symbol not found: _objc_setProperty_nonatomic_copy Referenced from: /Users/apple/Library/Application Support/iPhone Simulator/5.1/Applications/3A003E5F-2C66-494F-BCC1-C3EE82F01464/dogTree.app/dogTree Expected in: /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.1.sdk/System/Library/Frameworks/Foundation.framework/Foundation 

And I do not have 5.1 SDK. But why is the library search path 5.1, not 6.0?

My whole project and work on the iOS 6.0 device, but when I install it on iOS 5.0 or 5.1 devices, it breaks down and displays as the following message.

Please help me, do I need to run iPhone 5.1 simulator for iOS 5.1 SDK?

+7
source share
3 answers

I had the same problem and I found that I just forgot to change the target platform in the included project. Xcode automatically switches the target to the latest iOS when updating. Just changing the goal for the included project fixed it.

+22
source

I ran into a similar problem and solved by setting the deployment target to 4.3 (same as my minimum version of the application) for each static library.

I found that the static library depended on 6.0 by default, and this should result in a lack of library compatibility for the lower version.

+3
source

For libraries like pods, its in the build settings in iOS Deployment Target.

+2
source

All Articles