C# – Mono Resources for Cross Platform Development

ccross platformmononetpinvoke

Is there a site or repository of information about Cross Platform development in mono? Obviously I know about Moma, and the Cross Platform Guidlines and I am using the Visual Studio Tools to run and debug applications in a Virtual Machine, however since I am migrating an old application I have dozens (if not hundreds) of PInvokes to migrate. Surely everyone who does this must have come across these problems before, and have solutions, or suggestions for solutions. Rather than post a hundred, "What is Mono equivalent of the user32.dll GetKeyState()" on stackoverflow (or maybe that is the solution), is there a repository (wiki like Pinvoke.net), or is it hidden in the mono forums from both their search and google search?

To answer the comment below, I am looking for Cross Platform ways of doing API calls. Obviously the best solution is to have a Managed way to do everything, but some kind of reference on how to do it on Windows, Linux and Mac would also be incredibly helpful. From the lack of response I am guessing that no such reference site exists, and perhaps it should be started. Even if the mono project started a wiki that started off with the Application Portability guidelines I am sure that it would grow over time and be of great use to the community.

Best Answer

I had about the same problem recently. I'm going to tell you my success story.

My application use some third party components. Some of them use PInvokes. On first MOMA run there was about 20 places. I replaced one component with similar crossplaform (without PInvokes) - 10 places left. About 5 places I had to code myself (found some workarounds easily) - 5 places left. These 5 places actually never called.

I assume many of our PInvokes are never called too.