I am trying to make use of a C library in an iPhone project. I am very green with iPhone development. My Library
I have been battling for days now to try and get th
As Kay indicated in a comment, if you are trying to build from the command line (or via Make), you must specify the -isysroot $(SDKROOT) flag in order to get the correct headers (otherwise you pick up the host Mac OS X headers, which do not necessarily support ARM).
The easiest thing is to build with XCode, or find a version of the library designed to build for iOS, but if you must use an existing Make-driven build system, you can adapt it to build for iOS by setting:
TARGETSDK = /Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS4.2.sdk
CC = xcrun -sdk $(TARGETSDK) gcc
CFLAGS = -arch armv7 -isysroot $(TARGETSDK) ...
You will want to use similar xcrun commands for other tools used in your build.