iOS < 5 can't load twitter framework

ios, iphone, objective-c, twitter

Solution

You need to "weak link" it. Under "Build Phases" -> "Link Binary With Libraries" select "Optional" for the Twitter framework:

Weak Link Twitter.framework http://www.hypercrypt.net/images/SO10249170.png

Problem

I'm using the instructions here to detect the Twitter framework on iOS 5 devices. The problem is older devices don't have the Twitter library so I get the following error on iOS 4: ``` dyld: Library not loaded: /System/Library/Frameworks/Twitter.framework/Twitter ``` How do I make an app that can use the Twitter framework on iOS 5 and use a different API on iOS 4 and below?

Original source

Related problems