Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

does mono emulate .NET, or is it just a framework thats compatible with .NET languages?

Tags:

c#

.net

mono

Like, if I write a program on windows using C# and the .NET framework, then drop the code on a Linux machine running mono, will it run exactly the same? Or would I have to rewrite it to work with Mono's libraries?

like image 912
Kefka Avatar asked Nov 23 '25 14:11

Kefka


1 Answers

will it run exactly the same? Or would I have to rewrite it to work with Mono's libraries?

This really depends on what your program does, and how it's written.

If you use pure C# and core .NET framework features that are supported on Mono, they will "just work", with no changes. However, if you use unsupported features (ie: any 3rd party libs built around native interop, or WPF, etc), they will not work.

It's a very good idea to run the Mono Migration Analyzer regularly on your assemblies as you develop them. This will tell you of any incompatibilities.

like image 138
Reed Copsey Avatar answered Nov 26 '25 05:11

Reed Copsey



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!