Update: Moma 1.0 reports some false positives, see the post here for some explanations.
Jonathan Pobst wrote a very nice tool, the Mono Migration Analyzer (Moma) a tool that can be used by Windows .NET developers to evaluate whether their software will need any modifications to run on the Mono supported platforms, here is the welcome screen:
Moma works by analyzing all the instructions that the code contains and all the references to external types and assemblies (.exe and .dll files). The analysis is done using Cecil, a library used to examine, introspect and manipulate ECMA CIL images.
The first step is to select the assemblies to analyze:
During the analysis, Moma will look for any references to methods, fields, properties or events that the program does on external assemblies and report any of the following problems:
[MonoTODO ("In Mono this is controlled by the --share-code flag")] public LoaderOptimization LoaderOptimization { // implementation details. }
After analyzing your code, Moma will then present a summary of the issues found in your application:
The report is a summary of the issues identified by Moma. You can get a detailed report of issues by clicking on "View Detailed Report". This new report is what you will be using when you go through your application making sure that your code is portable, the report looks like this:
Finally, you can help us prioritize which classes and features are most important, you can do so by submitting the report to our team:
I used Moma in a couple of applications from third party vendors that we are interested in bringing to Linux. The results so far are very promising as we are not missing that much.
The majority of the problems so far have been in sections of code that P/Invoke to get to some features not available in the framework, things like preferences, recently used documents, CPU detection and a handful of features to get information about windows, items on the screen and a few more.
To help port those applications we will be creating a portability assembly that will provide an API that Windows developers can call and will provide the proper native equivalent on Linux, Windows and OSX.
You can download Moma 1.0.1 from here.
Update New version is here.
Posted on 27 Nov 2006