Re: CFBundleGetFunctionPointerForName
Re: CFBundleGetFunctionPointerForName
- Subject: Re: CFBundleGetFunctionPointerForName
- From: Alastair Houghton <email@hidden>
- Date: Thu, 13 Mar 2008 18:43:43 +0000
On 13 Mar 2008, at 18:32, Steve Checkoway wrote:
On Mar 13, 2008, at 9:09 AM, Sherm Pendley wrote:
In my experience, CFBundleGetFunctionPointerForName wants symbols
to be
prefixed with an underscore - that is, _model_call. They're stored
that way
in the binary (it's a C thing) and the function doesn't appear to
add it for
you before searching.
I'm pretty sure it is not a C thing and that nothing is mentioned in
the standard.
Linux, for example, does not prefix its symbols with underscores.
I'm pretty sure it's just Mac thing.
IIRC it's an assembler thing. It happens because the native
assemblers on some systems don't require any prefix when talking about
registers, which would interfere with C symbols with similar names
(e.g. you couldn't have a global called "d0" on some 68K platforms
without the '_' prefixes).
A *lot* of platforms use the '_' prefix convention for this reason.
OTOH I don't recall whether Linux is one of them; some platforms hide
the '_' prefixes from their dynamic linker APIs.
Kind regards,
Alastair.
--
http://alastairs-place.net
_______________________________________________
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