rhel5上使用源代码安装mysql4.0.x
2012-02-20 20:25
281 查看
1.在rhel5.1上安装mysql-4.0.18, configure的时候报如下错误:
configure: error: This is a linux system and Linux threads was not
found. On linux Linuxthreads should be used. Please install Linuxthreads
(or a new glibc) and try again. See the Installation chapter in the
Reference Manual for more information.
看来需要新版本的glibc;configure的时候增加参数 --with-named-thread-libs="-lpthread" ;顺利通过。
2.不过make的时候又出错了
mysqld.o: In function `main':
mysqld.cc:(.text+0x3ee0): undefined reference to `my_fast_mutexattr'
mysqld.o:mysqld.cc:(.text+0x4143): more undefined references to `my_fast_mutexattr' follow
collect2: ld returned 1 exit status
make[4]: *** [mysqld] Error 1
make[4]: Leaving directory `/usr/local/src/mysql-4.0.26/sql'
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory `/usr/local/src/mysql-4.0.26/sql'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/usr/local/src/mysql-4.0.26/sql'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/local/src/mysql-4.0.26'
make: *** [all] Error 2
在mysql-4.0.26/sql/sql_class.cc文件中的
#include <assert.h>
(约39行)语句下面写如下代码
#ifdef PTHREAD_ADAPTIVE_MUTEX_INITIALIZER_NP
pthread_mutexattr_t my_fast_mutexattr;
#endif
make顺利通过;
3.我按照上面的步骤坐下来仍然报错,最后直接修改mysql-4.0.26/sql/sql_class.cc文件,添加pthread_mutexattr_t my_fast_mutexattr;,不知道有没有什么影响。
configure: error: This is a linux system and Linux threads was not
found. On linux Linuxthreads should be used. Please install Linuxthreads
(or a new glibc) and try again. See the Installation chapter in the
Reference Manual for more information.
看来需要新版本的glibc;configure的时候增加参数 --with-named-thread-libs="-lpthread" ;顺利通过。
2.不过make的时候又出错了
mysqld.o: In function `main':
mysqld.cc:(.text+0x3ee0): undefined reference to `my_fast_mutexattr'
mysqld.o:mysqld.cc:(.text+0x4143): more undefined references to `my_fast_mutexattr' follow
collect2: ld returned 1 exit status
make[4]: *** [mysqld] Error 1
make[4]: Leaving directory `/usr/local/src/mysql-4.0.26/sql'
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory `/usr/local/src/mysql-4.0.26/sql'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/usr/local/src/mysql-4.0.26/sql'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/local/src/mysql-4.0.26'
make: *** [all] Error 2
在mysql-4.0.26/sql/sql_class.cc文件中的
#include <assert.h>
(约39行)语句下面写如下代码
#ifdef PTHREAD_ADAPTIVE_MUTEX_INITIALIZER_NP
pthread_mutexattr_t my_fast_mutexattr;
#endif
make顺利通过;
3.我按照上面的步骤坐下来仍然报错,最后直接修改mysql-4.0.26/sql/sql_class.cc文件,添加pthread_mutexattr_t my_fast_mutexattr;,不知道有没有什么影响。
相关文章推荐
- 在linux上使用源代码安装MySQL
- rhel5上使用源代码安装mysql4.0.x
- Linux下使用源代码编译方式安装MySQL
- 在CentOS下使用源代码安装MySQL
- linux mysql 安装使用说明
- 第十一天 Linux程序包、RPM 、YUM使用及源代码编译安装
- 在CentOS 7下使用yum配置MySQL源并安装MySQL
- Java Web开发Basic(二) mysql安装使用
- linux使用mysql(卸载,安装,修改密码,远程登录)
- NoSQL for MySQL [HandlerSocket] 之安装与使用
- 源代码安装MySQL5.6
- CentOS使用yum安装mysql(超简单)
- 使用cmake编译安装mysql(原创整理)
- CentOS 7.3下使用yum安装MySQL
- 在树莓派上安装和使用mySQL
- Mysql 安装及日常使用一
- MySQL下载安装、配置与使用教程详细版(win7x64)
- MYSQL完全安装使用指南
- win7下cmdline操控mysql(一 安装使用)
- 使用YUM安装并启动MySQL服务后,MySQL进程会自动在进程日志中打印root用户的初始密码