Compiling and running monodevelop from VS.NET

I’ve been spending a bit of time on MonoDevelop this week and gathered this information to get going with MonoDevelop.

First of all, you need GTK:
GTK the “GTK# for .NET” binary (just install that)

Also you need this zip file for binaries, or grab them yourself:
ICSharpCode.SharpZip.dll (from mono 2.4/lib)
MonoDoc.dll (from mono 2.4/lib)
Mono.Posix.dll (from mono 2.4/lib)
MonoPosixHelper.dll (from mono 2.4/bin); this will need to be copied next to the MonoDevelop binaries
Mono.Addins.* (compiled version of http://anonsvn.mono-project.com/source/trunk/mono-addins))

Place these files in a directory and add a registry entry for them so VS.NET can find them:

(win64) [HKEYLOCALMACHINE\SOFTWARE\Wow6432Node\Microsoft.NETFramework\v2.0.50727\AssemblyFoldersEx\MonoBinaries] @="D:\Projects\MD-checkouts\bin" (win32) [HKEYLOCALMACHINE\SOFTWARE\Microsoft.NETFramework\v2.0.50727\AssemblyFoldersEx\MonoBinaries] @="D:\Projects\MD-checkouts\bin"

Monodevelop itself can be fetched from:
http://anonsvn.mono-project.com/source/trunk/monodevelop

Then open the sln file in the source dir. Change the Configuration to DebugWin32 and go to Build/Configuration manager. Check all projects except:
GnomePlatform
MacPlatform
MonoDevelop.NUnit (unless you have nunit)
MonoDevelop.XmlEditor.Tests (unless you have nunit)
UnitTests (unless you have nunit)

apply this temporary change (fixed in GTK svn already):

Index: main/src/core/Mono.Texteditor/Mono.TextEditor/TextEditor.cs =================================================================== --- main/src/core/Mono.Texteditor/Mono.TextEditor/TextEditor.cs (revision 134437) +++ main/src/core/Mono.Texteditor/Mono.TextEditor/TextEditor.cs (working copy) @@ -292,7 +292,7 @@ Gtk.TargetList list = new Gtk.TargetList (); list.AddTextTargets (ClipboardActions.CopyOperation.TextType); - Gtk.Drag.DestSet (this, DestDefaults.All, (TargetEntry[])list, DragAction.Ask | DragAction.Default | DragAction.Move |Â DragAction.Copy); + //Gtk.Drag.DestSet (this, DestDefaults.All, (TargetEntry[])list, DragAction.Ask | DragAction.Default | DragAction.Move |Â DragAction.Copy); imContext = new IMMulticontext (); imContext.Commit += IMCommit;

Set the startup Project to Mono.Startup and run it.
When you get a “File in use” error during compiling after you ran it before, open the task manager and kill the mdhost.exe task.

Carlo Kok

Read more posts by this author.