Reputation: 3134
I have an app which uses btouch'd bindings for WEPopover. You can find the bindings below with a SAMPLE application that works on both device and simulator:
https://github.com/anujb/monotouch-bindings
I am using that same dll in another app and it works on simulator but causes a crash on device:
Crash Log:
Hardware Model: iPad2,1
Process: MyApp [2905]
Path: /var/mobile/Applications/31F6EA63-F5B5-49A4-B78B-7A0EDE39FF6E/MyApp.app/MyApp
Identifier: MyApp
Version: ??? (???)
Code Type: ARM (Native)
Parent Process: launchd [1]
Date/Time: 2012-01-11 20:56:08.238 -0600
OS Version: iPhone OS 5.0.1 (9A405)
Report Version: 104
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x00000000, 0x00000000
Crashed Thread: 0
Thread 0 name: Dispatch queue: com.apple.main-thread
Thread 0 Crashed:
0 libsystem_kernel.dylib 0x3088932c 0x30878000 + 70444
1 libsystem_c.dylib 0x37d2af54 0x37cdd000 + 319316
2 libsystem_c.dylib 0x37d23fe4 0x37cdd000 + 290788
3 MyApp 0x009c8048 mono_handle_native_sigsegv (mini-exceptions.c:2249)
4 MyApp 0x009f53c4 sigabrt_signal_handler (mini-posix.c:196)
5 libsystem_c.dylib 0x37d35532 0x37cdd000 + 361778
6 libsystem_c.dylib 0x37d2af54 0x37cdd000 + 319316
7 libsystem_c.dylib 0x37d23fe4 0x37cdd000 + 290788
8 MyApp 0x00b450c8 monoeg_g_logv (goutput.c:135)
9 MyApp 0x00b4519c monoeg_assertion_message (goutput.c:155)
10 MyApp 0x0099d080 mono_resolve_patch_target (mini.c:3179)
11 MyApp 0x009bbf5c mono_aot_plt_resolve (aot-runtime.c:3134)
12 MyApp 0x009ca640 mono_aot_plt_trampoline (mini-trampolines.c:768)
13 MyApp 0x003fa930 generic_trampoline_aot_plt (mscorlib.dll.6.s:204591)
14 MyApp 0x00ab3b6c mono_runtime_invoke (object.c:2757)
15 MyApp 0x00a39894 create_exception_two_strings (exception.c:134)
16 MyApp 0x00a3990c mono_exception_from_name_two_strings (exception.c:157)
17 MyApp 0x009f6164 create_domain_objects (appdomain.c:177)
18 MyApp 0x009f6430 mono_runtime_init (appdomain.c:261)
19 MyApp 0x009a2b80 mini_init (mini.c:6584)
20 MyApp 0x009ae728 mono_jit_init_version (driver.c:2233)
21 MyApp 0x00996388 main (main.m:2423)
22 MyApp 0x00008218 start + 32
Update: mtouch --logdev crash report:
Jan 11 21:16:55 unknown SpringBoard[15] <Warning>: Killing MyApp for termination assertion
Jan 11 21:17:00 unknown SpringBoard[15] <Warning>: Reloading application state for 'MyApp' as its modification date or path has changed
Jan 11 21:17:00 unknown SpringBoard[15] <Warning>: Reloading and rendering all application icons.
Jan 11 21:17:03 unknown SpringBoard[15] <Notice>: Posting 'com.apple.iokit.hid.displayStatus' notifyState=1
Jan 11 21:17:03 unknown SpringBoard[15] <Notice>: MultitouchHID: detection mode: 255->0 (deferring until bootloaded)
Jan 11 21:17:03 unknown SpringBoard[15] <Notice>: MultitouchHID: device bootloaded
Jan 11 21:17:03 unknown SpringBoard[15] <Notice>: MultitouchHID: detection mode: 0->0
Jan 11 21:17:03 unknown kernel[0] <Debug>: set_crc_notification_state 0
Jan 11 21:17:07 unknown kernel[0] <Debug>: AppleKeyStore:cp_key_store_action(1)
Jan 11 21:17:07 unknown kernel[0] <Debug>: AppleKeyStore:Sending lock change
Jan 11 21:17:09 unknown UIKitApplication:MyApp[0xba5e][2965] <Notice>: Successfully received USB connection from MonoDevelop on port 10001.
Jan 11 21:17:09 unknown kernel[0] <Debug>: launchd[2965] Builtin profile: container (sandbox)
Jan 11 21:17:09 unknown kernel[0] <Debug>: launchd[2965] Container: /private/var/mobile/Applications/31F6EA63-F5B5-49A4-B78B-7A0EDE39FF6E [69] (sandbox)
Jan 11 21:17:14 unknown ReportCrash[2967] <Notice>: Formulating crash report for process MyApp[2965]
Jan 11 21:17:14 unknown com.apple.launchd[1] <Warning>: (UIKitApplication:MyApp[0xba5e]) Job appears to have crashed: Segmentation fault: 11
Jan 11 21:17:14 unknown com.apple.launchd[1] <Warning>: (UIKitApplication:MyApp[0xba5e]) Throttling respawn: Will start in 2147483642 seconds
Jan 11 21:17:14 unknown SpringBoard[15] <Warning>: Application 'MyApp' exited abnormally with signal 11: Segmentation fault: 11
Jan 11 21:17:14 unknown ReportCrash[2967] <Error>: Saved crashreport to /var/mobile/Library/Logs/CrashReporter/MyApp_2012-01-11-211713_myipads-iPad.plist using uid: 0 gid: 0, synthetic_euid: 501 egid: 0
Upvotes: 1
Views: 1027
Reputation: 19335
This is a known bug in the current stable release (5.0.*). It is fixed in the latest beta (5.1.1) - have in mind though that it is a beta and there are known regressions (for instance, if your application is big, it might not be possible to upload it to device).
You may have success working around the bug if you change the linker options (to link all assemblies)
Upvotes: 1
Reputation: 43543
8 MyApp 0x00b450c8 monoeg_g_logv (goutput.c:135)
The mono runtime is trying to tell you something but that won't show up in the crash log (e.g. you might be running out of trampolines). Try running:
/Developer/MonoTouch/usr/bin/mtouch --logdev
on a terminal window when running your application. The device log should contain the message and/or managed stack trace that will make this easier to diagnose.
Upvotes: 0