> 운영 및 유지보수 > 리눅스 운영 및 유지 관리 > 리눅스에서 gcc를 설치하기 위해 yum을 사용하는 방법

리눅스에서 gcc를 설치하기 위해 yum을 사용하는 방법

(*-*)浩
풀어 주다: 2020-09-18 14:55:37
원래의
11143명이 탐색했습니다.

Linux에서 yum을 사용하여 gcc를 설치하는 방법: [yum -y install gcc] 명령을 직접 실행하여 설치를 완료합니다. gcc를 제거하려면 [yum Remove gcc] 명령을 실행하세요.

리눅스에서 gcc를 설치하기 위해 yum을 사용하는 방법

Linux 시스템에서 gcc를 설치하려면 yum 소스를 사용하는 것이 매우 편리합니다. 아래 방법을 참조하세요.

gcc를 설치하려면 yum -y install gcc를 사용하세요.

리눅스에서 gcc를 설치하기 위해 yum을 사용하는 방법

설치 로그:

[root@localhost ~]# yum -y install gcc
已加载插件:fastestmirror, refresh-packagekit, security
设置安装进程
Loading mirror speeds from cached hostfile
 * base: mirrors.aliyun.com
 * extras: mirrors.aliyun.com
 * updates: mirrors.aliyun.com
解决依赖关系
--> 执行事务检查
---> Package gcc.x86_64 0:4.4.7-18.el6 will be 安装
--> 处理依赖关系 libgomp = 4.4.7-18.el6,它被软件包 gcc-4.4.7-18.el6.x86_64 需要
--> 处理依赖关系 cpp = 4.4.7-18.el6,它被软件包 gcc-4.4.7-18.el6.x86_64 需要
--> 处理依赖关系 libgcc >= 4.4.7-18.el6,它被软件包 gcc-4.4.7-18.el6.x86_64 需要
--> 处理依赖关系 cloog-ppl >= 0.15,它被软件包 gcc-4.4.7-18.el6.x86_64 需要
--> 执行事务检查
---> Package cloog-ppl.x86_64 0:0.15.7-1.2.el6 will be 安装
--> 处理依赖关系 libppl_c.so.2()(64bit),它被软件包 cloog-ppl-0.15.7-1.2.el6.x86_64 需要
--> 处理依赖关系 libppl.so.7()(64bit),它被软件包 cloog-ppl-0.15.7-1.2.el6.x86_64 需要
---> Package cpp.x86_64 0:4.4.7-18.el6 will be 安装
--> 处理依赖关系 libmpfr.so.1()(64bit),它被软件包 cpp-4.4.7-18.el6.x86_64 需要
---> Package libgcc.x86_64 0:4.4.7-17.el6 will be 升级
---> Package libgcc.x86_64 0:4.4.7-18.el6 will be an update
---> Package libgomp.x86_64 0:4.4.7-17.el6 will be 升级
---> Package libgomp.x86_64 0:4.4.7-18.el6 will be an update
--> 执行事务检查
---> Package mpfr.x86_64 0:2.4.1-6.el6 will be 安装
---> Package ppl.x86_64 0:0.10.2-11.el6 will be 安装
--> 完成依赖关系计算

依赖关系解决

===============================================================================================================================================================================================
 软件包                                        架构                                       版本                                                  仓库                                      大小
===============================================================================================================================================================================================
正在安装:
 gcc                                           x86_64                                     4.4.7-18.el6                                          base                                      10 M
为依赖而安装:
 cloog-ppl                                     x86_64                                     0.15.7-1.2.el6                                        base                                      93 k
 cpp                                           x86_64                                     4.4.7-18.el6                                          base                                     3.7 M
 mpfr                                          x86_64                                     2.4.1-6.el6                                           base                                     157 k
 ppl                                           x86_64                                     0.10.2-11.el6                                         base                                     1.3 M
为依赖而更新:
 libgcc                                        x86_64                                     4.4.7-18.el6                                          base                                     103 k
 libgomp                                       x86_64                                     4.4.7-18.el6                                          base                                     134 k

事务概要
===============================================================================================================================================================================================
Install       5 Package(s)
Upgrade       2 Package(s)

