gitlab4安装mysql出问题解决方法

mysql不能自动安装

在新安装的ubuntu系统上面bunlde的时候遇到了这样一个问题:

  1. Installing mysql2 (0.3.11) with native extensions   
  2. Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension.  
  3.   
  4.         /home/ailen/.rvm/rubies/ruby-1.9.3-p327/bin/ruby extconf.rb   
  5. checking for rb_thread_blocking_region()... yes  
  6. checking for rb_wait_for_single_fd()... yes  
  7. checking for mysql_query() in -lmysqlclient... no  
  8. checking for main() in -lm... yes  
  9. checking for mysql_query() in -lmysqlclient... no  
  10. checking for main() in -lz... yes  
  11. checking for mysql_query() in -lmysqlclient... no  
  12. checking for main() in -lsocket... no  
  13. checking for mysql_query() in -lmysqlclient... no  
  14. checking for main() in -lnsl... yes  
  15. checking for mysql_query() in -lmysqlclient... no  
  16. checking for main() in -lmygcc... no  
  17. checking for mysql_query() in -lmysqlclient... no  
  18. *** extconf.rb failed ***  
  19. Could not create Makefile due to some reason, probably lack of  
  20. necessary libraries and/or headers.  Check the mkmf.log file for more  
  21. details.  You may need configuration options.  
  22.   
  23. Provided configuration options:  
  24.     --with-opt-dir  
  25.     --with-opt-include  
  26.     --without-opt-include=${opt-dir}/include  
  27.     --with-opt-lib  
  28.     --without-opt-lib=${opt-dir}/lib  
  29.     --with-make-prog  
  30.     --without-make-prog  
  31.     --srcdir=.  
  32.     --curdir  
  33.     --ruby=/home/ailen/.rvm/rubies/ruby-1.9.3-p327/bin/ruby  
  34.     --with-mysql-config  
  35.     --without-mysql-config  
  36.     --with-mysql-dir  
  37.     --without-mysql-dir  
  38.     --with-mysql-include  
  39.     --without-mysql-include=${mysql-dir}/include  
  40.     --with-mysql-lib  
  41.     --without-mysql-lib=${mysql-dir}/lib  
  42.     --with-mysqlclientlib  
  43.     --without-mysqlclientlib  
  44.     --with-mlib  
  45.     --without-mlib  
  46.     --with-mysqlclientlib  
  47.     --without-mysqlclientlib  
  48.     --with-zlib  
  49.     --without-zlib  
  50.     --with-mysqlclientlib  
  51.     --without-mysqlclientlib  
  52.     --with-socketlib  
  53.     --without-socketlib  
  54.     --with-mysqlclientlib  
  55.     --without-mysqlclientlib  
  56.     --with-nsllib  
  57.     --without-nsllib  
  58.     --with-mysqlclientlib  
  59.     --without-mysqlclientlib  
  60.     --with-mygcclib  
  61.     --without-mygcclib  
  62.     --with-mysqlclientlib  
  63.     --without-mysqlclientlib  
  64.   
  65.   
  66. Gem files will remain installed in /home/ailen/.rvm/gems/ruby-1.9.3-p327/gems/mysql2-0.3.11 for inspection.  
  67. Results logged to /home/ailen/.rvm/gems/ruby-1.9.3-p327/gems/mysql2-0.3.11/ext/mysql2/gem_make.out  
  68. An error occurred while installing mysql2 (0.3.11), and Bundler cannot continue.  
  69. Make sure that `gem install mysql2 -v '0.3.11'` succeeds before bundling.  

解决方案是:

sudo apt-get install libmysql-ruby libmysqlclient-dev

 

http://blog.csdn.net/renkai611919/article/details/8223418

 

posted @ 2012-12-26 22:49  shiningrise  阅读(774)  评论(0编辑  收藏  举报
// 侧边栏目录 // https://blog-static.cnblogs.com/files/douzujun/marvin.nav.my1502.css