Fedora 29 使用 SCL (Software Collections)

在社区中SCL 由Centos 项目进行维护,所以我们使用CentOS 7 SCL源。CentOS SCL中提供了devtoolset-7-gcc-c++,版本正好为 gcc version 7.3.1 20180303 (Red Hat 7.3.1-5) (GCC) 

        首先需要下载CentOS 7 SCL源CentOS-SCL-el7.tar.gz,这里提供百度云Google Drive的地址。

        下载后解压,将其中的repo文件和key文件复制到/etc/目录下:

sudo cp ./etc/* /etc -rf  

   安装devtoolset-7-gcc-c++

sudo dnf install devtoolset-7-gcc-c++ 

       安装完毕后,若要在当前控制台使用gcc 7.3,使用命令

scl enable devtoolset-7 bash  
更多关于scl的用法,可以参考 scl -help。若系统没有安装scl,使用  sudo dnf install scl即可

参考链接:

https://blog.csdn.net/u010158659/article/details/53608285

http://blog.51cto.com/hashlinux/1772066

https://www.softwarecollections.org/en/docs/

https://www.softwarecollections.org/en/scls/rhscl/devtoolset-7/

http://mirror.centos.org/centos/7/sclo/x86_64/rh/

保持更新,转载请注明出处。

原文地址:https://www.cnblogs.com/xuyaowen/p/scls.html