centos安裝devtoolset-3支持gcc 4.9.2


由於gcc 4.8.2不支持C++11的regex庫,故需升到4.9.2
 
#centos6系列,首先加載源,導入rpm
wget https://www.softwarecollections.org/repos/rhscl/devtoolset-3/epel-6-x86_64/noarch/rhscl-devtoolset-3-epel-6-x86_64-1-2.noarch.rpm
rpm -ivh rhscl-devtoolset-3-epel-6-x86_64-1-2.noarch.rpm
 
#centos7系統
wget https://www.softwarecollections.org/repos/rhscl/devtoolset-3/epel-7-x86_64/noarch/rhscl-devtoolset-3-epel-7-x86_64-1-2.noarch.rpm
rpm -ivh rhscl-devtoolset-3-epel-7-x86_64-1-2.noarch.rpm
 
接下來開始下載安裝
yum install devtoolset-3-toolchain
 
安裝完畢后可通過
scl enable devtoolset-3 bash
 
啟用開發環境 通過gcc -v確認
 

 

 

 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM