Search code examples
objective-ciosxcodexcode4xcode4.2

Making a reference in xcode 4.2


How can I make a reference to another project in xcode 4.2? I trying to put Protocol Buffers working in Objective-C but I can't do this:

  1. Open your existing project and a reference to the ProtocolBuffers project found in .
  2. Add a reference to /Classes/ProtocolBuffers.h in your project and add the following line to your pch file: #import "ProtocolBuffers.h"
  3. Get Info on your build target
  4. Add ProtocolBuffers as a Direct Dependency of your build target.
  5. Add libProtocolBuffers.a as a Linked Library of your build target. You may have to do this by dragging and dropping the library from the referenced ProtocolBuffers project to your target's Link Binary With Libraries section.

Solution

  • I solved the problem. For making the reference just add to the main project the xcodeproj file of the another project. And then add as Direct Dependency and Linked Library.