title: Adding a static library to an XCode console application
body: <p>I'm having trouble adding a static library from another Xcode project (<a href="https://github.com/cloudapp/objective-c" rel="nofollow">CloudApp API</a>) to my Xcode project. My project has two targets -- a prefpane bundle, and a console application. I want to add the static library to the console application. Here's what I've done so far:</p>
  
  <ul>
  <li>Created a new workspace</li>
  <li>Added the CloudApp project to my workspace</li>
  <li>Added the libcloud.a file to my "Link Project Binaries" list for the target binary</li>
  <li>Added -ObjC to the "Other Linker Flags" setting for the target binary</li>
  <li>Added $(BUILD_PRODUCTS_DIR) to the "User Header Search Paths" setting for the target binary</li>
  <li>Copied all the relevant headers from the CloudApp project into my project (without adding them to the target) so that I don't get errors from any #import statements</li>
  <li>Edited the scheme for the target binary to require compiling CloudApp first</li>
  <li>Added relevant frameworks to the target (Cocoa, Foundation, CoreFoundation)</li>
  </ul>
  
  <p>Doing all this worked fine when I just had a single Cocoa target (not a console application). But now I'm getting errors in the CloudApp header files I included. Basically things like this:</p>
  
  <pre><code>In CLWebItem.h:
  Unknown type name 'NSImage'
  </code></pre>
  
  <p>Any ideas?</p>