Problems with Sqlite3 and apt-get

I am new to Ruby, and have a problem to install Sqlite3.

After searching the previous posts, I found a solution, first to do :
sudo apt-get install libsqlite3-0 libsqlite3-dev

However, I am on an AWS Ec2 instance which don’t have apt-get, only
with yum. Would anyone please
tell me how to install apt-get, or how to use yum to install
libsqlite3-dev ? Really appreciate !

Scott

On Mar 3, 10:38am, Scott L Gu [email protected] wrote:

I am new to Ruby, and have a problem to install Sqlite3.

After searching the previous posts, I found a solution, first to do :
sudo apt-get install libsqlite3-0 libsqlite3-dev

However, I am on an AWS Ec2 instance which don’t have apt-get, only
with yum. Would anyone please
tell me how to install apt-get, or how to use yum to install
libsqlite3-dev ? Really appreciate !

The naming is slightly different - looks like sqlite-devel is the yum
package you want.

Fred

Thanks, Frederick, it works. I can go one step further now.

However, I still have a problem with “rails console”: `require’:
no such file to load – readline (LoadError)

I saw some solution to do : yum install ncurses-devel readline-
devel

I did it. However, the next steps should be :

cd <ruby_src>/ext/readline
ruby extconf.rb
make && make install

But I cannot find ext/readline in my ruby directory: /home/ec2-
user/.rvm/rubies/ruby-1.9.2-p180/
and don’t know where this extconf.rb should be :slight_smile:

Scott

On Mar 3, 3:51am, Frederick C. [email protected]

On Mar 3, 1:44pm, Scott L Gu [email protected] wrote:

cd <ruby_src>/ext/readline
ruby extconf.rb
make && make install

But I cannot find ext/readline in my ruby directory: /home/ec2-
user/.rvm/rubies/ruby-1.9.2-p180/
and don’t know where this extconf.rb should be :slight_smile:

it will be where the source code for ruby is. Seeing as you are using
rvm, the easiest thing is probably to ask rvm to reinstall ruby for
you - it should build the readline extension automatically now that
the readline development package is installed.

Fred

After I re-installed Ruby, ‘rails console’ works. Really appreciate
your helps, Frederick !

Scott

On Mar 3, 6:32am, Frederick C. [email protected]

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs