Bug 34631 - mono embedding ( mono_runtime_invoke() ) broken on Mac OS X 10.11 'El Capitan'
Summary: mono embedding ( mono_runtime_invoke() ) broken on Mac OS X 10.11 'El Capitan'
Status: RESOLVED FIXED
Alias: None
Product: Runtime
Classification: Mono
Component: JIT ()
Version: 4.2.0 (C6)
Hardware: PC Mac OS
: Normal normal
Target Milestone: (C6SR1)
Assignee: Alexis Christoforides
URL:
Depends on:
Blocks:
 
Reported: 2015-10-07 10:46 UTC by dinkblam
Modified: 2015-11-12 06:34 UTC (History)
5 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:


Attachments
xcode project (127.81 KB, application/zip)
2015-10-07 10:46 UTC, dinkblam
Details


Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on GitHub or Developer Community with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED FIXED

Description dinkblam 2015-10-07 10:46:54 UTC
Created attachment 13221 [details]
xcode project

it seems embedding mono like described on http://www.mono-project.com/docs/advanced/embedding/ is completely broken in 'El Capitan'

i've developed a small sample app. it worked fine until i upgraded to 'El Capitan', now it crashes, either in mono_method_full_name() or in mono_runtime_invoke().

to reproduce download the attachment

1.) open and run test/test.xcodeproj in XCode 7 (needs the mono framework installed in 32 bit)
2.) it should run fine on 10.10 but but crash on 10.11 inside mono_method_full_name() on el-capitan. commenting out the debug output just makes it crash later in mono_runtime_invoke()

i've tried updating to the latest versions available today, i.e
MonoFramework-MDK-4.2.1.macos10.xamarin.x86.pkg
and to
MonoFramework-MDK-4.3.0.1414.macos10.xamarin.x86.pkg
as well as by building from source in 64-bit from: mono-4.3.0.1414.tar.bz2 
but the same problem remains.


any ETA when a functional mono version for embedding the mono runtime on el capitan could become available? i can provide any needed additional information like backtraces, etc
Comment 1 dinkblam 2015-10-13 11:22:22 UTC
i'm not the only one experiencing the issue, there is a discussion about it on the mono-osx mailing list ... the supposed fix is to run the binary outside the debugger

http://lists.ximian.com/pipermail/mono-osx/2015-October/005328.html
Comment 2 Rajneesh Kumar 2015-10-14 06:55:17 UTC
I have checked this issue but not able to reproduce this. To reproduce this issue I have followed the steps and instruction provided in bug description. On OS X 10.11 with Xcode 7.0, I am not able to run the attached test case and on running I am getting following in application output: 

https://gist.github.com/Rajneesh360Logica/e79705d41cee5d24d4c8
Screencast: http://www.screencast.com/t/4v7hlkoInFN0

However I am successfully able to run the attached test sample in Xcode 7.0 on OS X 10.10 successfully.

Screencast: http://www.screencast.com/t/msmqdTuEK

Please let me know that what I am missing/wrong to reproduce this issue?

Thanks..!

Environment Info:


=== Xamarin Studio ===

Version 5.10 (build 815)
Installation UUID: 0b7eaebc-a0ed-4b58-81df-91e378cad28c
Runtime:
	Mono 4.3.0 (master/0421c0c)
	GTK+ 2.24.23 (Raleigh theme)

	Package version: 403001564

=== Xamarin.Profiler ===

Version: 0.0.0.0
Location: /Applications/XamarinProfiler.Mac.app/Contents/MacOS/XamarinProfiler.Mac

=== Apple Developer Tools ===

Xcode 7.0 (8227)
Build 7A220

=== Xamarin.Mac ===

Version: 2.4.0.82 (Business Edition)

=== Xamarin.iOS ===

Version: 9.2.0.87 (Business Edition)
Hash: 3e5d608
Branch: master
Build date: 2015-10-09 16:01:44-0400

=== Xamarin.Android ===

