码迷,mamicode.com
首页 > 数据库 > 详细

MySQL源码包的编译安装

时间:2017-12-19 15:08:29      阅读:190      评论:0      收藏:0      [点我收藏+]

标签:源码安装mysql mysql源码安装

1、安装依赖包

yum -y install ncurses-devel libaio-devel

2、下载cmake包,解压,编译

wget -q https://cmake.org/files/v2.8/cmake-2.8.8.tar.gz 
tar -xvf cmake-2.8.8.tar.gz
cd cmake-2.8.8
./configure

编译报错一般是因为没有安装gcc-c++

yum -y install gcc-c++
gmake && gmake install

3、下载mysql-5.5.58.tar.gz

tar -xvf mysql-5.5.58.tar.gz
cd mysql-5.5.58
cmake . -DCMAKE_INSTALL_PREFIX=/application/mysql-5.5.58 -DMYSQL_DATADIR=/application/mysql-5.5.58/data -DMYSQL_UNIX_ADDR=/application/mysql-5.5.58/tmp/mysql.sock -DDEFAULT_CHARSET=utf8 -DDEFAULT_COLLATION=utf8_general_ci -DEXTRA_CHARESTS=gbk,gb2313,utf8,ascii -DENABLED_LOCAL_INFILE=ON -DWITH_INNOBASE_STORAGE_ENGINE=1 -DWITH_FEDERATED_STORAGE_ENGINE=1 -DWITH_BLACKHOLE_STORAGE_ENGINE=1 -DWITHOUT_EXAMPLE_STORAGE_ENGINE=1 -DWITHOUT_PARTITION_STORAGE_ENGINE=1 -DWITH_FAST_MUTEXES=1 -DWITH_ZLIB=bundled -DENABLED_LOCAL_INFILE=1 -DWITH_READLINE=1 -DWTH_EMBEDDED_SERVER=1 -DWITH_DEBUG=0
make && make install


MySQL源码包的编译安装

标签:源码安装mysql mysql源码安装

原文地址:http://blog.51cto.com/jhyeliu/2052068

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!