Set mono environment variables in centos

Source: Internet
Author: User

GitHub has a one-click mono installation script. For more information, see https://github.com/nathanb/iws-snippets/tree/master/mono-install-scripts/fedora.

1. Install the latest mono environment mono-2.11

mkdir mono-2.11
cd mono-2.11
wget --no-check-certificate https://github.com/nathanb/iws-snippets/tree/master/mono-install-scripts/fedora/install_mono-2.11.sh
chmod 755 install_mono-2.11.sh
./install_mono-2.11.sh

2. Set mono environment variables on centos

The installation script installs mono/Opt/mono-2.11/, you need to add the mono directory to the system $ PATH variable

Method 1: Add a variable to the/etc/profile file [effective for all users (permanent )]
Use VI to add a variable to the/etc/profile file. This variable will be valid for all users in Linux and will be "permanent ".

[root@SNDA-192-168-15-161 ~]# vi /etc/profile
Add the following two lines of code to the end of the file:
Path =/opt/mono-2.11/bin: $ Pathexport path

If the modification takes effect immediately, run the following code:

[root@SNDA-192-168-15-161 ~]# source /etc/profile

Method 2: Create a mono configuration under the/etc/profile. d/directory.

Create a new mono. Sh

Initialize environment variables in this file

Export Path = $ path:/opt/mono-2.11/bin

If the modification takes effect immediately, run the following code:

[Root @ SNDA-192-168-15-161 profile. d] # source mono. Sh

Now you can directly execute the mono command.

[Root @ SNDA-192-168-15-161 profile. d] # mono-V
Mono JIT compiler version 2.11.3 (tarball Thu Oct 11 07:46:58 CST 2012)

Copyright (c) 2002-2012 Novell, Inc, xamarin INC and contributors. www.mono-project.com

TLS: _ thread

SIGSEGV: altstack

Specifications: epoll

Architecture: amd64

Disabled: None

Misc: softdebug

Llvm: supported, not enabled.

GC: encoded ded Boehm (with typed GC and parallel mark)

 

Running ASP. NET mvc4 on Ubuntu 12.04

Related Article

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.