When in Doubt, Build From Source

I’m not a core MonoGame developer, but I try to answer the occasional question on the project’s CodePlex, StackOverflow, GitHub, this blog, etc. For a lot of these questions, I answer back with another question: Did you try building MonoGame from the latest source? Often the answer is “no”, followed by “yeah, that fixed it” or “well I got a little further this time”.

Compared to most software [citation needed], MonoGame is particularly egregious in its disparity between packaged releases and the central repository. Its last official release is still 3.0.1, around 10 months old. This release is not only missing out on 10 months of platform and API improvements, but it has some well-known flaws as well. Like the missing GamePad class. Oops. There’s newer unofficial nightlies that get packaged on the project’s build server, but these have had some packaging flaws of their own. Recently for example (and it might still be a problem), there’s been a mix-up with the WindowsGL and DirectX Windows assemblies. It’s easy to build MonoGame from source though, and it really only requires two steps:

  • Check out a copy of the full MonoGame repository, which will also brings down its dependencies.
  • Open the *.sln file for the platform you want in Visual Studio (or Xamarin Studio), and “build”.

Reference your newly built assembly from your project, or better still, reference the MonoGame *.csproj for your platform directly. If you encounter a failure in the framework, you’ll get the benefit of breaking inside MonoGame and you may get a better stack trace to share with other developers if you need help.

I’m not suggesting you should swear off official releases, but building from source should be one of your standard troubleshooting steps. Do swear off the 3.0.1 release though.

About jaquadro

I am a full time software developer and part time game and game tooling developer.
This entry was posted in Programming and tagged , , . Bookmark the permalink.

11 Responses to When in Doubt, Build From Source

  1. I agree completely. I wonder if we can encourage the MonoGame team to do another official release sometime soon. It would certainly help the situation.

Leave a Reply

Your email address will not be published. Required fields are marked *