Version: 6.0.99.87 (Business Edition)
Android SDK: /Android SDK/android-sdk-macosx
	Supported Android versions:
		2.3    (API level 10)
		4.0.3  (API level 15)
		4.1    (API level 16)
		4.2    (API level 17)
		4.3    (API level 18)
		4.4    (API level 19)
		4.4.87 (API level 20)

SDK Tools Version: 23.0.2
SDK Platform Tools Version: 20
SDK Build Tools Version: 20

Java SDK: /usr
java version "1.7.0_25"
Java(TM) SE Runtime Environment (build 1.7.0_25-b15)
Java HotSpot(TM) 64-Bit Server VM (build 23.25-b01, mixed mode)

=== Xamarin Android Player ===

Version: 0.6.1
Location: /Applications/Xamarin Android Player.app

=== Build Information ===

Release ID: 510000815
Git revision: 1f1910169d5433415cac632094c57272080ef9df
Build date: 2015-10-08 14:39:26-04
Xamarin addins: a44901897f3e0c6a25c0f12b6a5fcd892faecdbc
Build lane: monodevelop-lion-cycle6

=== Operating System ===

Mac OS X 10.11.0
Darwin Admin-Macs-Mac-mini.local 15.0.0 Darwin Kernel Version 15.0.0
    Wed Aug 26 16:57:32 PDT 2015
    root:xnu-3247.1.106~1/RELEASE_X86_64 x86_64
Comment 3 dinkblam 2015-10-14 07:01:20 UTC
dyld: Library not loaded: /private/tmp/source-mono-mac-crypto-32/bockbuild-xamarin/profiles/mono-mac-xamarin/package-root/lib/libmonoboehm-2.0.1.dylib


i guess your mono framework installation is broken
Comment 4 Rajneesh Kumar 2015-10-14 09:01:55 UTC
Yeh,  I Re-Install the Mono-Framework and Now I am observing that the app showing in the doc (Application Tray) but not getting launched properly, and on hover it is showing busy.

Screencast: http://www.screencast.com/t/i3Ly2M1Bs

And now,  I am observing the following in application output:

2015-10-14 17:33:07.575 test[511:8300] Failed to connect (window) outlet from (AppDelegate) to (NSWindow): missing setter or instance variable

Please let me know that how I can get the crash info as you mentioned in the blog. So that I cam confirmed this issue.

Thanks..!
Comment 5 dinkblam 2015-10-15 05:22:06 UTC
> Please let me know that how I can get the crash info  

you are already seeing the crash, don't you see how starting at second 9 the program stops in the debugger in mono_runtime_invoke() ? thats a CRASH


> and on hover it is showing busy.

thats because the program has crashed and is stopped in the debugger



> 2015-10-14 17:33:07.575 test[511:8300] Failed to connect (window) outlet from (AppDelegate) to (NSWindow): missing setter or instance variable

obviously harmless warning, ignore



> So that I cam confirmed this issue.

you already did
Comment 6 Rajneesh Kumar 2015-10-15 12:33:27 UTC
@dinkblam, Thanks a lot for clarification and confirmation of issue.

Hence as per comment 5 changing its status Needinfo to Confirmed.

Thanks..!
Comment 7 Zoltan Varga 2015-10-23 19:41:52 UTC
I can reproduce this. It only seems to crash when ran from xcode, not when ran from the commandl ine.
Comment 9 dinkblam 2015-11-11 14:27:17 UTC
any chance for a workaround? this bug is kinda a roadblock
Comment 10 Zoltan Varga 2015-11-11 14:53:40 UTC
This _might_ have been fixed by mono master 061f993b6878585a75fbb4de39b89bf3b4aca348:

https://github.com/mono/mono/commit/061f993b6878585a75fbb4de39b89bf3b4aca348
Comment 11 dinkblam 2015-11-12 06:34:33 UTC
thank you very much, i can confirm that 061f993b6878585a75fbb4de39b89bf3b4aca348 fixes the issue