Re: Dead stripping of Cocoa classes from static libraries
Re: Dead stripping of Cocoa classes from static libraries
- Subject: Re: Dead stripping of Cocoa classes from static libraries
- From: glenn andreas <email@hidden>
- Date: Thu, 27 Mar 2008 10:40:22 -0500
On Mar 27, 2008, at 10:08 AM, Kai wrote:
I am working on a project which uses static libraries for
structuring. The final application links against the static libraries.
One of these static libraries includes some Cocoa classes. This
works nicely, as long as these classes are referenced by code in the
final application. But if a class is not referenced explicitly, it
seems to be stripped away be the linker. My case is a class which is
instantiated via a nib and never explicitly referenced.
You need to add -ObjC to the "additional linker flags". This tells
the linker to not strip any Objective-C classes, etc... that it may
find even if they aren't directly referenced.
Glenn Andreas email@hidden
<http://www.gandreas.com/> wicked fun!
quadrium | flame : flame fractals & strange attractors : build,
mutate, evolve, animate
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden