原文链接:http://my.oschina.net/u/249914/blog/177234
新装的机器Gnome-Ubuntu-13.10,编译安装mysql-5.6.14.tar.gz
命令
?
1 | cmake -DCMAKE_INSTALL_PREFIX= /usr/local/database/mysql5 .6? -DSYSCONFDIR= /usr/local/database/mysql5 .6 /etc ? -DMYSQL_DATADIR= /data/mysql/3306 ? -DMYSQL_TCP_PORT=3306? -DMYSQL_UNIX_ADDR= /tmp/mysqld-3306 .sock? -DMYSQL_USER=mysql? -DEXTRA_CHARSETS=all? -DWITH_READLINE=1? -DWITH_EMBEDDED_SERVER=1? -DENABLED_LOCAL_INFILE=1? -DWITH_INNOBASE_STORAGE_ENGINE=1 -DENABLE_DOWNLOADS=1 -DDEFAULT_CHARSET=utf8mb4 |
CMake Error at /usr/share/cmake-2.8/Modules/CMakeCXXInformation.cmake:37 (get_filename_component):
get_filename_component called with incorrect number of arguments
Call Stack (most recent call first):
CMakeLists.txt:3 (PROJECT)
CMake Error: CMAKE_CXX_COMPILER not set, after EnableLanguage
CMake Error: Internal CMake error, TryCompile configure of cmake failed
-- Performing Test HAVE_PEERCRED - Failed
-- Library mysqlclient depends on OSLIBS -lpthread;m;dl
-- GMOCK_SOURCE_DIR:/usr/local/database/mysql-5.6.14/source_downloads/gmock-1.6.0
-- Performing Test HAVE_NO_NULL
CMake Error at /usr/share/cmake-2.8/Modules/CMakeCXXInformation.cmake:37 (get_filename_component):
get_filename_component called with incorrect number of arguments
Call Stack (most recent call first):
CMakeLists.txt:3 (PROJECT)
CMake Error: CMAKE_CXX_COMPILER not set, after EnableLanguage
CMake Error: Internal CMake error, TryCompile configure of cmake failed
-- Performing Test HAVE_NO_NULL - Failed
-- Performing Test HAVE_NO_UNUSED_TYPEDEFS
CMake Error at /usr/share/cmake-2.8/Modules/CMakeCXXInformation.cmake:37 (get_filename_component):
get_filename_component called with incorrect number of arguments
Call Stack (most recent call first):
CMakeLists.txt:3 (PROJECT)
CMake Error: CMAKE_CXX_COMPILER not set, after EnableLanguage
CMake Error: Internal CMake error, TryCompile configure of cmake failed
-- Performing Test HAVE_NO_UNUSED_TYPEDEFS - Failed
-- GTEST_LIBRARIES:gmock;gtest
Warning: Bison executable not found in PATH
-- Library mysqlserver depends on OSLIBS -lpthread;m;crypt;dl
-- Configuring incomplete, errors occurred!
解决方法:
sudo apt-get install g++