CentOS 5, Ruby, and SQLite3 – Installation

Getting sqlite3 to work with ruby and centos5 is apparently something of a chore.

The notes below are the collected notes regarding how to get it to work.  The instructions appear to allow the sqlite ruby gem to be successfully installed.

Installing ruby and ruby gems on CentOS 5:

#yum install ruby

#yum install ruby-devel ruby-gems

[And the most important/non-obvious one: yum install sqlite-devel]

#yum install sqlite-devel

#gem install sqlite3-ruby

Note: after installing the sqlite3-ruby as a ruby gem, your ruby code will have to include the following in order to use the sqlite3 gem:

require ‘rubygems’

require ‘sqlite3’

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

w

Connecting to %s