redhat 7에는 gcc 4.8.5가 있습니다.
4.9로 업그레이드하고 싶습니다. 이를 위해 아래 명령을 사용했습니다.
sudo yum install devtoolset-3-gcc.x86_64
그리고 나는 아래 응답을 얻었다
Loaded plugins: amazon-id, rhui-lb, search-disabled-repos
Resolving Dependencies
--> Running transaction check
---> Package devtoolset-3-gcc.x86_64 0:4.9.1-10.el6 will be installed
--> Processing Dependency: devtoolset-3-binutils >= 2.22.52.0.1 for package: devtoolset-3-gcc-4.9.1-10.el6.x86_64
--> Processing Dependency: devtoolset-3-runtime for package: devtoolset-3-gcc-4.9.1-10.el6.x86_64
--> Processing Dependency: libmpfr.so.1()(64bit) for package: devtoolset-3-gcc-4.9.1-10.el6.x86_64
--> Processing Dependency: libgmp.so.3()(64bit) for package: devtoolset-3-gcc-4.9.1-10.el6.x86_64
--> Running transaction check
---> Package devtoolset-3-binutils.x86_64 0:2.24-18.el6 will be installed
---> Package devtoolset-3-gcc.x86_64 0:4.9.1-10.el6 will be installed
--> Processing Dependency: libmpfr.so.1()(64bit) for package: devtoolset-3-gcc-4.9.1-10.el6.x86_64
--> Processing Dependency: libgmp.so.3()(64bit) for package: devtoolset-3-gcc-4.9.1-10.el6.x86_64
---> Package devtoolset-3-runtime.noarch 0:3.0-15.el6 will be installed
--> Processing Dependency: scl-utils >= 20120927-11 for package: devtoolset-3-runtime-3.0-15.el6.noarch
--> Running transaction check
---> Package devtoolset-3-gcc.x86_64 0:4.9.1-10.el6 will be installed
--> Processing Dependency: libmpfr.so.1()(64bit) for package: devtoolset-3-gcc-4.9.1-10.el6.x86_64
--> Processing Dependency: libgmp.so.3()(64bit) for package: devtoolset-3-gcc-4.9.1-10.el6.x86_64
---> Package scl-utils.x86_64 0:20130529-17.el7_1 will be installed
--> Finished Dependency Resolution
Error: Package: devtoolset-3-gcc-4.9.1-10.el6.x86_64 (slc6-scl)
Requires: libmpfr.so.1()(64bit)
Error: Package: devtoolset-3-gcc-4.9.1-10.el6.x86_64 (slc6-scl)
Requires: libgmp.so.3()(64bit)
You could try using --skip-broken to work around the problem
You could try running: rpm -Va --nofiles --nodigest
mpfr이 설치되어 있음을 확인했습니다
[ec2-user@ip-172-31-31-165 ~]$ sudo yum install mpfr-devel
Loaded plugins: amazon-id, rhui-lb, search-disabled-repos
Package mpfr-devel-3.1.1-4.el7.x86_64 already installed and latest version
Nothing to do
[ec2-user@ip-172-31-31-165 ~]$ sudo yum install mpfr
Loaded plugins: amazon-id, rhui-lb, search-disabled-repos
Package mpfr-3.1.1-4.el7.x86_64 already installed and latest version
Nothing to do
또한 gmp가 설치되어 있는지 확인했습니다.
[ec2-user@ip-172-31-31-165 ~]$ sudo yum install gmp
Loaded plugins: amazon-id, rhui-lb, search-disabled-repos
Package 1:gmp-6.0.0-12.el7_1.x86_64 already installed and latest version
Nothing to do
[ec2-user@ip-172-31-31-165 ~]$ sudo yum install gmp-devel
Loaded plugins: amazon-id, rhui-lb, search-disabled-repos
Package 1:gmp-devel-6.0.0-12.el7_1.x86_64 already installed and latest version
Nothing to do
그러나 둘 다 이미 내 시스템에 존재합니다. 여기에 빠진 것이 있습니까? RHEL 7에서 gcc 버전 4.9를 어떻게 설치합니까?
/opt/rh/devtoolset-3/root/usr/libexec/gcc/x86_64-redhat-linux/4.9.1/ld: cannot find -lgfortran /opt/rh/devtoolset-3/root/usr/libexec/gcc/x86_64-redhat-linux/4.9.1/ld: cannot find -lquadmath
. 다른 도구 devtoolset-3도 설치해야한다고 생각합니다. 이 같은 추가 라이브러리가 필요합니다libboost_system-mt.so.5
. compat-libgmp-4.3.1-1.sl7.x86_64.rpm 및 compat-libmpfr-2.4.1-1.sl7.x86_64.rpm이있는 위치를 알려주십시오.