从源安装 MySQL 时出现“Could NOT find Curses”错误

Abd*_*naf 4 mysql mysql-5.5

我正在MySQL Server从我下载的源代码分发版进行安装:

http://dev.mysql.com/downloads/mysql/#downloads

我已经下载了文件(mysql-5.5.19.tar.gz)

我正在使用 Debian/Ubuntu 机器。我正在按照MySQL 文档中给出的说明进行操作。

cmake .shell发出后,我收到以下错误:

-- MySQL 5.5.19
-- 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.
Call Stack (most recent call first):
  cmake/readline.cmake:127 (FIND_CURSES)
  cmake/readline.cmake:217 (MYSQL_USE_BUNDLED_LIBEDIT)
  CMakeLists.txt:257 (MYSQL_CHECK_READLINE)


-- Configuring incomplete, errors occurred!
Run Code Online (Sandbox Code Playgroud)

为什么我收到这个错误?

Kev*_*Kev 5

线索在错误消息中(我今天也遇到了):

  1. 安装正确的 Curses 库。如果您使用的是 Debian/Ubuntu,则安装libncurses5-dev(使用sudo apt-get install libncurses5-dev
  2. 然后删除 CMakeCache.txt 并重新运行 cmake。即做rm -f CMakeCache.txt
  3. 重新运行 cmake .