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.

Tuesday, December 13, 2005

Dec 2005 SF Ruby Meetup Notes

The San Francisco Ruby Meetup Group met for the first time in a while on Dec 13, 2005. I did the 1st presentation - Running Ruby and Ruby-on-Rails on the Macintosh - because my colleague who promised to do it had to go on a business trip. It's basically a rehash of the steps in the following articles: When I was installing readline on my Mac, it was at version 5.1 but the instructions in the 1st article was still referring to version 5.0. The instructions have now been updated to 5.1 and the following note (here for historical purpose) can be ignored:
Note that the latest version of readline is 5.1 and you don't have to do the business with sed/mv after running configure (skip these two lines):
sed -e 's/-dynamic/-dynamiclib/' shlib/Makefile > shlib/Makefile.new
mv shlib/Makefile.new shlib/Makefile