在Ubuntu上使用ruby在rails上安装MySQL [ERROR]

前端之家收集整理的这篇文章主要介绍了在Ubuntu上使用ruby在rails上安装MySQL [ERROR]前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。
捆绑安装 mysql时发生错误
我有工作台和服务器,我可以连接到它,所以这不是问题.
Installing MysqL (2.8.1) with native extensions /home/ahmet/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/installer.rb:551:in `rescue in block in build_extensions': ERROR: Failed to build gem native extension. (Gem::Instal ler::ExtensionBuildError)

        /home/ahmet/.rvm/rubies/ruby-1.9.2-p290/bin/ruby extconf.rb  checking for MysqL_query() in -lMysqLclient... no checking for main() in -lm... yes checking for MysqL_query() in -lMysqLclient... no checking for main() in -lz... yes checking for MysqL_query() in
-lMysqLclient... no checking for main() in -lsocket... no checking for MysqL_query() in -lMysqLclient... no checking for main() in -lnsl... yes checking for MysqL_query() in -lMysqLclient... no checking for main() in -lmygcc... no checking for MysqL_query() in -lMysqLclient... no
*** extconf.rb Failed *** Could not create Makefile due to some reason,probably lack of necessary libraries and/or headers.  Check the mkmf.log file for more details.  You may need configuration options.

Provided configuration options:
        --with-opt-dir
        --without-opt-dir
        --with-opt-include
        --without-opt-include=${opt-dir}/include
        --with-opt-lib
        --without-opt-lib=${opt-dir}/lib
        --with-make-prog
        --without-make-prog
        --srcdir=.
        --curdir
        --ruby=/home/ahmet/.rvm/rubies/ruby-1.9.2-p290/bin/ruby
        --with-MysqL-config
        --without-MysqL-config
        --with-MysqL-dir
        --without-MysqL-dir
        --with-MysqL-include
        --without-MysqL-include=${MysqL-dir}/include
        --with-MysqL-lib
        --without-MysqL-lib=${MysqL-dir}/lib
        --with-MysqLclientlib
        --without-MysqLclientlib
        --with-mlib
        --without-mlib
        --with-MysqLclientlib
        --without-MysqLclientlib
        --with-zlib
        --without-zlib
        --with-MysqLclientlib
        --without-MysqLclientlib
        --with-socketlib
        --without-socketlib
        --with-MysqLclientlib
        --without-MysqLclientlib
        --with-nsllib
        --without-nsllib
        --with-MysqLclientlib
        --without-MysqLclientlib
        --with-mygcclib
        --without-mygcclib
        --with-MysqLclientlib
        --without-MysqLclientlib


Gem files will remain installed in /home/ahmet/.rvm/gems/ruby-1.9.2-p290/gems/MysqL-2.8.1 for inspection. Results logged to /home/ahmet/.rvm/gems/ruby-1.9.2-p290/gems/MysqL-2.8.1/ext/MysqL_api/gem_make.out
        from /home/ahmet/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/installer.rb:529:in `block in build_extensions'
        from /home/ahmet/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/installer.rb:504:in `each'
        from /home/ahmet/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/installer.rb:504:in `build_extensions'
        from /home/ahmet/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/installer.rb:180:in `install'
        from /home/ahmet/.rvm/gems/ruby-1.9.2-p290/gems/bundler-1.0.16/lib/bundler/source.rb:101:in `block in install'
        from /home/ahmet/.rvm/gems/ruby-1.9.2-p290/gems/bundler-1.0.16/lib/bundler/rubygems_integration.rb:78:in `preserve_paths'
        from /home/ahmet/.rvm/gems/ruby-1.9.2-p290/gems/bundler-1.0.16/lib/bundler/source.rb:91:in `install'
        from /home/ahmet/.rvm/gems/ruby-1.9.2-p290/gems/bundler-1.0.16/lib/bundler/installer.rb:58:in `block (2 levels) in run'
        from /home/ahmet/.rvm/gems/ruby-1.9.2-p290/gems/bundler-1.0.16/lib/bundler/rubygems_integration.rb:93:in `with_build_args'
        from /home/ahmet/.rvm/gems/ruby-1.9.2-p290/gems/bundler-1.0.16/lib/bundler/installer.rb:57:in `block in run'
        from /home/ahmet/.rvm/gems/ruby-1.9.2-p290/gems/bundler-1.0.16/lib/bundler/installer.rb:49:in `run'
        from /home/ahmet/.rvm/gems/ruby-1.9.2-p290/gems/bundler-1.0.16/lib/bundler/installer.rb:8:in `install'
        from /home/ahmet/.rvm/gems/ruby-1.9.2-p290/gems/bundler-1.0.16/lib/bundler/cli.rb:220:in `install'
        from /home/ahmet/.rvm/gems/ruby-1.9.2-p290/gems/bundler-1.0.16/lib/bundler/vendor/thor/task.rb:22:in `run'
        from /home/ahmet/.rvm/gems/ruby-1.9.2-p290/gems/bundler-1.0.16/lib/bundler/vendor/thor/invocation.rb:118:in `invoke_task'
        from /home/ahmet/.rvm/gems/ruby-1.9.2-p290/gems/bundler-1.0.16/lib/bundler/vendor/thor.rb:263:in `dispatch'
        from /home/ahmet/.rvm/gems/ruby-1.9.2-p290/gems/bundler-1.0.16/lib/bundler/vendor/thor/base.rb:386:in `start'
        from /home/ahmet/.rvm/gems/ruby-1.9.2-p290/gems/bundler-1.0.16/bin/bundle:13:in `<top (required)>'
        from /home/ahmet/.rvm/gems/ruby-1.9.2-p290/bin/bundle:19:in `load'
        from /home/ahmet/.rvm/gems/ruby-1.9.2-p290/bin/bundle:19:in `<main>'
在安装MysqL gem之前安装以下.
sudo apt-get install MysqL-server MysqL-client
sudo apt-get install libMysqL-ruby libMysqLclient-dev
原文链接:https://www.f2er.com/ubuntu/349119.html

猜你在找的Ubuntu相关文章