Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

As .NET is OS independent how can I run programs built/compiled on .NET 4.0 ?
Can I develop software in Ubuntu for .NET 4.0 [if yes, what i need to download, link] ?

share|improve this question
Right now, not every Feature of 3.5 and 4.0 is supported by mono. Hope you don't need WPF or stuff like that. – mbx Jul 3 '11 at 9:38
up vote 9 down vote accepted


Mono provides the core compatibility API for the .Net framework.

The version in Natty (v2.6.7) has support for both Visual Basic & C# version 2,3 & partial API support for v4.

This also includes a VB .Net compiler & the runtime compiler. The other members of the family, j# and f# are not supported in terms of development. Obviously - their compiled variants are byte compatible with the rest of the .Net family.

Windows Forms up-to version 2 is supported - source

The next version of Ubuntu - 11.10 - will come with mono 2.10 which has virtually complete .Net v4 support

Mono Example Usage

An example of a .Net application which I use that runs without issue on Ubuntu is Keepass 2

You run the compiled .exe [it was created under windows] using mono i.e.

mono Keepass.exe


To develop under Ubuntu, I would have a look at the Mono Develop project - an IDE based environment - search for MonoDevelop in the Software Center.


Take a closer look at the suggested Add-Ons - choose the Add-Ons in the area that you will be developing in.

enter image description here

share|improve this answer
It should be noted that .net 4.0 support was added in mono 2.8, and the current ubuntu has 2.6. So there is no .net 4.0 support in any released ubuntu version. mono 2.10 has however made it into ubuntu 11.10 which is not yet released. – trampster Jul 5 '11 at 22:38
@trampster - many thanks - have updated the answer. – fossfreedom Jul 5 '11 at 22:51

The Mono project offers a compiler and class library for C Sharp compatible with .NET 4.0. The compatibility improves with later versions. Ubuntu contains 2.6.7, I believe, which is the latest long-term stable release. Mono 2.10.2 is the most recent release and has various improvements.

For development, install monodevelop. Ubuntu offers MonoDevelop 2.4. You can grab MonoDevelop 2.6 beta 3 if you're adventurous -- here's a script that installs both Mono 2.10.2 and MonoDevelop 2.6 beta 3.

share|improve this answer
what about VB.NET ? – Sourav Jul 3 '11 at 6:55
  1. I installed using winetricks

    $ sudo apt-get install winetricks
    $ winetricks dotnet40
  2. Copy the file they say in dotnet40 to download to the folder they say

    $ cp gacutil-net40.tar.bz2 ~/.cache/winetricks/dotnet40/gacutil-net40.tar.bz2
  3. Run winetricks again

    $ winetricks dotnet40
  4. Then run your apps with wine

    $ cd .wine/drive_c/Program.../App
    $ wine APP.exe
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.