Every Flavour Beans

“The time has come…to talk of many [technologies].” –Lewis Carroll(’The Walrus and the Carpenter’)
Development Tools. Web Frameworks. GNU/Linux. Nokia N800. Video Encoding.

October 31, 2007

Installing C#/Mono(.NET)/MonoDevelop/XSP in Ubuntu Gutsy Gibbon(7.10)

Filed under: GNU/Linux, Mono, Ubuntu — tabrez @ 12:33 pm

The reason for not updating the old post that explained how to install C#/Mono/MonoDevelop/XSP packages in Ubuntu Dapper Drake is that the procedure remains pretty much the same for Ubuntu Feisty Fawn as well as the recently released Ubuntu Gutsy Gibbon distributions(but now you get the newer versions of those packages installed, of course). You can just go through that longer post and probably make one or two changes here and there to get everything running under Feisty/Gutsy too.

Do note that Ubuntu Gutsy Gibbon supports installing the more recent stable versions of Mono(1.2.4) and MonoDevelop(1.4) right from its package manager than any other distribution(AFAIK). Mono 1.2.5 is released but it is not available even in Gutsy. All other distribution either install the older versions of Mono and MonoDevelop or make you compile these packages from the sources(which is a good idea even on Gutsy if you want Mono 1.2.5 or some bleeding-edge version of MonoDevelop).

Below is a command running which will get most of the packages related to Mono and MonoDevelop installed on your Ubuntu Gutsy Gibbon(7.10) operating system. The only changes you can notice here are the missing mono-gac package(as it comes installed by default in Gutsy) and the addition of monodevelop-query and libnunit-doc packages. Drop the packages that you don’t want from the command line, and remember that dependencies will be automatically pulled by apt if you accidentally drop any needed packages, so don’t worry too much about it.

sh# sudo aptitude install mono mono-gmcs mono-utils monodevelop monodoc mono-xsp monodoc-http monodoc-ipod-manual monodoc-njb-manual monodoc-nunit-manual monodoc-gtk2.0-manual monodoc-gecko2.0-manual monodoc-ipod-manual monodoc-njb-manual monodoc-nunit-manual monodoc-gecko2.0-manual mono-xsp2 monodevelop-java libnunit-doc monodevelop-nunit monodevelop-versioncontrol monodevelop-query

A lot has changed in the Mono world in the past year but I will leave it up to you to explore the changes according to what version you are interested in. Here are some links to get you started:

What’s new in MonoDevelop 0.14 (stable version available for Gutsy)
What’s new in MonoDevelop 0.15 (stable version but not available for Gutsy, need to compile from sources)
What’s new in MonoDevelop 1.0 Beta 1 (0.16) (unstable version, need to compile from sources)
What’s new in Mono 2.1.4 (stable version available for Gutsy)
What’s new in Mono 2.1.5 (stable version but not available for Gutsy, need to compile from sources)

Keep track of Mono development(RSS)


If you want to receive future posts by email, enter your email address here:

