# 'gem install' vs. 'ruby install.rb'. A few questions

**URL:** <https://www.ruby-forum.com/t/gem-install-vs-ruby-install-rb-a-few-questions/67456>\
**Category:** Ruby\
**Created:** [September 4, 2006, 2:44pm UTC](https://www.ruby-forum.com/t/gem-install-vs-ruby-install-rb-a-few-questions/67456 "2006-09-04T14:44:06Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![GSSSSraud\_Contisouz](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/ee7513/32.png) [@GSSSSraud\_Contisouz](https://www.ruby-forum.com/u/GSSSSraud_Contisouz)\
**Post date:** [September 4, 2006, 2:44pm UTC](https://www.ruby-forum.com/t/gem-install-vs-ruby-install-rb-a-few-questions/67456/1 "2006-09-04T14:44:06Z")

</div>

Hello list,

First, a little disclaimer : I don’t know jack on ruby, gem, rails or  
anything. I hit this problem after a week-end trying to install Typo  
on FreeBSD. Did my homework with grandma’ Google on my side, even went  
to IRC to burn some karma, and well, as they say in another corner of  
the programming language map, “Warnock Applies”.

To make a long story short : you can install (as in extract the gem  
and put the files in due place) Typo on FreeBSD but it won’t run.  
There’s a missing dependency --namely the new rails-app-installer  
gem-- which I tried to make a port for (for people in the GNU/Linux  
land, think ‘debian package’). Here is where I hit a wall :  
rails-app-installer needs sqlite3. There’s already a port for  
sqlite3-ruby in FreeBSD, that uses the ‘ruby install.rb’ way. On the  
filesystem, the files are stored in  
/usr/local/lib/ruby/site\_ruby/1.8/sqlite3/…

Now, trying to `gem install` the rails-app-installer it complains that  
sqlite3-ruby is missing. Indeed all the gems are installed in  
/usr/local/lib/ruby/gems/1.8/gems/ and I assume that it’s trying to  
check the deps within this directory. Now, please keep in mind that my  
goal is to fix the state of Typo in FreeBSD in general. I’m not  
interested in installing Typo just for myself, I have a greater goal  
than that 😉

So, here are my questions :

- Is it possible to tell gem to cross the border and have a look in  
…/site\_ruby/ for deps checking?

- If no, well, what could be the risks of having a ‘ruby install.rb’  
and a ‘gem install’ version of the same package at the same time?  
Would there be some kind of conflict that would make everything  
explode?

- If conflicts occur, is there any functional or performance-related  
difference between the two versions? Which one should be TheOne in  
your opinion?

I hope I made myself clear, I had issues on IRC to make people grok  
where I was heading. Anyway, thanks in advance for your wisdom.

Best regards,

Geraud

---

<div class="post-metadata">

**Author:** ![GSSSSraud\_Contisouz](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/ee7513/32.png) [@GSSSSraud\_Contisouz](https://www.ruby-forum.com/u/GSSSSraud_Contisouz)\
**Post date:** [September 6, 2006, 7:02pm UTC](https://www.ruby-forum.com/t/gem-install-vs-ruby-install-rb-a-few-questions/67456/2 "2006-09-06T19:02:36Z")

</div>

On 9/3/06, Géraud Contisouzas [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> Now, trying to `gem install` the rails-app-installer it complains that  
> sqlite3-ruby is missing. Indeed all the gems are installed in  
> /usr/local/lib/ruby/gems/1.8/gems/ and I assume that it’s trying to  
> check the deps within this directory. Now, please keep in mind that my  
> goal is to fix the state of Typo in FreeBSD in general. I’m not  
> interested in installing Typo just for myself, I have a greater goal  
> than that 😉

AFAIK, there’s no fakegem capability in RubyGems, which is essentially  
what you need for install.

I _think_ you can tell gem to ignore dependencies, but I’m not sure.  
Where you might run into a problem is if a gem specifically does a  
require\_gem (a no-no; there’s a new method to require a specific  
version which would _activate_ but not require the gem).

> - Is it possible to tell gem to cross the border and have a look in  
> …/site\_ruby/ for deps checking?

No. It doesn’t actually look for sqlite3/… it looks for the gem.

> - If no, well, what could be the risks of having a ‘ruby install.rb’  
> and a ‘gem install’ version of the same package at the same time?  
> Would there be some kind of conflict that would make everything  
> explode?

It would not be good.

> - If conflicts occur, is there any functional or performance-related  
> difference between the two versions? Which one should be TheOne in  
> your opinion?

In most cases, the Gem is probably a good choice. But not everyone  
agrees.

-austin

---

<div class="post-metadata">

**Author:** ![GSSSSraud\_Contisouz](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/g/ee7513/32.png) [@GSSSSraud\_Contisouz](https://www.ruby-forum.com/u/GSSSSraud_Contisouz)\
**Post date:** [September 13, 2006, 8:26pm UTC](https://www.ruby-forum.com/t/gem-install-vs-ruby-install-rb-a-few-questions/67456/3 "2006-09-13T20:26:16Z")

</div>

The sqlite3-ruby gem is working for me now on FreeBSD, but in case it  
helps someone: the gem has a dependency on swig, but it installs without  
it – it just doesn’t work. Even worse, it seems to work for some  
operations, but fails for others.

This maneuver fixed my problem:

gem uninstall sqlite3-ruby  
cd /usr/ports/devel/swig13  
make install  
gem install sqlite3-ruby
