At the time of writing 2.11.2 is the newest version for Mono that I could find. If a newer version of Mono has come out by now, you can probably find it here.
Before installing
Before installing version 2.11.2 I actually had 2.6.7 installed (which doesn’t support .NET 4.0). I am not sure if my installation guide will work without you having done this, so in case you run into problems, run this first;
apt-get install mono-complete
apt-get remove mono-complete
After doing this, the command “Mono -V” actually still showed 2.6.7 as being installed so I’m not exactly sure if any of these files were required to get 2.11.2 to run.
Installation guide
Make might take 30-60 minutes, make-install should be fast
Updated for 3.4.0
This release has a bug (missing file) so one of the below commands creates it
apt-get update
apt-get install -y --force-yes gcc libtool bison pkg-config libglib2.0-dev gettext make bzip2 g++ build-essential
mkdir -p /var/mono-install
cd /var/mono-install
wget http://origin-download.mono-project.com/sources/mono/mono-3.4.0.tar.bz2
tar xvjf mono-3.4.*.tar.bz2
cd mono-3.4.*
echo -e '<Project xmlns=<a class="moz-txt-link-rfc2396E" href="http://schemas.microsoft.com/developer/msbuild/2003">"http://schemas.microsoft.com/developer/msbuild/2003">\n <Import Project="..\Microsoft.Portable.Core.props" />\n <Import Project="..\Microsoft.Portable.Core.targets" />\n</Project>' > mcs/tools/xbuild/targets/Microsoft.Portable.Common.targets
./configure --prefix=/opt/mono-3.4
make
make install
rm /usr/bin/mono
rm /usr/bin/gmcs
rm /usr/bin/mcs
rm /usr/bin/smcs
rm /usr/bin/dmcs
ln -s /opt/mono-3.4/bin/mono /usr/bin/mono
ln -s /opt/mono-3.4/bin/gmcs /usr/bin/gmcs
ln -s /opt/mono-3.4/bin/mcs /usr/bin/mcs
ln -s /opt/mono-3.4/bin/smcs /usr/bin/smcs
ln -s /opt/mono-3.4/bin/dmcs /usr/bin/dmcs
Updated for 3.2.6
apt-get update apt-get install -y --force-yes gcc libtool bison pkg-config libglib2.0-dev gettext make bzip2 g++ build-essential mkdir -p /var/mono-install cd /var/mono-install wget http://origin-download.mono-project.com/sources/mono/mono-3.2.6.tar.bz2 tar xvjf mono-3.2.*.tar.bz2 cd mono-3.2.* ./configure --prefix=/opt/mono-3.2 make make install rm /usr/bin/mono rm /usr/bin/gmcs rm /usr/bin/mcs rm /usr/bin/smcs rm /usr/bin/dmcs ln -s /opt/mono-3.2/bin/mono /usr/bin/mono ln -s /opt/mono-3.2/bin/gmcs /usr/bin/gmcs ln -s /opt/mono-3.2/bin/mcs /usr/bin/mcs ln -s /opt/mono-3.2/bin/smcs /usr/bin/smcs ln -s /opt/mono-3.2/bin/dmcs /usr/bin/dmcs
Updated for 3.0.3
apt-get update apt-get install gcc libtool bison pkg-config libglib2.0-dev gettext make bzip2 g++ mkdir /var/mono-install cd /var/mono-install wget http://origin-download.mono-project.com/sources/mono/mono-3.0.3.tar.bz2 tar xvjf mono-3.0.3.tar.bz2 cd mono-3.0.3 ./configure --prefix=/opt/mono-3.0 # Make might take 30-60 minutes, make-install should be fast make make install cd /usr/bin mv mono mono.old mv gmcs gmcs.old ln -s /opt/mono-3.0/bin/mono /usr/bin/mono ln -s /opt/mono-3.0/bin/gmcs /usr/bin/gmcs
2.11.2 version
apt-get update apt-get install gcc libtool bison pkg-config libglib2.0-dev gettext make bzip2 g++ mkdir /var/mono-install cd /var/mono-install wget http://origin-download.mono-project.com/sources/mono/mono-2.11.2.tar.bz2 tar xvjf mono-2.11.2.tar.bz2 cd mono-2.11.2 ./configure --prefix=/opt/mono-2.11 # Make might take 30-60 minutes, make-install should be fast make make install cd /usr/bin mv mono mono.old mv gmcs gmcs.old ln -s /opt/mono-2.11/bin/mono /usr/bin/mono ln -s /opt/mono-2.11/bin/gmcs /usr/bin/gmcs
Also include (Clean Debian 6 installation) —>
apt-get install build-essential
apt-get install gettext
apt-get install g++
Apart from that everything went well… now to figure out whereto from here :)
Also edit the gmcs script and add the Full path
(Debian 6 installation)
from:
mcs -sdk:2 “[email protected]”
to:
/opt/mono-3.0/bin/mcs -sdk:2 “[email protected]”
(or wathever your installation path)
to prevent compiler errors like:
“error CS2007: Unrecognized command-line option: `-sdk:2′”