因为错误设置环境变量,gcc坏掉了
checking for gcc... gccchecking whether the C compiler works... no
configure: error: in `/root/mod_gnutls-0.7.5':
configure: error: C compiler cannot create executables
See `config.log' for more details
参考: http://stackoverflow.com/questions/18872796/configure-error-c-compiler-cannot-create-executables-when-installing-ruby-1-9
In my case, the issue is due to the customized LDFLAGS. I was compiling one of python packages. Because my python is installed in a customized location, I had to temporarily set the LDFLAGS variable env. As soon as I unset this env variable, the problem went away. So FYI.
参考: http://blog.csdn.net/weiyidemaomao/article/details/7742605
因为刚才导致出问题的2个环境变量是 CFLAGS 和 LIBS :
unset CFLAGS && unset LIBS