Tuesday, December 20, 2005

Ruby MySQL native bindings on Fedora Core

In this article about installing Ruby, and Ruby-on-Rails for Mac OSX, I found that it also works for Fedora Core 2 Linux (and probably other *nuxes). However, if MySQL was installed with RPM, there isn't one root MySQL directory. Thus, the last command that you issue must be modified to point to where the include and lib files are located. So instead of using this command to install the Ruby MySQL native bindings:
  • sudo gem install mysql -- --with-mysql-dir=/usr/local/mysql
You need to use this command
  • sudo gem install mysql -- --with-mysql-include=/usr/include/mysql --with-mysql-lib=/usr/lib/mysql
And by the way, though the lib files are included in the standard mysql RPM distribution, the include files aren't. You'll also need mysql-devel for the include files.

0 Comments:

Post a Comment

<< Home