Ubuntu 11.10 GCC4.5 GCC4.6无缝切换
来源:互联网 发布:手机淘宝达人入口 编辑:程序博客网 时间:2024/06/10 00:42
Step1: 检查版本和安装的版本
lee@lee:~$ ls /usr/bin/gcc*
/usr/bin/gcc /usr/bin/gcc-4.5 /usr/bin/gcc-4.6
如果缺4.5那么就安装哈。
sudo apt-get install gcc-4.5 g++-4.5
g++ -v
gcc -v
Step2:增加可选项
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.5 40
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-4.6 30
sudo update-alternatives --config gcc
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-4.5 40
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-4.6 30
sudo update-alternatives --config g++
如果想删除可选项:
sudo update-alternatives --remove gcc /usr/bin/gcc-4.5
Step3:检查当前版本
g++ -v
gcc -v
- Ubuntu 11.10 GCC4.5 GCC4.6无缝切换
- Ubuntu 11.10 GCC4.5 GCC4.6无缝切换
- Ubuntu 11.10 GCC4.5 GCC4.6无缝切换
- Ubuntu 11.10 GCC4.5 GCC4.6无缝切换
- Ubuntu 11.10 GCC4.5 GCC4.6无缝切换
- Ubuntu 11.10 GCC4.5 GCC4.6无缝切换
- Ubuntu 安装GCC4.8
- GCC4.6升级到GCC4.8
- Ubuntu14下gcc4.8和gcc4.7之间的切换
- ubantu安装gcc4.6
- 编译GCC4.5
- 编译GCC4.5
- gcc4.5编译
- .ubuntu 10.04 安装 gcc4.6.1
- Ubuntu 10.04下 GCC4.7
- Ubuntu 13.04 安装 GCC4.8.1
- Ubuntu中编译GCC4.9.0
- RHEL5.6安装GCC4.4.3
- PostgreSQL启动过程中的那些事一:初始化TopMemoryContext和ErrorContext
- printf
- Android布局总结
- 剖析云计算技术及架构(1)
- HotOS 2011年会:对云计算如何进行理论研究
- Ubuntu 11.10 GCC4.5 GCC4.6无缝切换
- Ext.ux.grid.RowEditor的bug修改
- 《Windows核心编程系列》二十谈谈DLL高级技术
- SSH2->Spring Framework2 struts2 hibernate
- 开漏与开集
- copy的用法
- 开漏与推挽
- Android 布局分析
- android布局