Install MONO 2.10.6 in CentOS 5.5

Source: Internet
Author: User

 

Note: In this article, refer to installing MONO 2.10.6 in CentOS 6.0 and mark the original article based on some problems encountered after installation.

 

1. Update the system

 

Yum update

 

2. install necessary Libraries

 

Yum install gcc-c ++ bison pkgconfig glib2-devel gettext make libpng-devel libjpeg-devel libtiff-devel libexif-devel giflib-devel libX11-devel freetype-devel fontconfig-devel cairo-devel httpd -devel

 

3. Upgrade sqlite (sqlite3.5 or above is required when installing mono xsp-2.10)

 

Http://dl.atrpms.net/el5-i386/atrpms/testing/sqlite-3.6.20-1.el5.i386.rpm wget-c

 

Rpm-Uvh sqlite-3.6.20-1.el5.i386.rpm

 

4. Install libgdiplus

 

Cd/usr/local/src/

 

Wget http://download.mono-project.com/sources/libgdiplus/libgdiplus-2.10.tar.bz2

 

Tar-jxvf libgdiplus-2.10.tar.bz2

 

Cd libgdiplus-2.10

 

./Configure -- prefix =/opt/mono

 

Make

 

Make install

 

Echo "/opt/mono/lib">/etc/ld. so. conf. d/mono. conf

 

Ldconfig

 

5. Install mono

 

Cd/usr/local/src/

 

Wget http://download.mono-project.com/sources/mono/mono-2.10.6.tar.bz2

 

Tar-jxvf mono-2.10.6.tar.bz2

 

Cd mono-2.10.6

 

./Configure -- prefix =/opt/mono

 

Make

 

Make install

 

Echo export 'pkg _ CONFIG_PATH =/opt/mono/lib/pkgconfig: $ PKG_CONFIG_PATH '> ~ /. Bash_profile

 

Echo export 'path =/opt/mono/bin: $ path'> ~ /. Bash_profile

 

Source ~ /. Bash_profile

 

If mono-V has mono version information, the installation is successful.

 

6. Install mono xsp-2.10

 

Cd/usr/local/src/

 

Wget http://download.mono-project.com/sources/xsp/xsp-2.10.tar.bz2

 

Tar jxvf xsp-2.10.tar.bz2

 

Cd xsp-2.10

 

./Configure-prefix =/opt/mono

 

Make

 

Make install

 

7. Install mod_mono-2.10

 

Cd/usr/local/src/

 

Wget http://download.mono-project.com/sources/mod_mono/mod_mono-2.10.tar.bz2

 

Tar jxvf mod_mono-2.10.tar.bz2

 

Cd mod_mono-2.10

 

./Configure-prefix =/opt/mono

 

Make;

 

Make install

 

Note: After the mod_mono module is installed, the configuration file mod_mono.conf will be copied to the/etc/httpd/conf/directory by default, but apache will only load/etc/httpd/conf by default. d/directory configuration, you need to move mod_mono.conf to/etc/httpd/conf. d/directory.

 

Mv/etc/httpd/conf/mod_mono.conf/etc/httpd/conf. d/mod_mono.conf

 

Test whether aspx can be run. Because mono xsp comes with a demo, which is located in the opt/mono/lib/xsp/test directory, we will take this as an example.

 

Modify mod_mono.conf

 

Vi/etc/httpd/conf. d/mod_mono.conf

 

Add the following lines at the end of the file:

 

Alias/demo "/opt/mono/lib/xsp/test"

MonoApplications "/demo:/opt/mono/lib/xsp/test"

MonoServerPath/opt/mono/bin/mod-mono-server2

<Location/demo>

SetHandler mono

</Location>

 

Restart apache

 

Service httpd restart

 

Enter http: // localhost/demo/in the browser/

 

If Welcome to Mono XSP appears! The prompt message indicates that the operation is successful.

 

Author: Chen Feng

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.