Error Failed To Build Gem Native Extension. Mysql 2
Contents |
here for a quick overview of the site Help Center Detailed answers error installing mysql2 error failed to build gem native extension to any questions you might have Meta Discuss the workings failed to build gem native extension mysql2 windows and policies of this site About Us Learn more about Stack Overflow the company Business unable to locate package libmysql-ruby Learn more about hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the
Install Mysql2 Gem
Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up ERROR: Error installing mysql2: ERROR: Failed to build gem native extension up vote 7 down vote favorite 1 I am having some problems failed to build gem native extension mysql2 mac when trying to install gem install mysql2 -v '0.3.17' for Rails. When I try to install it by running gem install mysql2 -v '0.3.17' or gem install mysql2 -v '0.3.17' it gives me the following error: ERROR: Error installing mysql2: ERROR: Failed to build gem native extension. Could not create Makefile due to some reason, probably lack of necessary libraries and/or headers. Check the file for more details. You may need configuration options. Provided configuration options: --with-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 --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-mysql-config --without-mysql-config Gem files will remain installed in `..../gems/ruby-1.9.3-p392/gems/mysql2-0.3.17 for inspection`. Results logged to `.../gems/ruby-1.9.3-p392/extensions/x86_64-darwin-14/1.9.1/mysql2-0.3.17/gem_make.out` How can I fix this and successfully install mysql2? Thanks all . mysql ruby-on-rails ruby ruby-on-rails-3 gem share|improve this question edited Jan 8 '15 at 3:02 Prakash Murthy 9,64132046 asked Jan 8 '15 at 2:40 Thanh Khiet Nguyen 3614 Could you i
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack Overflow the company Business gem install mysql2 windows Learn more about hiring developers or posting ads with us Stack Overflow Questions Jobs
Gem Install Mysql2 Fails
Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just
Install Mysql Gem Ubuntu
like you, helping each other. Join them; it only takes a minute: Sign up ERROR: Failed to build gem native extension - Error installing mysql2 up vote 31 down vote favorite 6 error while running bundle install http://stackoverflow.com/questions/27832120/error-error-installing-mysql2-error-failed-to-build-gem-native-extension Installing mysql2 (0.3.11) with native extensions Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension. ... Make sure that `gem install mysql2 -v '0.3.11'` succeeds before bundling. when i run Make sure that gem install mysql2 -v '0.3.11'.I still get the same error. mysql ruby-on-rails ruby rubygems bundler share|improve this question edited Nov 4 '13 at 10:07 asked Nov 4 '13 at 9:59 user2951937 add a comment| 3 Answers 3 active oldest votes up vote 80 http://stackoverflow.com/questions/19765290/error-failed-to-build-gem-native-extension-error-installing-mysql2 down vote accepted which OS are you using? anyway if you are using ubuntu, from this https://github.com/brianmario/mysql2/issues/8 run: sudo apt-get install mysql-client libmysqlclient-dev Otherwise for Mac users,(use brew to install) check this http://mxcl.github.com/homebrew/, or run: brew install mysql then sudo gem install mysql2 and for windows users check the link below for a solution. Error installing mysql2: Failed to build gem native extension I would recommend to use the normal command prompt. share|improve this answer edited Jan 14 '14 at 8:02 answered Nov 4 '13 at 10:06 ben 2,17111733 Great. This fixed the issue I had installing Gitlab. –jwinn Jan 9 '14 at 9:18 add a comment| up vote 0 down vote Sometimes you need to update your Ruby library, run this code: sudo gem update --system share|improve this answer answered Nov 26 '13 at 19:37 Mohammed Sawaie 293 add a comment| up vote 0 down vote Error fixed.. Try to install these packages.. sudo apt-get install libmysqlclient-dev sudo apt-get install bundler After installing the bundler.. try with gem install mysql2 Its working.. Cool :) share|improve this answer answered Jun 28 at 6:55 karthi kj 1 add a comment| Your Answer draft saved draft discarded Sign up or log in Sign up using Google Sign up using Facebook Sign up using Email and Password Post as a guest
Sign in Pricing Blog Support Search GitHub This repository Watch 77 Star 1,520 Fork 341 brianmario/mysql2 Code Issues 42 Pull requests 18 Projects 0 Pulse https://github.com/brianmario/mysql2/issues/364 Graphs New issue Error installing mysql2, Failed to build gem native extension. On Win XP with Ruby 2.0.0. #364 Closed wzup opened this Issue Mar 24, 2013 · 29 comments Projects None yet Labels None yet Milestone 0.3.14 Assignees No one assigned 19 participants wzup commented Mar 24, 2013 I cannot install the gem. I have pre-installed failed to MySQL here, no any spaces in the path: C:\mysql-5.6.10\mysql-5.6.10-win32 I have Ruby 2.0.0 from RubyInstaller. The command I type: C:\>gem install mysql2 --platform=ruby -- --with-mysql-dir="C:\mysql-5.6.10\mysql-5.6.10-win32" Readme.md says: If you have installed MySQL to a non-standard location, add gem install mysql2 --with-mysql-config=/some/random/path/bin/mysql_config What is /some/random/path/bin/mysql_config? I don't have any mysql_config file in bin/ directory of my MySQL installation. Could you explain what failed to build config is meant? A copy/paste part from the error message: ERROR: Error installing mysql2: ERROR: Failed to build gem native extension. C:/Ruby200/bin/ruby.exe extconf.rb --with-mysql-dir=C:\mysql-5.6.10\mysql-5.6.10-win32 checking for rb_thread_blocking_region()... *** 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=C:/Ruby200/bin/ruby What do all those configuration options mean? Do I have to pass any values with them for successful installation? Readme.md file doesn't provide info about them. Where may I find explanation? How to solve the issue? Is it even possible to install the gem on Win XP? jopich commented Mar 27, 2013 +1 for me during redmine installation process. I am under windows XP with Ruby 2.0.0 and DevKit installed as well. I use Wamp server for mysql. - when I try to do the "rake generate_secret_token" (from redmine install guide), I got "rake aborted! cannot load such file -- mysql2/2.0/mysql2" - and when I try to re build mys