Extract object (*.o) files from an iPhone static library

Posted by Brett on Stack Overflow See other posts from Stack Overflow or by Brett
Published on 2011-01-02T14:24:11Z Indexed on 2011/01/02 14:54 UTC
Read the original article Hit count: 206

Filed under:
|
|
|

I have a set of iPhone static libraries (a *.a file) in which I only call a few of the classes from. I have used AR in the past (with linux libraries) to extract the object files from the static library, remove the unwanted object files and rearchive.

However, when I try this with an iPhone compliled static library, I get the following error:

ar: CustomiPhoneLib.a is a fat file (use libtool(1) or lipo(1) and ar(1) on it)
ar: CustomiPhoneLib.a: Inappropriate file type or format

Does anyone know how to extract the object files from an iphone compiled static library? Doing thie could potentially reduce the final file size.

© Stack Overflow or respective owner

Related posts about iphone

Related posts about objective-c