Problem configuring database with rubyonrails.

Hi,

I was trying to configure sqlite3 as a backend to work with rubyonrails.

First i did yum install sqlite and got the package installed. Then i did .I got an error message:

Building native extensions. This could take a while… ERROR: Error installing sqlite: ERROR: Failed to build gem native extension.

/usr/bin/ruby extconf.rb install sqlite can’t find header files for ruby.

Gem files will remain installed in /usr/lib/ruby/gems/1.8/gems/sqlite-2.0.1 for inspection. Results logged to /usr/lib/ruby/gems/1.8/gems/sqlite-2.0.1/ext/gem_make.out

Then i did and got an error message:

WARNING: Installing to ~/.gem since /usr/lib/ruby/gems/1.8 and /usr/bin aren’t both writable. WARNING: You don’t have /home/yevlempy/.gem/ruby/1.8/bin in your PATH, gem executables will not run. Building native extensions. This could take a while… ERROR: Error installing sqlite3-ruby: ERROR: Failed to build gem native extension.

/usr/bin/ruby extconf.rb install sqlite3-ruby can’t find header files for ruby.

Gem files will remain installed in /home/yevlempy/.gem/ruby/1.8/gems/sqlite3-ruby-1.2.5 for inspection. Results logged to /home/yevlempy/.gem/ruby/1.8/gems/sqlite3-ruby-1.2.5/ext/sqlite3_api/gem_make.out.

I am new to rubyonrails if anyone can help.I use fedora as linux distro.

Thanks, Regards, Yevlempy>Harsh Verma

/usr/bin/ruby extconf.rb install sqlite3-ruby can't find header files for ruby.

That is the right gem. You need to install the package that has the ruby development headers. Often called something like ruby-dev or ruby- devel (probably also for sqlite3)

Fred