Re: Weird issue loading kernel extension.
Re: Weird issue loading kernel extension.
- Subject: Re: Weird issue loading kernel extension.
- From: "B.J. Buchalter" <email@hidden>
- Date: Wed, 31 Aug 2011 22:09:04 -0400
On Aug 31, 2011, at 8:06 PM, Alexander Klyuev wrote:
> Hi ALL,
>
> I got unexpected issue: my kernel extension doesn't get loaded on Mac OS X 10.4.11 PPC.
> kextload utility outputs the following:
>
> sudo kextload -t -v 6 /System/Library/Extensions/MyDriver.kext > kextload.log
>
> Password:
>
> kld(): /System/Library/Extensions/MyDriver.kext/Contents/MacOS/MyDriver load command 2 unknown cmd field
>
> kextload: kld_load_from_memory() failed for module /System/Library/Extensions/MyDriver.kext/Contents/MacOS/MyDriver
>
> kextload: a link/load error occured for kernel extension /System/Library/Extensions/MyDriver.kext
>
> load failed for extension /System/Library/Extensions/MyDriver.kext
>
> (run kextload with -t for diagnostic output)
>
>
>
> This is the error message (I don't include kextload.log file content because it doesn't shed light on the problem).
>
> MyDriver.kext contains executables for 3 architectures: ppc, i386 and x86_64, however the issue occurs with PPC arch only.
>
> It's built with Xcode 3.2.4 (or so) on SL 10.6.7 using SDK 10.4u (SDK 10.6 is for x86_64 arch only).
This is because the Mach-o file has the UUID field in and the PPC kernel on 10.4.x doesn't understand it. This is a result of using the linker included with the newer Xcodes.
You have to add the following build setting to the project for the ppc build:
OTHER_LDFLAGS = -Xlinker -no_uuid
That one stumped me for a while when I ran into it.
Best regards,
B.J. Buchalter
Metric Halo
http://www.mhlabs.com
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-kernel mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden