我的问题是这样的:在安装 nagios,编译 nrpe 和 nagios-plugin 时都出现下面的错误
[root@localhost nagios-plugins-2.1.2]# ./configure
checking for a BSD-compatible install… /usr/bin/install -c
checking whether build environment is sane… yes
checking for a thread-safe mkdir -p… /bin/mkdir -p
checking for gawk… gawk
checking whether make sets $(MAKE)… yes
checking whether to disable maintainer-specific portions of Makefiles… yes
checking build system type… x86_64-unknown-linux-gnu
checking host system type… x86_64-unknown-linux-gnu
checking for gcc… gcc
checking for C compiler default output file name…
configure: error: in /root/nagios-plugins-2.1.2′:
configure: error: C compiler cannot create executables
Seeconfig.log’ for more details.
[root@localhost nrpe-2.12]# ./configure
checking for a BSD-compatible install… /usr/bin/install -c
checking build system type… x86_64-unknown-linux-gnu
checking host system type… x86_64-unknown-linux-gnu
checking for gcc… gcc
checking for C compiler default output file name… configure: error: C compiler cannot create executables
See `config.log’ for more details.
日志最后提示: configure: exit 77
然后检视很多资料
有的说缺失这个包 libc6-dev ,但是 yum 根本就安装不了
gcc 我也解除安装了,然后用 yum 重灌了还是不行,,然后我又下载了 gcc 安装包手动安装,但是到编译的部分还是提示类似上面的错误。
然后我就搜寻 yum 安装 libc6-dev,终于找到了答案
https://superuser.com/questions/491504/how-do-i-install-package-libc6-dev-i386-on-fedora
yum install glibc-devel 问题解决了!