操作系统是:redhat5以上版本,具体忘了
系统内核是:Linuxlocalhost.localdomain2.6.32-358.el6.x86_64#1SMPTueJan2911:47:41ESTx86_64x86_64x86_64GNU/Linux
安装nginx时,提示
[root@localhostnginx-1.4.1]#./configure
checkingforOS
+Linux2.6.32-358.el6.x86_64x86_64
checkingforCcompiler...notfound
./configure:error:Ccompilerccisnotfound
安装其他需要编译的程序时(譬如apache)提示c编译器无法使用
具体如下:
[root@localhosthttpd-2.2.22]#./configure
checkingforchosenlayout...Apache
checkingforworkingmkdir-p...yes
checkingbuildsystemtype...x86_64-unknown-linux-gnu
checkinghostsystemtype...x86_64-unknown-linux-gnu
checkingtargetsystemtype...x86_64-unknown-linux-gnu
ConfiguringApachePortableRuntimelibrary...
checkingforAPR...reconfig
configuringpackageinsrclib/aprnow
checkingbuildsystemtype...x86_64-unknown-linux-gnu
checkinghostsystemtype...x86_64-unknown-linux-gnu
checkingtargetsystemtype...x86_64-unknown-linux-gnu
ConfiguringAPRlibrary
Platform:x86_64-unknown-linux-gnu
checkingforworkingmkdir-p...yes
APRVersion:1.4.5
checkingforchosenlayout...apr
checkingforgcc...gcc
checkingforCcompilerdefaultoutputfilename...
configure:error:in`/usr/local/bjta/httpd-2.2.22/srclib/apr':
configure:error:Ccompilercannotcreateexecutables
See`config.log'formoredetails.
configurefailedforsrclib/apr
我检查gcc是否安装,已经安装:
[root@localhosthttpd-2.2.22]#gcc-v
Usingbuilt-inspecs.
Target:x86_64-redhat-linux
Configuredwith:../configure--prefix=/usr--mandir=/usr/share/man--infodir=/usr/share/info--with-bugurl=/bugzilla--enable-bootstrap--enable-shared--enable-threads=posix--enable-checking=release--with-system-zlib--enable-__cxa_atexit--disable-libunwind-exceptions--enable-gnu-unique-object--enable-languages=c,c++,objc,obj-c++,java,fortran,ada--enable-java-awt=gtk--disable-dssi--with-java-home=/usr/lib/jvm/java-1.5.0-gcj-1.5.0.0/jre--enable-libgcj-multifile--enable-java-maintainer-mode--with-ecj-jar=/usr/share/java/eclipse-ecj.jar--disable-libjava-multilib--with-ppl--with-cloog--with-tune=generic--with-arch_32=i686--build=x86_64-redhat-linux
Threadmodel:posix
gccversion4.4.70313(RedHat4.4.7-3)(GCC)
[root@localhosthttpd-2.2.22]#whichgcc
/usr/bin/gcc
去看了下,/usr/bin目录下有gcc这个文件
/usr/lib/gcc/x86_64-redhat-linux目录下有两个文件夹一个“4.4.4”一个“4.4.7”,内都有“include”文件夹和部分文件
请问如何设置使gcc可用
|
他说你编译器CC没找到./configure:error:Ccompilerccisnotfound
你./configure--help下,把CC设置设置成gcc
|
cc是C编译器吗?这个cc链接到哪里去了?一项一项的查下去。