23

Is there any way to run the .NET exe (of a winform app) in Linux without building the code in linux? In fact I don't have the code for some of the utilities I developed earlier and would like to run them in linux.

Related to : Feasibility of C# development with Mono

Community
  • 1
  • 1
softwarematter
  • 28,015
  • 64
  • 169
  • 263

3 Answers3

33

Mono ! http://mono-project.com/Main_Page

Works great too. There's a growing tool support, C# compiler etc in a growing community.

jottos
  • 20,098
  • 9
  • 30
  • 27
  • 3
    I need to run a .NET exe file. I know that .NET programs can be built using mono. But can we run .NET exe (created in windows) in linux? – softwarematter Apr 29 '09 at 05:34
  • 3
    mono is an implementation of the CLR. assemblies built against the .net framework on windows can be run on mono without recompiling – Hamish Smith Apr 29 '09 at 05:38
  • 3
    yes, we build in visual studio and deploy on linux and run under mono – jottos Apr 29 '09 at 06:26
4

You can test it by using the Mono Migration Analyzer or by actually testing it using the Mono command prompt...covered in this article

Jon
  • 655
  • 3
  • 11
2

Wine + .NET

UnkwnTech
  • 88,102
  • 65
  • 184
  • 229
  • Incorrect answer. .NET applications (IL code) generally cannot be run using wine! – Milen Apr 29 '09 at 06:08
  • I do believe, that .NET (>=2.0 iirc) can be installed in wine. – UnkwnTech Apr 29 '09 at 06:26
  • Check http://appdb.winehq.org/objectManager.php?sClass=application&iId=2586 for the status of running .NET in Wine. It seems 2.0 is Bronze (which means your assembly may or may not run depending on the libs it uses). – Ruben Steins Apr 29 '09 at 07:01