Centos 6.4 compile and install gcc-4.8.0

Source: Internet
Author: User

1. DownloadSource code

 
Wget http://ftp.gnu.org/gnu/gcc/gcc-4.8.0/gcc-4.8.0.tar.bz2

2. Extract

 
Tar-jxvf gcc-4.8.0.tar.bz2

3. Download the dependencies required for compilation.

 
CD gcc-4.8.0./contrib/download_prerequisites CD ..

4. Create a compilation output directory

 
Mkdir gcc-build-4.8.0

5. Go to the directory and run the following command to generate the MAKEFILE file.

 
CD gcc-build-4.8.0 ../gcc-4.8.0/configure -- enable-checking = release -- enable-extensions ages = C, C ++ -- disable-multilib

6. Execute the following command to compile

 
Make-J4

So far, the compilation process has been completed. Wait until the compilation is completed ....

During compilation, the CPU runs at full capacity. About 40 minutes.

7. Install

 
Sudo make install

8. Check the GCC version.

 
GCC -- version

 

 
[Arlen @ Arlen-centos gcc-build-4.8.0] $ GCC -- versiongcc (GCC) 4.8.0copyright 2013 Free Software Foundation, Inc.ProgramIs Free Software. See the sourceCode. This software does not have any warranty, including non-marketable and non-applicable warranties for a specific purpose. [Arlen @ Arlen-centos gcc-build-4.8.0] $

 

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.