Tag: How-to

gem install mysql on linux

It might be a problem, an “old” well-known issue…

sudo gem install mysql

might return an error like:

ERROR:  While executing gem ... (Gem::Installer::ExtensionBuildError)
    ERROR: Failed to build gem native extension.

Well, this is cause you need the -dev environment of mysql. Too easy to think that it could be mysql-dev, no! just try

apt-get install libmysqlclient15-dev

It will works!

gem install mysql on linux