总下载量:16 M
下载软件包:
(1/7): cloog-ppl-0.15.7-1.2.el6.x86_64.rpm                                                                                                                              |  93 kB     00:00     
(2/7): cpp-4.4.7-18.el6.x86_64.rpm                                                                                                                                      | 3.7 MB     00:01     
(3/7): gcc-4.4.7-18.el6.x86_64.rpm                                                                                                                                      |  10 MB     00:03     
(4/7): libgcc-4.4.7-18.el6.x86_64.rpm                                                                                                                                   | 103 kB     00:00     
(5/7): libgomp-4.4.7-18.el6.x86_64.rpm                                                                                                                                  | 134 kB     00:00     
(6/7): mpfr-2.4.1-6.el6.x86_64.rpm                                                                                                                                      | 157 kB     00:00     
(7/7): ppl-0.10.2-11.el6.x86_64.rpm                                                                                                                                     | 1.3 MB     00:00     
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
总计                                                                                                                                                           2.2 MB/s |  16 MB     00:07     
warning: rpmts_HdrFromFdno: Header V3 RSA/SHA1 Signature, key ID c105b9de: NOKEY
Retrieving key from http://mirrors.aliyun.com/centos/RPM-GPG-KEY-CentOS-6
Importing GPG key 0xC105B9DE:
 Userid: "CentOS-6 Key (CentOS 6 Official Signing Key) <centos-6-key>"
 From  : http://mirrors.aliyun.com/centos/RPM-GPG-KEY-CentOS-6
运行 rpm_check_debug 
执行事务测试
事务测试成功
执行事务
  正在升级   : libgcc-4.4.7-18.el6.x86_64                                                                                                                                                  1/9 
  正在安装   : ppl-0.10.2-11.el6.x86_64                                                                                                                                                    2/9 
  正在安装   : cloog-ppl-0.15.7-1.2.el6.x86_64                                                                                                                                             3/9 
  正在安装   : mpfr-2.4.1-6.el6.x86_64                                                                                                                                                     4/9 
  正在安装   : cpp-4.4.7-18.el6.x86_64                                                                                                                                                     5/9 
  正在升级   : libgomp-4.4.7-18.el6.x86_64                                                                                                                                                 6/9 
  正在安装   : gcc-4.4.7-18.el6.x86_64                                                                                                                                                     7/9 
  清理       : libgcc-4.4.7-17.el6.x86_64                                                                                                                                                  8/9 
  清理       : libgomp-4.4.7-17.el6.x86_64                                                                                                                                                 9/9 
  Verifying  : cpp-4.4.7-18.el6.x86_64                                                                                                                                                     1/9 
  Verifying  : libgomp-4.4.7-18.el6.x86_64                                                                                                                                                 2/9 
  Verifying  : mpfr-2.4.1-6.el6.x86_64                                                                                                                                                     3/9 
  Verifying  : libgcc-4.4.7-18.el6.x86_64                                                                                                                                                  4/9 
  Verifying  : gcc-4.4.7-18.el6.x86_64                                                                                                                                                     5/9 
  Verifying  : ppl-0.10.2-11.el6.x86_64                                                                                                                                                    6/9 
  Verifying  : cloog-ppl-0.15.7-1.2.el6.x86_64                                                                                                                                             7/9 
  Verifying  : libgcc-4.4.7-17.el6.x86_64                                                                                                                                                  8/9 
  Verifying  : libgomp-4.4.7-17.el6.x86_64                                                                                                                                                 9/9 

已安装:
  gcc.x86_64 0:4.4.7-18.el6                                                                                                                                                                    

作为依赖被安装:
  cloog-ppl.x86_64 0:0.15.7-1.2.el6                    cpp.x86_64 0:4.4.7-18.el6                    mpfr.x86_64 0:2.4.1-6.el6                    ppl.x86_64 0:0.10.2-11.el6                   

作为依赖被升级:
  libgcc.x86_64 0:4.4.7-18.el6                                                                  libgomp.x86_64 0:4.4.7-18.el6                                                                 

完毕!</centos-6-key>
로그인 후 복사

위 내용은 리눅스에서 gcc를 설치하기 위해 yum을 사용하는 방법의 상세 내용입니다. 자세한 내용은 PHP 중국어 웹사이트의 기타 관련 기사를 참조하세요!

관련 라벨:
원천:php.cn
본 웹사이트의 성명
본 글의 내용은 네티즌들의 자발적인 기여로 작성되었으며, 저작권은 원저작자에게 있습니다. 본 사이트는 이에 상응하는 법적 책임을 지지 않습니다. 표절이나 침해가 의심되는 콘텐츠를 발견한 경우 admin@php.cn으로 문의하세요.
인기 튜토리얼
더>
최신 다운로드
더>
웹 효과
웹사이트 소스 코드
웹사이트 자료
프론트엔드 템플릿