vmware workstation虚拟机中linux系统如何安装gcc
vmwareworkstation虚拟机中linux系统如何安装gcc?要详细步骤,详细步骤,图文并茂更好!另外,安装vmwaretools和安装gcc哪个步骤在先?在宿...
vmware workstation虚拟机中linux系统如何安装gcc?要详细步骤,详细步骤,图文并茂更好!另外,安装vmware tools和安装gcc哪个步骤在先?在宿主机下载了gcc后,怎样才能把gcc文件放到虚拟机里安装啊,在vmware tools还没安装好的前提下是不能用共享文件夹这种形式将gcc导到虚拟机中吧?而且安装vmware tools时有一步是检测是否有gcc,而没有gcc的话这个vmware tools的安装就不会成功,那么就不可能用共享文件夹,所以这样就形成了一个恶性循环啊,如何处理?请提供详细步骤,新手求教,急用,谢谢了!
展开
6个回答
展开全部
1、打开VMware Workstation 10,点击“创建新的虚拟机”按钮,进入创建新的虚拟机界面。
2、选择“自定义(高级)”,点击“下一步”。
3、硬件兼容性选择“Workstation 10.0”,点击“下一步”。
4、选择“稍后安装操作系统”,点击“下一步”。
5、操作系统选择“Linux”,版本选择“Ubuntu”,点击“下一步”。
6、设置虚拟机网络类型,点击“下一步”;接下来可全部按照默认设置,点击下一步直至完成。
7、运行虚拟机,开始安装gcc,安装完成进入系统登录界面。
展开全部
使用两个命令安装gcc,gcc-c++:
#yum -y install gcc
#yum -y install gcc-c++
yum会自动查找软件的相关依赖包,自动下载安装。
横线以内为安装过程。
——————————————————————————————————
[root@localhost ~]# yum -y install gcc
Loaded plugins: fastestmirror, rhnplugin, security
Repository base is listed more than once in the configuration
Repository updates is listed more than once in the configuration
Repository extras is listed more than once in the configuration
Repository centosplus is listed more than once in the configuration
Repository contrib is listed more than once in the configuration
This system is not registered with RHN.
RHN support will be disabled.
Loading mirror speeds from cached hostfile
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package gcc.i386 0:4.1.2-51.el5 set to be updated
--> Processing Dependency: glibc-devel >= 2.2.90-12 for package: gcc
--> Running transaction check
---> Package glibc-devel.i386 0:2.5-65 set to be updated
--> Processing Dependency: glibc-headers = 2.5-65 for package: glibc-devel
--> Processing Dependency: glibc-headers for package: glibc-devel
--> Running transaction check
---> Package glibc-headers.i386 0:2.5-65 set to be updated
--> Processing Dependency: kernel-headers >= 2.2.1 for package: glibc-headers
--> Processing Dependency: kernel-headers for package: glibc-headers
--> Running transaction check
---> Package kernel-headers.i386 0:2.6.18-274.3.1.el5 set to be updated
--> Finished Dependency Resolution
Dependencies Resolved
================================================================================
Package Arch Version Repository Size
================================================================================
Installing:
gcc i386 4.1.2-51.el5 base 5.2 M
Installing for dependencies:
glibc-devel i386 2.5-65 base 2.0 M
glibc-headers i386 2.5-65 base 604 k
kernel-headers i386 2.6.18-274.3.1.el5 updates 1.2 M
Transaction Summary
================================================================================
Install 4 Package(s)
Upgrade 0 Package(s)
Total download size: 9.1 M
Downloading Packages:
(1/4): glibc-headers-2.5-65.i386.rpm | 604 kB 00:06
(2/4): kernel-headers-2.6.18-274.3.1.el5.i386.rpm | 1.2 MB 00:14
(3/4): glibc-devel-2.5-65.i386.rpm | 2.0 MB 00:11
(4/4): gcc-4.1.2-51.el5.i386.rpm | 5.2 MB 00:27
--------------------------------------------------------------------------------
Total 149 kB/s | 9.1 MB 01:02
Running rpm_check_debug
Running Transaction Test
Finished Transaction Test
Transaction Test Succeeded
Running Transaction
Installing : kernel-headers 1/4
Installing : glibc-headers 2/4
Installing : glibc-devel 3/4
Installing : gcc 4/4
Installed:
gcc.i386 0:4.1.2-51.el5
Dependency Installed:
glibc-devel.i386 0:2.5-65 glibc-headers.i386 0:2.5-65
kernel-headers.i386 0:2.6.18-274.3.1.el5
Complete!
[root@localhost ~]#
————————————————————————————————————
#yum -y install gcc
#yum -y install gcc-c++
yum会自动查找软件的相关依赖包,自动下载安装。
横线以内为安装过程。
——————————————————————————————————
[root@localhost ~]# yum -y install gcc
Loaded plugins: fastestmirror, rhnplugin, security
Repository base is listed more than once in the configuration
Repository updates is listed more than once in the configuration
Repository extras is listed more than once in the configuration
Repository centosplus is listed more than once in the configuration
Repository contrib is listed more than once in the configuration
This system is not registered with RHN.
RHN support will be disabled.
Loading mirror speeds from cached hostfile
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package gcc.i386 0:4.1.2-51.el5 set to be updated
--> Processing Dependency: glibc-devel >= 2.2.90-12 for package: gcc
--> Running transaction check
---> Package glibc-devel.i386 0:2.5-65 set to be updated
--> Processing Dependency: glibc-headers = 2.5-65 for package: glibc-devel
--> Processing Dependency: glibc-headers for package: glibc-devel
--> Running transaction check
---> Package glibc-headers.i386 0:2.5-65 set to be updated
--> Processing Dependency: kernel-headers >= 2.2.1 for package: glibc-headers
--> Processing Dependency: kernel-headers for package: glibc-headers
--> Running transaction check
---> Package kernel-headers.i386 0:2.6.18-274.3.1.el5 set to be updated
--> Finished Dependency Resolution
Dependencies Resolved
================================================================================
Package Arch Version Repository Size
================================================================================
Installing:
gcc i386 4.1.2-51.el5 base 5.2 M
Installing for dependencies:
glibc-devel i386 2.5-65 base 2.0 M
glibc-headers i386 2.5-65 base 604 k
kernel-headers i386 2.6.18-274.3.1.el5 updates 1.2 M
Transaction Summary
================================================================================
Install 4 Package(s)
Upgrade 0 Package(s)
Total download size: 9.1 M
Downloading Packages:
(1/4): glibc-headers-2.5-65.i386.rpm | 604 kB 00:06
(2/4): kernel-headers-2.6.18-274.3.1.el5.i386.rpm | 1.2 MB 00:14
(3/4): glibc-devel-2.5-65.i386.rpm | 2.0 MB 00:11
(4/4): gcc-4.1.2-51.el5.i386.rpm | 5.2 MB 00:27
--------------------------------------------------------------------------------
Total 149 kB/s | 9.1 MB 01:02
Running rpm_check_debug
Running Transaction Test
Finished Transaction Test
Transaction Test Succeeded
Running Transaction
Installing : kernel-headers 1/4
Installing : glibc-headers 2/4
Installing : glibc-devel 3/4
Installing : gcc 4/4
Installed:
gcc.i386 0:4.1.2-51.el5
Dependency Installed:
glibc-devel.i386 0:2.5-65 glibc-headers.i386 0:2.5-65
kernel-headers.i386 0:2.6.18-274.3.1.el5
Complete!
[root@localhost ~]#
————————————————————————————————————
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
展开全部
先让虚拟机中的linux能上网,只要你主机能上网,把虚拟机的网卡模式设置为桥接模式,就可以了
然后在运行yum install gcc -y,(你的linux版本挺老的,估计够呛能有yum)那就得手动安装
wget ftp://rpmfind.net/linux/freshrpms/redhat/9/yum/yum-2.0.4-1.rh.fr.i386.rpm
rpm -ivh yum-2.0.4-1.rh.fr.i386.rpm
yum update
然后再运行
yum install gcc -y
然后在运行yum install gcc -y,(你的linux版本挺老的,估计够呛能有yum)那就得手动安装
wget ftp://rpmfind.net/linux/freshrpms/redhat/9/yum/yum-2.0.4-1.rh.fr.i386.rpm
rpm -ivh yum-2.0.4-1.rh.fr.i386.rpm
yum update
然后再运行
yum install gcc -y
本回答被提问者采纳
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
展开全部
先装gcc,因为安装vm tools需要gcc编译模块;
在物理机下载了gcc把他做成iso,完后挂载到虚拟机里面安装(gcc这种基本软件通常在系统光盘里面有,不用下载,光盘Packet文件夹里面,就是你装系统时候的那个iso);
安装gcc的时候可能需要很多依赖哦!
在物理机下载了gcc把他做成iso,完后挂载到虚拟机里面安装(gcc这种基本软件通常在系统光盘里面有,不用下载,光盘Packet文件夹里面,就是你装系统时候的那个iso);
安装gcc的时候可能需要很多依赖哦!
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询