Linux MySQL源碼安裝缺少ncurses-devel包

來源:互聯網
上載者:User

標籤:

在Red Hat Enterprise Linux Server release 5.7 上用源碼安裝MySQL-5.6.23時,遇到了" remove CMakeCache.txt and rerun cmake.On Debian/Ubuntu, package name is libncurses5-dev, on Redhat and derivates it is ncurses-devel."錯誤,如下所示

[[email protected] mysql-5.6.23]# cmake ./ -DCMAKE_INSTALL_PREFIX=/usr/local/mysql -DMYSQL_DATADIR=/usr/local/mysql/data

.........................

-- Check size of wctype_t

-- Check size of wctype_t - done

-- Check size of wint_t

-- Check size of wint_t - done

-- Could NOT find Curses (missing: CURSES_LIBRARY CURSES_INCLUDE_PATH)

CMake Error at cmake/readline.cmake:85 (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:128 (FIND_CURSES)

cmake/readline.cmake:202 (MYSQL_USE_BUNDLED_EDITLINE)

CMakeLists.txt:409 (MYSQL_CHECK_EDITLINE)

 

按照錯誤提示,Debian/Ubuntu下需要安裝libncurses5-dev;Redhat下需要安裝ncurses-devel ,檢查是否安裝了ncurses包,如下所示,已經安裝了ncurses-5.5-24.20060715,但是缺少ncurses-devel包。

[[email protected] Server]# rpm -qa | grep ncurses
ncurses-5.5-24.20060715
ncurses-5.5-24.20060715
[[email protected] Server]# ls ncurses*
ncurses-5.5-24.20060715.i386.rpm    ncurses-devel-5.5-24.20060715.i386.rpm
ncurses-5.5-24.20060715.x86_64.rpm  ncurses-devel-5.5-24.20060715.x86_64.rpm
[[email protected] Server]# rpm -ivh ncurses-devel-5.5-24.20060715.x86_64.rpm 
warning: ncurses-devel-5.5-24.20060715.x86_64.rpm: Header V3 DSA signature: NOKEY, key ID 37017186
Preparing...                ########################################### [100%]
   1:ncurses-devel          ########################################### [100%]
[[email protected] Server]# 

安裝了ncurses-devel包後,刪除CMakeCache.txt,然後重新編譯,編譯成功,問題解決!

[[email protected] mysql-5.6.23]# rm CMakeCache.txt 
rm: remove regular file `CMakeCache.txt‘? yes
[[email protected] mysql-5.6.23]# cmake . -DCMAKE_INSTALL_PREFIX=/usr/local/mysql  -DMYSQL_DATADIR=/usr/local/mysql/data -DDEFAULT_CHARSET=utf8 -DDEFAULT_COLLATION=utf8_general_ci -DEXTRA_CHARSETS=all -DENABLED_LOCAL_INFILE=1

Linux MySQL源碼安裝缺少ncurses-devel包

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.