Related Posts:

  • Finally Got 3D Desktop Effects in My Ubuntu Gutsy (ATI Hardware)
  • ‘wget -c’ Bug in Download Script Generated by Synaptic in Ubuntu 7.10(Feisty Fawn)
  • Installing Sun Java SE 6, Apache Maven 2 and Tomcat 5.5 on Ubuntu GNU/Linux
  • Installing Grails in Ubuntu GNU/Linux Using Package Manager
  • Installing C++ Boost on Gentoo and Debian/Ubuntu
  • Installing Ubuntu & Kubuntu Dapper(6.06 LTS) For NVidia GeForce Cards
  • Writing Your First Program With Mono And MonoDevelop

  • Readers who viewed this page, also viewed:


    July 22, 2006

    Create ASP.NET 1.0 & 2.0 Applications On GNU/Linux and Windows Using Mono XSP

    Filed under: GNU/Linux, Gentoo, Mono, Web — tabrez @ 12:39 pm

    This post assumes that Mono is installed on your system. The following links should help if it is not installed.

    Installing Mono on Gentoo and Ubuntu 5.10
    Installing Mono and XSP on Ubuntu 6.06
    Installing Mono and XSP on Fedora

    Installing Mono XSP on Gentoo

    #emerge xsp xsp2

    Installing Mono XSP on Debian/(K)Ubuntu

    #sudo apt-get install xsp xsp2

    Installing Complete Mono Environment(Mono, GTK#, XSP) on MS Windows

    1. Download the Mono installation file for MS Windows from the Mono website.
    2. Run the installer and follow the installation wizard.

    Go to the Mono menu in the Start menu(Start->All Programs->Mono[version]) to access all the applications installed as part of Mono.

    Your First ASP.NET 1.0 Application Using Mono XSP

    1. First create a directory to store the ASP.NET files and change to that directory. You can create the directory in your home directory.
      sh# mkdir aspnet && cd aspnet
    2. Create a sample ASP.NET page. Copy and paste the following code in two separate files(hello.aspx and hello.aspx.cs).
      hello.aspx
      HTML:
      1. <%@ Page language="c#" src="hello.aspx.cs"
      2.                     Inherits="HelloApp.HelloPage" AutoEventWireup="true" %>
      3.     <title>First Mono ASP.NET 1.0 Application</title>
      4.   </head>
      5.     <H1>Welcome to my page!</H1>
      6.     <form  runat="server">
      7.       Enter your name: <asp:TextBox id="name" runat="server" />
      8.       <asp:Button id="greet" Text="Greet" onClick="OnGreetClick" runat="server"/>
      9.     </form>
      10.     <br /><strong><asp:Label id="message" runat="server">Hello, World!
      11.             </asp:Label></strong>
      12.   </body>

      hello.aspx.cs
      C#:
      1. using System;
      2. using System.Web.UI.WebControls;
      3.  
      4. namespace HelloApp
      5. {
      6.    public class HelloPage : System.Web.UI.Page
      7.    {
      8.       protected Label message;
      9.       protected Button greet;
      10.       protected TextBox name;
      11.  
      12.       public void OnGreetClick(Object sender, EventArgs e)
      13.       {
      14.           message.Text = "Hello, " + name.Text;
      15.       }
      16.    }
      17. }

    3. From the same directory('aspnet'), start the XSP server:
      sh# xsp

      (you can press ENTER to terminate the XSP server process)

    4. Open a web browser, type the url http://localhost:8080/hello.aspx and press ENTER. You should see a web page with a text box and a message. Enter a name in the text box and click the "Greet" button to see the personalised greeting displayed.

    On MS Windows, go to the Mono menu in the Start menu(Start->All Programs->Mono[version]), select "Mono[version] Command Prompt" menu item. Create a directory(say 'c:\programs\aspnet'), change to that directory and copy the above two files in that directory. From the same directory, run 'xsp' commad to start the XSP webserver. Open a web browser and access the url http://localhost:8080/hello.aspx.

    Your First ASP.NET 2.0 Application Using Mono XSP

    To develop ASP.NET 2.0 applications using Mono XSP server, start 'xsp2' webserver instead of 'xsp'. Create a test ASP.NET 2.0 page(say 'hello2.aspx') and copy it in a folder. Run the following command from the same folder:

    sh# xsp2

    Go to http://localhost:8080/hello2.aspx to test the ASP.NET 2.0 page.


    If you want to receive future posts by email, enter your email address here:

    Related Posts:

  • Installing C#, Mono(.NET) & MonoDevelop in Ubuntu Dapper Drake 6.06
  • Installing C#/Mono(.NET)/MonoDevelop/XSP in Ubuntu Gutsy Gibbon(7.10)
  • C# & MonoDevelop (.NET) on Gentoo and Ubuntu
  • Writing Your First Program With Mono And MonoDevelop
  • Setting Up Rails Development Environment on Fedora GNU/Linux
  • “Hello, World” Web Application in Ruby on Rails using console
  • My Favourite Note-Taking Applications

  • Readers who viewed this page, also viewed:


    June 28, 2006

    Writing Your First Program With Mono And MonoDevelop

    Filed under: GNU/Linux, Mono — tabrez @ 10:18 pm

    Installing Mono And MonoDevelop on Gentoo and Debian/Ubuntu(5.10)
    Installing Mono And MonoDevelop K/Ubuntu(6.06)

    Mono applications can be developed using any text editor and the mono compiler(mcs). Type the following program in your favourite editor:

    C#:
    1. using System;
    2. namespace FirstMono
    3. {
    4.     class Hello
    5.     {
    6.         public static void Main(string[] args)
    7.         {
    8.             Console.WriteLine("Hello World!");
    9.         }
    10.     }
    11. }

    C# Program in MonoDevelop IDE

    Now go to a shell prompt and compile and run the program:

    sh# mcs Hello.cs
    sh# mono Hello.exe

    You can copy the same Hello.exe file to a Windows machine and execute it there; you get the same output.

    To create a C# application using the MonoDevelop development environment, follow these simple steps:

    1. Start Monodevelop from the GNOME/KDE menu.
    2. Select 'File->New Project' or press Ctrl-Shift-N to create a new Project/Solution. Select "C#" in the left pane and "Console Project" in the right pane of the dialog box.
    3. Type 'FirstMono' as the project name(in Location->Name field) and press the "New" button. You will see a sample C# file created in the open window(sample code is not created if "Blank Project" is selected in the "New Solution" Dialog box). Modify the string passed to the WriteLine() method if you wish.
    4. Select "Run->Build Solution" to build the project. Run the project using "Run->Run"(or press "F8"). The output is displayed in the Application Output window at the bottom.
    5. C# Program in MonoDevelop IDE

      Most of the frequently used operations(like "Build Solution", "Run" etc) can be invoked from the toolbar buttons too.


    If you want to receive future posts by email, enter your email address here:

    Related Posts:

  • Installing C#/Mono(.NET)/MonoDevelop/XSP in Ubuntu Gutsy Gibbon(7.10)
  • Installing C#, Mono(.NET) & MonoDevelop in Ubuntu Dapper Drake 6.06
  • C# & MonoDevelop (.NET) on Gentoo and Ubuntu
  • Create ASP.NET 1.0 & 2.0 Applications On GNU/Linux and Windows Using Mono XSP
  • C++ Boost Filesystem Library(Part III): Example Programs
  • C++ Boost Filesystem Library(Part II): Example Programs
  • Boost Filesystem Library: Writing Portable C++ Programs to Acess The Filesystem

  • Readers who viewed this page, also viewed:


    June 8, 2006

    Installing C#, Mono(.NET) & MonoDevelop in Ubuntu Dapper Drake 6.06

    Filed under: GNU/Linux, Mono, Ubuntu — tabrez @ 8:53 pm

    Installing the complete Mono environment, including the runtime, the compiler and the development environment(MonoDevelop), is no more difficult in Ubuntu 6.06 than it was in Ubuntu 5.10.(The procedure for installing Mono for Kubuntu 6.06 is also similar, but GTK and related packages are needed to install the MonoDevelop IDE, which will be a big download if GNOME is not already installed.) After adding Multiverse and the Universe repositories to the Ubuntu source list, run the following commands in a shell(or use Synaptic/Adept Package Managers):

    sh# sudo apt-get install mono mono-gmcs mono-gac mono-utils monodevelop

    Except 'mono' all other packages are optional. mono-gmcs is C# 2.0 compiler(By default, mono-mcs C# 1.0 compiler is installed). MonoDevelop is a GUI development environment for Mono development(primarily). The above command will also install the Mono documentation manual(monodoc-manual). For a standalone Mono documentation browser, install monodoc-browser. If you prefer to read the documentation in a web browser, then install monodoc-http(which needs mono-xsp):

    sh# sudo apt-get install monodoc mono-xsp monodoc-http

    In the above command, monodoc package automatically installs monodoc-browser. Now you can view Mono documentation either in the stand-alone browser or in the web browser, by selecting the appropriate menu item from the GNOME/KDE menu:
    MonoDevelop Menu Items
    Click the Monodoc(Documentation Browser) to browse through various help topics on Mono development:
    Mono Documentation Browser
    You can install many other Mono based development manuals too, like Mono iPod manual, Mono njb manual(njb is a library used to talk to Creative MP3 Players etc), Mono NUnit manual etc.

    sh# sudo apt-get install monodoc-ipod-manual monodoc-njb-manual monodoc-nunit-manual monodoc-gtk-manual monodoc-gtk2.0-manual monodoc-gecko2.0-manual

    Search for more documentation packages using 'sudo apt-cache search mono | grep manual' command or using Synaptic/Adept Package Manager.

    The following related tools are also available in the repositories:
    monodevelop-java: To develop Java applications in MonoDevelop. Needs Java to be installed.
    monodevelop-nunit: NUnit support in MonoDevelop. Strongly recommended.
    monodevelop-versioncontrol: Only subversion is supported(no CVS).

    sh# sudo apt-get install monodevelop-java monodevelop-nunit monodevelop-versioncontrol

    mono-xsp is a standalone webserver that can be used to run ASP.NET 1.0 & 1.1 applications. mono-xsp2 runs ASP.NET 2.0 applications.

    sh# sudo apt-get install mono-xsp mono-xsp2

    If you would rather host the ASP.NET applications through Apache webserver, then you need mono-apache-server package. Note:

    mono-apache-server + libapache-mod-mono --> Apache 1.3
    mono-apache-server + libapache2-mod-mono --> Apache 2.0

    Similarly, mono-apache-server2 is for ASP.NET 2.0.

    sh# sudo apt-get install mono-apache-server2 libapache2-mod-mono

    This will automatically select the mono-apache-server2 package. Remember that this will also install Apache server and related packages if they are not already installed. The next post will be about creating a sample Mono program using the MonoDevelop development environment.


    If you want to receive future posts by email, enter your email address here:

    Related Posts:

  • Installing C#/Mono(.NET)/MonoDevelop/XSP in Ubuntu Gutsy Gibbon(7.10)
  • Writing Your First Program With Mono And MonoDevelop
  • Create ASP.NET 1.0 & 2.0 Applications On GNU/Linux and Windows Using Mono XSP
  • C# & MonoDevelop (.NET) on Gentoo and Ubuntu
  • Killer Looks of KDE in Kubuntu Entices a Long Time GNOME User!
  • Installing Sun Java SE 6, Apache Maven 2 and Tomcat 5.5 on Ubuntu GNU/Linux
  • Installing Ubuntu & Kubuntu Dapper(6.06 LTS) For NVidia GeForce Cards

  • Readers who viewed this page, also viewed:


    March 3, 2006

    C# & MonoDevelop (.NET) on Gentoo and Ubuntu

    Filed under: GNU/Linux, Gentoo, Mono, Ubuntu — tabrez @ 9:03 am

    .NET developers looking for a similar development framework on the GNU/Linux operating system should check out the Mono project. It's fairly simple to install Mono on most of the GNU/Linux platforms and to start developing applications using the C# language. But beginner programmers would love to have an easy to use IDE which could integrate all the tools required for C# based development in one place. One such tool is MonoDevelop which is fast developing into a useful product. Installing it on rpm based distribution was not a satisfactory experience for me however. But I knew it should be easy to install it on Ubuntu and Gentoo operating systems. if you have included Mutliverse and Universe repositories in the apt source list, then MonoDevelop is just one 'apt-get install' away on Ubuntu.

    sh# sudo apt-get install monodevelop

    It required only a bit more effort on a Gentoo system, so I am documenting it here. Most of the packages required to get MonoDevelop working on a Gentoo system are in the masked state. Put the following lines in the /etc/portage/package.keywords file(create it if it already doesn't exist):

    >=dev-dotnet/gtkhtml-sharp-2.4.0 ~x86
    >=dev-dotnet/glade-sharp-2.4.0 ~x86
    >=dev-dotnet/gconf-sharp-2.4.0 ~x86
    >=dev-dotnet/art-sharp-2.4.0 ~x86
    >=dev-dotnet/gnome-sharp-2.4.0 ~x86
    >=dev-dotnet/vte-sharp-2.4.0 ~x86
    >=dev-dotnet/gnomevfs-sharp-2.4.0 ~x86
    dev-dotnet/gtksourceview-sharp ~x86
    dev-dotnet/gecko-sharp ~x86
    dev-dotnet/libgdiplus ~x86
    dev-util/monodevelop ~x86
    dev-lang/mono ~x86

    you can drop ">=" in front of some of the lines above by dropping the version numbers in the same lines.
    eg: dev-dotnet/gtkhtml-sharp ~x86

    Now run the following command to get everything installed:

    sh# emerge monodevelop

    Similarly 'emerge mono' will get only the mono environment, and all the development can be carried out using your favourite editor and the command shell.

    If you get any problems, first try 'emerge sync' to get everything synchronised, and then re-run 'emerge monodevelop'. If you still get any errors, see if still there are any dependency problems left that are in the masked state. if so, add them too to the '/etc/portage/package.keywords' file and repeat the process.
    Let me know how this works out for you as I haven't found much information regarding this on the internet.


    If you want to receive future posts by email, enter your email address here:

    Related Posts:

  • How to Speed up Booting Into GNOME - A Gentoo Wiki Tip
  • Java on Gentoo
  • Two Applications For Easy Management Of ‘USE’ Flags In Gentoo
  • Moving A GNU/Linux Installation To A Different Partition
  • A NFS Story on Gentoo
  • Update or Install Applications on a Gentoo Machine Without an Internet Connection
  • Installing C++ Boost on Gentoo and Debian/Ubuntu

  • Readers who viewed this page, also viewed:



    Copyright (c) 2006, 2007 Tabrez Iqbal.
    Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. Verbatim copying and distribution of this entire article is permitted in any medium without royalty provided this notice is preserved. A copy of the license is included in the section entitled "GNU Free Documentation License".


    Powered by WordPress
    This website is hosted by Dreamhost