Linking to a Library or Framework
In the project editor, select the target to which you want to add a library or framework.
Click Build Phases at the top of the project editor.
Open the Link Binary With Libraries section.
Click the Add (+) button to add a library or framework.
Select a library or framework from the list and click Add.
Link frameworks and libraries with your project’s object files to produce a binary file using the Link Binary With Libraries build phase. You can link a target’s source files against libraries in the target’s active SDK or against external libraries.
For example, to provide your application with access to audio hardware, link to the Core Audio framework.
External libraries and frameworks are those not provided by the active SDK. They aren’t in the list you see when you click the plus button, but you can navigate to an external item by clicking the Add Other button below the list.
Libraries and frameworks are designated as Required by default, but you can change this designation to Optional. Required libraries must be present on the host computer for the product to load. Optional libraries do not have to be present for the product to load. A Required framework will always be loaded into memory, but an Optional framework will be loaded only if needed. The initial load of the application will be faster if a large library that is never needed is designated as Optional.
The screenshot shows linking to the Core Audio framework.
© 2012 Apple Inc. All Rights Reserved. (Last updated: 2012-01-09)