Question

I need to create a static library for existing C code and use that library to create an iphone application. I am using Xcode 4.2. I followed the steps as given in the link below:

http://developer.apple.com/library/ios/#technotes/iOSStaticLibraries/Articles/configuration.html#//apple_ref/doc/uid/TP40012554-CH3-SW1

My queries are as follows:

  1. In the line #import "LibraryName/HeaderName.h", they say for LibraryName I have to include the name of the library (the value of its PRODUCT_NAME build setting). What exactly does it mean? Where can I get that value?
  2. What is the meaning of "Other Linker Flags"? What value should I give for that since my library is in C and I'm writing my application in Objective C?
Was it helpful?

Solution

  1. The LibraryName is the name you gave the library when you created it. It should be the same as the project name and target name (unless you've messed with the settings). You can verify it in the library's Build Settings under Packaging -> Product Name

  2. As you are working in pure C you can ignore this, leave it as it is.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top