Cygwin Rails and MySQL

January 27, 2008

Many others have done this, so thanks to those who provided the info used here.

Gem Installation

When setting up gems unset the environment variable RUBYOPT RUBYOPT=""

Rails Installation

Don’t need --include-dependencies switch any more, they’re installed by default.


In Cygwin you’ll want to install the MySQL gem. This needs the MySql libraries/source in order to build, so you need to download the source. Then run

./configure make install

This failed at first, trying to resolve by

  • installing g++ using cygwin setup

Now you have what you need to install the MySql gem. gem install mysql