Re: Debugging a crash in dyld
Re: Debugging a crash in dyld
- Subject: Re: Debugging a crash in dyld
- From: Fritz Anderson <email@hidden>
- Date: Fri, 24 Apr 2009 09:19:31 -0500
Guesses?
I know it's a lot to plow through, but whenever a poster omits this
amount of detail, someone always asks for it.
— F
On 22 Apr 2009, at 5:01 PM, Fritz Anderson wrote:
iPhone SDK 2.2.1 / Xcode 3.1.2
I ran my iPhone app in Instruments a couple of times, and then went
back to running under the debugger. The app now crashes with
EXC_BAD_ACCESS before entering main().
Backtrace:
(gdb) bt
#0 0x8fe01bef in __dyld__ZN4dyld17setNewProgramVarsERK11ProgramVars
()
#1 0x8fe18196 in
__dyld__ZN16ImageLoaderMachO23setupLazyPointerHandlerERKN11ImageLoader11LinkContextE
()
#2 0x8fe181ee in
__dyld__ZN16ImageLoaderMachO6doBindERKN11ImageLoader11LinkContextEb ()
#3 0x8fe0d490 in
__dyld__ZN11ImageLoader13recursiveBindERKNS_11LinkContextEb ()
#4 0x8fe1062e in
__dyld__ZN11ImageLoader4linkERKNS_11LinkContextEbbRKNS_10RPathChainE
()
#5 0x8fe051ae in
__dyld__ZN4dyld4linkEP11ImageLoaderbRKNS0_10RPathChainE ()
#6 0x8fe07acf in __dyld__ZN4dyld5_mainEPK11mach_headermiPPKcS5_S5_ ()
#7 0x8fe01872 in
__dyld__ZN13dyldbootstrap5startEPK11mach_headeriPPKcl ()
#8 0x8fe01037 in __dyld__dyld_start ()
I've tried cleaning, uninstalling the app from the simulator, and
quitting the simulator. None helped.
Apparently this is a crash in the dynamic loader. GDB has the
following complaint:
warning: Unable to read symbols for "/System/Library/Frameworks/
UIKit.framework/UIKit" (file not found).
(But a similar complaint, this time about CoreGraphics, appears for
another app that still works.)
This is disturbing. I also don't like looking for UIKit in /System/
Library/Frameworks, but maybe that's the same in iPhone OS. The
inspector for the UIKit reference in the project says it's at "/
Developer/Platforms/iPhoneOS.platform/Developer/SDKs/
iPhoneOS2.2.1.sdk/System/Library/Frameworks/UIKit.framework", which
is consistent with the paths for the other two frameworks. Other
applications, including my own, install in the simulator and run
with no apparent problems.
Here is the link command:
======
cd /Users/fritza/scientia/scientia/Directory
setenv MACOSX_DEPLOYMENT_TARGET 10.5
setenv PATH "/Developer/Platforms/iPhoneSimulator.platform/
Developer/usr/bin:/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/
gcc-4.0 -arch i386 -isysroot /Developer/Platforms/
iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator2.2.1.sdk -L/
Users/fritza/Projects/BuildProducts/Debug-iphonesimulator -F/Users/
fritza/Projects/BuildProducts/Debug-iphonesimulator -filelist /Users/
fritza/Projects/BuildProducts/Directory.build/Debug-iphonesimulator/
Directory.build/Objects-normal/i386/Directory.LinkFileList -mmacosx-
version-min=10.5 -framework Foundation -framework CoreGraphics -
framework UIKit -o /Users/fritza/Projects/BuildProducts/Debug-
iphonesimulator/Directory.app/Directory
======
Base SDK is Device - iPhone 2.2.1 (verified in Target/Debug
configuration); ad-hoc SDK is Simulator - 2.2.1".
I've tried using the target inspector, General tab, to remove and re-
add UIKit. No effect.
I think this is some sort of toolchain issue, but I can't put my
finger on it. In a Mac OS target, there are environment variables to
make dyld chattier, but these seem not to be available to me.
Any ideas on how I can proceed?
— F
--
Fritz Anderson -- Xcode 3 Unleashed: Now in its second printing -- <http://x3u.manoverboard.org/
>
_______________________________________________
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
_______________________________________________
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