c编译器无法在mac上创建可执行文件

时间:2014-03-25 17:52:40

标签: c gcc compilation osx-mavericks

每当我尝试从配置文件在我的mac(Maverick)上安装软件包或软件时,它在检查C编译器时会自动失败。它说'#34; configure:错误:C编译器无法创建可执行文件"。此外,Homebrew完美运作。我附上了一个config.log的例子。我之前的相关帖子中没有找到任何满意的信息,如果问题得到解决,我会道歉。

## ----------- ##
## Core tests. ##
## ----------- ##

configure:2530: checking for gcc
configure:2546: found /usr/local/bin/gcc
configure:2557: result: gcc
configure:2786: checking for C compiler version
configure:2795: gcc --version >&5
gcc (GCC) 4.8.0 20130113 (experimental)
Copyright (C) 2013 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

configure:2806: $? = 0
configure:2795: gcc -v >&5
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/local/libexec/gcc/x86_64-apple-darwin12.2.0/4.8.0/lto-wrapper
Target: x86_64-apple-darwin12.2.0
Configured with: ../gcc-4.8-20130113/configure --enable-languages=c++,fortran
Thread model: posix
gcc version 4.8.0 20130113 (experimental) (GCC) 
configure:2806: $? = 0
configure:2795: gcc -V >&5
gcc: error: unrecognized command line option '-V'
gcc: fatal error: no input files
compilation terminated.
configure:2806: $? = 1
configure:2795: gcc -qversion >&5
gcc: error: unrecognized command line option '-qversion'
gcc: fatal error: no input files
compilation terminated.
configure:2806: $? = 1
configure:2826: checking whether the C compiler works
configure:2848: gcc    conftest.c  >&5
ld: library not found for -lgcc_ext.10.5
collect2: error: ld returned 1 exit status
configure:2852: $? = 1
configure:2890: result: no
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME ""
| #define PACKAGE_TARNAME ""
| #define PACKAGE_VERSION ""
| #define PACKAGE_STRING ""
| #define PACKAGE_BUGREPORT ""
| #define PACKAGE_URL ""
| /* end confdefs.h.  */
| 
| int
| main ()
| {
| 
|   ;
|   return 0;
| }
configure:2895: error: in `/Users/amidou/miriad_cvs':
configure:2897: error: C compiler cannot create executables
See `config.log' for more details

我的Xcode版本是5.1,我安装了命令行。提前谢谢。

0 个答案:

没有答案