How do I get a console app working using MonoDevelop on OSX?

Hi there,

I'm using MonoDevelop 2.6 via Unity 3.3 and trying to get a simple console app working so I can test and benchmark csharp classes and algorithms before using them in my unity scripts.

I've gotten a simple test compiling and it produces a binary but it does not run via the mono runtime (I assume this is the way you execute a csharp console app in OSX)?

I'm not referencing any classes from UnityEngine.dll just to keep it simple.

It seems that the issue is with the mono runtime itself via a missing lib?

setenv PKG_CONFIG_PATH "/Applications/Unity/"


setenv PATH "/Applications/Unity/"


dyld: Library not loaded: /Library/Frameworks/Mono.framework/Versions/2.6/lib/libgthread-2.0.0.dylib

Referenced from: /Applications/Unity/

Reason: image not found

Trace/BPT trap

It's the same error when I call the compiled binary through mono.

This libgthread-2.0.0.dylib does not exist or the /Library/Frameworks/Mono.framework for that matter?

Has anyone got this working? Or is there anything I should be doing/installing?


o.k in the spirit of enhancing google-foo I will answer this for myself and y'all.

I'm using tcsh so please convert to your favorite shell language.

setenv MONO_FRAMEWORK_PATH /Applications/Unity/



mono /path/To/Your/Binary

This worked for me in a shell. It's a shame this doesn't happen when you hit 'run' inside MonoDevelop!