Tech Ads

Back to Article List

Originally published April 2004 [ Publisher Link ]

.NET on Linux


More than 2 years have passed since Microsoft announced it's .NET initiative -- 2002 -- and made their first tools available for their Windows operating system, fortunately since then, other tools have also evolved that allow you to run .NET applications on Linux platforms, in this article we will be addressing the series of current tools that allow you to do just that.

Before we describe any specific .NET Linux tools, it should be pointed out that .NET is not just a software development platform from Micrsoft's perspective, but a company wide initiative that encompasses a wide array of areas, so in this sense a .net suffix on a Windows slogan does not necessarily imply there will be a Linux counterpart, this is also based on the technical fact that some parts of .NET are operating system independent, like the single sing-on offered by Passport.Net just to mention one aspect.

That said, in the following sections we will be analyzing the two mainstream .NET Linux development tools which have been created to date : Mono and DotGNU .

Mono is an Open-Source project previously developed by Ximian, now supported by Novell (by acquisition of Ximian) which was the brainchild of GNOME pioneer Miguel de Icaza. Among his primary motivations for starting work on Mono were basically the same features Microsoft touts as it's own technical merits, which he cites as follows :

  • Cross-language integration.
  • APIs that are exposed to multiple languages.
  • Contract/interface based programming.

Mono's primary component is the Common Language Runtime (CLR) which offers the environment in which you execute .NET byte-code also known as MSIL ("Microsoft Intermediate Language"), if you are familiar with the Java platform, the CLR is similar in nature to the Java Runtime Environment, which allows the execution of Java byte-code in an operating system independent manner.

Besides the execution of .NET byte-code, Mono also offers the set of foundation class libraries needed to create .NET applications on the wide array of incarnations available for the framework, like Web Applications through ASP.NET and ADO.NET, Windows Forms & Web-Services. This particular segment of Mono can be considered a work in progress, although it does offer the most common classes used in the creation of .NET components, it does lack some implementations when compared to the .NET distribution offered by Microsoft for Windows platforms.

Language wise, Mono offers a C# compiler and a less developed VisualBasic.NET compiler to create MSIL, these allow you to use either C# or Visual Basic for creating your .NET applications on your Linux environment, for the moment these are the only two languages supported by Mono, although there is a todo list for other compilers like J#, which in the near future will permit you to create .NET byte-code from your Java classes.

For hosting .NET applications developed for web environments - those in ASP.NET - Mono offers two alternatives : A standalone Web-Server named XSP or an Apache module dubbed mod_mono, both of which will allow you to execute the same ASP.NET assemblies created for IIS and be run on Linux platforms.

You can obtain the Mono platform at : http://www.go-mono.com/ .

DotGNU is the Free Software Foundation umbrella project for the .NET Framework, under the name Portable.NET it offers a standard based C# compiler and runtime needed to execute common language byte-code as defined by the ECMA-334 and ECMA-335 specifications, much in the same manner as Mono.

However, where these two specs end, both DotGNU and Mono start to show their differences. DotGNU is more focused on the Web-Services area of .NET, this since one of it's main development projects encompasses a complete web-services server which is built on top of Goldwater - another GNU project - which is a lightweight middle-ware platform. Besides this feature, another touted functionality in DotGNU is the ease of integration with phpGroupWare, a web-based GroupWare suite based on PHP.

You can obtain DotGNU at : http://dotgnu.org/ .

If you are a GNU purist you will surely be more interested in the DotGNU implementation, as it builds on other GNU projects, however, Mono also has it's own merits, for one it is more thoroughly developed and has a wider user base probably due to its same GNOME root's, and as with DotGNU, although most of the current development in Mono seems to be tightly aligned with Microsoft's .NET for Windows, it has also branched development sub-projects like Gtk# which is obviously heavily influenced by GNOME's ties.

Even though some of these tools for developing .NET on Linux are still in flux, the run times for executing .NET code are substantially stable, so for the moment you can at least have the benefit of reusing components on both operating systems, and in the near future be able to create the same functionalities offered by the original Windows implementation either through Mono or DotGNU.


Originally published April 2004 [ Publisher Link ]

Back to Article List