原来是mysql版本是5.0.11,现在将要装的是稳定版4.0.27。在configure的时候发现会出现找不到某线程的错误,后来上网查资料有人提示装一个mit-thread在mysql的根目录下,然后重新configure,编译通过,但是make还是出现错误.最后我采用了这样的办法:
CPPFLAGS="-D_GNU_SOURCE" ./configure --prefix=/usr --sysconfdir=/etc /
--libexecdir=/usr/sbin --localstatedir=/srv/mysql /
--enable-thread-safe-client --enable-assembler /
--enable-local-infile --with-named-thread-libs=-lpthread /
--with-unix-socket-path=/var/run/mysql/mysql.sock /
--without-debug --without-bench --without-readline
最重要的是这两个参数:CPPFLAGS="-D_GNU_SOURCE" 和 --with-named-thread-libs=-lpthread
BLFS 的说明:
CPPFLAGS="-D_GNU_SOURCE" and --with-named-thread-libs=-lpthread: This environment variable and configure switch enables building the package on NPTL systems