Re: [Xcode-users] dylib Version Introspection?
Re: [Xcode-users] dylib Version Introspection?
- Subject: Re: [Xcode-users] dylib Version Introspection?
- From: Peter O'Gorman <email@hidden>
- Date: Wed, 01 Oct 2008 10:35:00 -0500
Alexander von Below wrote:
> Hello,
>
> is there an easy way for a dylib to determine its own "current version",
> i.e. the info you get from otool -l ?
You probably know this already, but, see /usr/include/mach-o/ldsyms.h
and /usr/include/mach-o/loader.h.
Use the _mh_dylib_header symbol to find your own mach header and iterate
through the load commands looking for the LC_ID_DYLIB load command, then
take the version information from that.
I do not know if there is an easier way.
Peter
--
Peter O'Gorman
http://pogma.com
_______________________________________________
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