On Sat, Jan 21, 2012 at 10:39 PM, Felipe Pieretti Umpierre <
li...@ruby-forum.com> wrote:

> Hello, I'm trying to install the rails on ubuntu 11.10, but when I put
> the command
>
> felipe@Felipe:~/Downloads/rubygems-1.8.15$ sudo gem install rails
> --no-r1 --no-rdoc
> ERROR:  Loading command: install (LoadError)
>    no such file to load -- zlib
> ERROR:  While executing gem ... (NameError)
>    uninitialized constant Gem::Commands::InstallCommand
> felipe@Felipe:~/Downloads/rubygems-1.8.15$
>
> it return this error, how can I install correctly.
>

1) The default first answer to these questions is, "use rvm" (really !).

  https://rvm.beginrescueend.com/

E.g. for Ubuntu 11.10, I wrote a detailed log of doing it from scratch
(and there are many others if you Google):


http://rails.vandenabeele.com/blog/2011/11/26/installing-ruby-and-rails-with-rvm-on-ubuntu-11-dot-10/

Note that you will NOT need to do "sudo" with rvm, It is a local install
that you could alway wipe out and start over etc. if you are
experimenting ...
(you could even make a separate "ror" user and do rvm there,
just to practice without risk.

2) If you really want to install system with sudo , than the specific
problem
you face is probably that you miss a number -dev libraries.

Probably

$ sudo apt-get install zlib1g zlib1g-dev

will get you out of this one and then you will probably hit the next error
...

(I recently installed on a different Ubuntu 11.10 without rvm, it was a lot
harder and the write-up is here:
http://rails.vandenabeele.com/blog/2012/01/15/installing-ruby-rails-passenger-on-ubuntu-11-dot-10/
Not advised unless you are more experienced).


HTH,

Peter

-- 
Peter Vandenabeele
http://twitter.com/peter_v
http://rails.vandenabeele.com

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to 
rubyonrails-talk+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en.

Reply via email to