开发工具包是必需的,如果你有计划地建立软件在系统上进行安装。它也是您的系统上构建的软件包是有用的。开发工具包括像GCC有用的工具,GCC, g++, make, libtool, rpmbuild 和 autoconf 等软件包。本教程将帮助你在CentOS,RHEL及Fedora系统上安装开发工具。
安装开发工具
使用下面的命令集在你的RedHat和有衍生版本的系统上安装开发包。
# yum update
# yum groupinstall "Development Tools"
要搞清楚这组命令的作用
# yum groupinfo "Development Tools"
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
* base: mirror.cc.columbia.edu
* extras: mirror.metrocast.net
* updates: mirror.solarvps.com
Group: Development Tools
Group-Id: development
Description: A basic development environment.
Mandatory Packages:
=autoconf
=automake
binutils
=bison
=flex
=gcc
=gcc-c++
gettext
=libtool
make
=patch
pkgconfig
=redhat-rpm-config
=rpm-build
=rpm-sign
Default Packages:
=byacc
=cscope
=ctags
[...]
检查已安装的版本
成功安装在系统上建立必要的包后,让我们检查的重要二进制文件安装的版本。
# gcc --version
gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-4)
Copyright (C) 2015 Free Software Foundation, Inc.
# make --version
GNU Make 3.82
Built for x86_64-redhat-linux-gnu
Copyright (C) 2010 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later