Linux/Ubuntu下CMake编译MySQL教程
使用Linux+Vim写PHP简直是一种享受,下面是我的Vim配置和安装的插件.
1.下载MySQL 5.5.28源码包
下载地址:http://www.mysql.com/downloads/mysql/#downloads
在MySQL下载页面的下拉框选择“Source Code”,然后选择最下面的tar.gz格式,开始下载。wget开始可以使用:http://cdn.mysql.com/Downloads/MySQL-5.5/mysql-5.5.28.tar.gz这个地址。
2.添加MySQL用户和组,代码如下:
sudo groupadd mysql
sudo useradd -r -g mysql mysql
3.安装一些需要的软件,代码如下:
sudo apt-get install cmake automake autoconf libtool gcc g++ bison
如果只安装上面的扩展,编译过程总会出现这样的错误:-- Could NOT find Curses (missing: CURSES_LIBRARY CURSES_INCLUDE_PATH) CMake Error at cmake/readline.cmake:83 (MESSAGE):Curses library not found. Please install appropriate package, remove CMakeCache.txt and rerun cmake.On Debian/Ubuntu, package name is libncurses5-dev,on Redhat and derivates it is ncurses-devel.,则需要多安装libncurses5-dev包.
热门评论