RE: Version of dynamic library
site_archiver@lists.apple.com Delivered-To: darwin-kernel@lists.apple.com Thread-index: Acibs1ZWOvnqIgggRuOB2+Vurdc7ZAAAGo/g Hi, Well, when I read the fat_header, it gives following values: magic = 3199925962, (bebafeca) nfat_arch = 0 Since the no. of fat_archs is 0, how can I determine the version number in this case. My high level goal is to find the version of the dynamic library when I m given its full path. Regards, Anukriti -----Original Message----- From: darwin-kernel-bounces+anukriti_shrimal=persistent.co.in@lists.apple.com [mailto:darwin-kernel-bounces+anukriti_shrimal=persistent.co.in@lists.apple. com] On Behalf Of Quinn Sent: Friday, April 11, 2008 2:33 PM To: darwin-kernel@lists.apple.com Subject: RE: Version of dynamic library At 12:20 +0530 11/4/08, anukriti_shrimal wrote:
How can I get the version in such files?
You have to parse the fat header to find the architecture you're interested in, and then look up the version number in that specific architecture. The fat header is not very complex; see <mach-o/fat.h> for the details. What's your high-level goal here? There are typically better ways to manage version numbering that to go grovelling around in the image. S+E -- Quinn "The Eskimo!" <http://www.apple.com/developer/> Apple Developer Relations, Developer Technical Support, Core OS/Hardware _______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-kernel mailing list (Darwin-kernel@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/darwin-kernel/anukriti_shrimal%40pers istent.co.in This email sent to anukriti_shrimal@persistent.co.in _______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-kernel mailing list (Darwin-kernel@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/darwin-kernel/site_archiver%40lists.a... This email sent to site_archiver@lists.apple.com
participants (1)
-
anukriti_shrimal