Re: NSPrefrencePane with Garbage Collection won't work in System Preferences?
Re: NSPrefrencePane with Garbage Collection won't work in System Preferences?
- Subject: Re: NSPrefrencePane with Garbage Collection won't work in System Preferences?
- From: Greg Parker <email@hidden>
- Date: Fri, 27 Feb 2009 13:21:17 -0800
On Feb 27, 2009, at 12:58 PM, Tobias Zimmerman wrote:
OK, I'm being dense today, but is it the case that the entire bundle
is
marked as GC-required if any piece of it requires GC? If I move the
app out
of the bundle (so it is just the Pane and the framework) does that
make it
no longer GC-required (if the Framework is compiled as "GC-
supported")?
Again, the only parts of my code that touch the system prefs is the
Pane and
the framework, neither of which are compiled with GC-required.
The GC-ness marker applies to individual binaries, not bundle
packages. So your framework can be marked GC-supported, even if it's
inside an app bundle where the app's executable is marked GC-
unsupported.
You can use `otool` to verify the GC-ness of your binaries. If the
value isn't what you want, double-check your compiler settings and
make sure no wrong-GC files leaked in. (The linker should complain
when linking files built with incompatible GC, though.)
% otool -ov -arch i386 /path/to/MyApp.app/Contents/MacOS/MyApp
[...]
Contents of (__OBJC,__image_info) section
version 0
flags 0x02 GC RR
"RR" is support for non-GC ("retain-release"). "GC" is support for GC.
So "GC RR" is GC-supported, "RR" alone is GC-unsupported, and "GC"
alone is GC-required.
--
Greg Parker email@hidden Runtime Wrangler
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden