0

I just need a big help while i was facing this for past 3 months.

I am using windows 8 machine.

I was trying to install ruby in rails.Everything got success.

but while installing mysql gem i can face many errors which i have copied and pasted below

C:\Users\Mounarajan P A>gem install mysql Temporarily enhancing PATH to include DevKit... Building native extensions. This could take a while... ERROR: Error installing mysql: ERROR: Failed to build gem native extension. C:/Ruby200-x64/bin/ruby.exe extconf.rb checking for main() in -llibmysql... 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=C:/Ruby200-x64/bin/ruby --with-mysql-dir --without-mysql-dir --with-mysql-include --without-mysql-include=${mysql-dir}/include --with-mysql-lib --without-mysql-lib=${mysql-dir}/ --with-libmysqllib --without-libmysqllib Gem files will remain installed in C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/mysql -2.9.1 for inspection. Results logged to C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/mysql-2.9.1/ext/mysql_ api/gem_make.out 

2 Answers 2

1

Actually we should have the native development libraries when installing native extensions. For ubuntu it is libmysql2-dev, the same way find what is the dev lib for windows and install it. That could be solve your problem

Sign up to request clarification or add additional context in comments.

Comments

1

Do you mean to use the mysql gem? I thought mysql2 is now the standard/recommended gem to use with mysql databases.

Anyhow, this link might help you to get it installed: Unable to install mysql2 gem on windows 7

3 Comments

now -libmysql is installed but it again gives error as mysql.h is missing now what to do with this?
Do you actually have mysql installed? That is required before you can install the gem.
Hi tried reinstalling mysql but when i install mysql it shows mysql cant install in port 3306 this is an installation error

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.