日期:2014-05-16  浏览次数:23411 次

checking whether the C compiler works... no
我在安装Berkeley DB时报下面错误:
checking whether the C compiler works... no
configure: error: in `/c/db-4.8.30.NC-mgw/build_unix':
configure: error: C compiler cannot create executables
See `config.log' for more details.

求大神们指点,貌似是我的GCC没安装好,但是不知道怎么安装,我这个是用MinGW+msys运行的。
还有一个问题是之前报CC: not fond command,我记得CC和GCC是一样的,所以我将GCC.exe复制一份并重新命名为CC.exe,然后创建Berkeley DB库时就报上面这个错误,不知道这会不会有关系。

这是config.log的详细内容:
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.

It was created by Berkeley DB configure 4.8.30, which was
generated by GNU Autoconf 2.65.  Invocation command line was

  $ ../dist/configure --enable-mingw --enable-cxx LIBS=libwsock32,libws2_32

## --------- ##
## Platform. ##
## --------- ##

hostname = Alan32-PC
uname -m = i686
uname -r = 1.0.17(0.48/3/2)
uname -s = MINGW32_NT-6.1
uname -v = 2011-04-24 23:39

/usr/bin/uname -p = unknown
/bin/uname -X     = unknown

/bin/arch              = unknown
/usr/bin/arch -k       = unknown
/usr/convex/getsysinfo = unknown
/usr/bin/hostinfo      = unknown
/bin/machine           = unknown
/usr/bin/oslevel       = unknown
/bin/universe          = unknown

PATH: .
PATH: /usr/local/bin
PATH: /mingw/bin
PATH: /bin
PATH: /c/Windows/system32
PATH: /c/Windows
PATH: /c/Windows/System32/Wbem
PATH: /c/Windows/System32/WindowsPowerShell/v1.0/
PATH: /mingw/bin
PATH: /c/GNUstep/bin
PATH: /c/GNUstep/GNUstep/System/Tools


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

configure:2900: checking build system type
configure:2914: result: i686-pc-mingw32
configure:2934: checking host system type
configure:2947: result: i686-pc-mingw32
configure:2979: checking if building in the top-level or dist directories
configure:2990: result: no
configure:3074: checking if --disable-cryptography option specified
configure:3087: result: no
configure:3091: checking if --disable-hash option specified
configure:3104: result: no
configure:3108: checking if --disable-partition option specified
configure:3121: result: no
configure:3125: checking if --disable-compression option specified
configure:3138: result: no
configure:3142: checking if --disable-mutexsupport option specified
configure:3155: result: no
configure:3159: checking if --disable-atomicsupport