RVM 1.0.2 fails to build ruby 1.9.2 - ruby-1.9

This fails every time. I ran rvm remove 1.9.2 and then rvm install 1.9.2.
The error looks like this:
info: Applying patch '' (located at /)
error: Error running 'patch -F25 -p1 -f <"/"',
please check /Users/peter/.rvm/log/ruby-1.9.2-p0/patch.apply.*.log
fail: There has been an error applying the specified patches.
Aborting the installation.
And the log shows this:
[2010-09-05 19:38:14] patch -F25 -p1 -f <"/"
patch: **** read error : Is a directory
This worked fine with rvm 1.0.1.
Any idea what's up and how I can roll back rvm to 1.0.1?

For me, simply running rvm update (without --head) let Ruby 1.9.2 install right.

Related

"ruby-2.0.0-p0 is not installed" after trying to install with RVM

If I run rvm install 2.0.0, it goes through the normal steps (downloading, extracting, configuring, compiling, installing), but ends by simply saying:
ruby-2.0.0-p0 is not installed.
To install do: 'rvm install ruby-2.0.0-p0'
I've tried the following:
rvm remove 2.0.0
rvm get head
rvm requirements
rvm install ruby-2.0.0
I keep getting the same result: no error, it just "is not installed." Anybody know what's wrong?
I had the same issue and managed to work it out.
When I did an echo $CC it came up with /usr/bin/gcc-4.2. So I did an export CC=clang, then rvm reinstall 2.0.0 and it worked.
Hope that helps.
rvm get ruby here => http://ftp.ruby-lang.org/pub/ruby/
Maybe you should get the right ruby version to install. Something like ruby-2.0.0-rc1 or ruby-2.0.0-rc2 is the latest ruby version.
if you are getting this message when you open a Rails folder, then you need to remove the .ruby-version file which is inside the folder and re-run a bundle install:
rm .ruby-version
bundle install

'rvm get head' unrecognized command line argument: 'get' (see: 'rvm usage') on Ubuntu 11.10 oneric

I have following version of rvm installed on ubuntu 11.0.
$ rvm -v
rvm 1.0.1 by Wayne E. Seguin (wayneeseguin#gmail.com) [http://rvm.beginrescueend.com/]
However, on running rvm get head, I am getting following errors.
$ rvm get head && rvm reload
fail: Unrecognized command line argument: 'get' ( see: 'rvm usage' )
$ rvm update --head
rvm 1.0.1 by Wayne E. Seguin (wayneeseguin#gmail.com) [http://rvm.beginrescueend.com/]
fatal: destination path 'rvm' already exists and is not an empty directory.
fatal: destination path 'rvm' already exists and is not an empty directory.
Can you help me find out what is the problem? and what to do to fix it?
You have very old RVM installation, probably from Ubuntu, use this answer:
Installed Ruby 1.9.3 with RVM but command line doesn't show ruby -v
It will help you clean your system and install stable version of RVM.
As a hint, you could use following command to install RVM, Ruby and Rails in one hit:
curl -L get.rvm.io | bash -i stable --rails --auto

Capistrano + RVM rvm_install_ruby with Rubinius

I am trying to fully automate the setup of my deployment host, and so avoiding manual install of Ruby.
I am using capistrano-rvm as it promises to do the job, but I have a problem when RVM compiles Rubinius:
** [out] rbx-2.0.0pre - #configuring
** [out] rbx-2.0.0pre - #compiling
*** [err] Error running '/home/app/.rvm/wrappers/ruby-1.8.7-p358/rake install', please read /home/app/.rvm/log/rbx-2.0.0pre/rake.log
The content of /home/app/.rvm/log/rbx-2.0.0pre/rake.log is:
ERROR: Gem rake is not installed, run `gem install rake` first.
How could I? That should have been done by RVM, no?
Does anyone already met & get out of this issue?
EDIT
I forgot to mention that RVM did load & compile 1.8.7 before rbx, seems like a dependence for build. Maybe RVM is running in a gem set which is badly initialized?
I thought the 2.0.0pre was removed from rbx already, it looks like you have older RVM installation, make sure you update RVM:
curl -L get.rvm.io | bash -s stable --auto
rvm reload
This will run the installer which also makes update.
To make sure everything works properly use rbx-2.0.testing which is supposed to work version of rbx.

rvm install ree complaining about readline on Ubuntu

I'm trying to install ree-1.8.7 on Ubuntu 11.10, but I get the following:
$ rvm install ree-1.8.7
$ ...
$ ERROR: Error running './installer -a $HOME/.rvm/rubies/ree-1.8.7-2011.03 --dont-install-useful-gems -c --with-readline-dir=$HOME/.rvm/usr', please read $HOME/.rvm/log/ree-1.8.7-2011.03/install.log
$ ERROR: There has been an error while trying to run the ree installer. Halting installation.
If I check the install.log file as suggested, it says that:
GNU Readline development headers... not found
...
Please run apt-get install libreadline5-dev as root
That didn't work because the package is no longer available, so I finally found out about using libreadline from a rvm package. So I install it and run the install again:
$ rvm pkg install readline
$ rvm install ree-1.8.7 -C --with-readline-dir=$rvm_path/usr
I still get the same error even if I run rvm remove ree beforehand.
I'm stuck, what can I do?
UPDATE: I'm still stuck, but I found something that might be useful for others with a similar issue even though it didn't work for me. From the RVM REE page:
NOTE: on any OS, if installation of REE fails and the output file reports missing readline-devel, zlib-devel, and openssl-devel headers AND you are sure that you have read the packages install instructions - or you are otherwise positive that you have the necessary packages installed in a known location - check your PATH environment variable to make sure something like "/usr/lib" is NOT present. See this REE issue for more information. If you don't want to change your PATH variable then this patch fixes the issue in REE 2010.02
I checked my path and all I had that contained /usr/lib was /usr/lib/lightdm/lightdm. My full $PATH is this: bash: /home/michel/.rvm/gems/ruby-1.9.3-p0/bin:/home/michel/.rvm/gems/ruby-1.9.3-p0#global/bin:/home/michel/.rvm/rubies/ruby-1.9.3-p0/bin:/home/michel/.rvm/bin:/usr/lib/lightdm/lightdm:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games: No such file or directory.
I finally got it working by running this line:
rvm install ree --with-readline-dir=$rvm_path/usr --with-iconv-dir=$rvm_path/usr --with-zlib-dir=$rvm_path/usr --with-openssl-dir=$rvm_path/usr
Running only rvm install ree --with-readline-dir=$rvm_path/usr didn't work, so maybe they all need to be run at the same time.
Note that I ran the following commands some time before succeeding:
rvm head update; rvm reload;
# remove any file from previous failed installations
rvm remove ree
# as suggested in a comment on the question
sudo apt-get install libreadline6-dev
I'm not sure if the libreadline6-dev was necessary, but maybe and it's worth a try if you're having trouble.

Need help setting up passenger with RVM

I'm trying to setup passenger with rvm. I keep getting this error
Your RVM wrapper scripts are too old.
Please update them first by running
'rvm update --head && rvm reload &&
rvm repair all'.
I did that still same problem
GNU C++ compiler... found at /usr/bin/g++
Curl development headers with SSL support... found
OpenSSL development headers... found
Zlib development headers... found
Ruby development headers... found
OpenSSL support for Ruby... found
RubyGems... found
Your RVM wrapper scripts are too old.
Please update them first by running 'rvm update
--head && rvm reload && rvm repair all'.
I'm using Fedora 14, Ruby 1.9.2, Rails 3.0.7
RVM is installed for multiuser
I also get this error when I do 'passenger start'
Cannot execute
'/home/antarr/.passenger/standalone/3.0.7-x86_64-ruby1.9.2-linux-gcc4.5.1-1002/support/helper-scripts/prespawn
http://0.0.0.0:3000': Permission
denied (13)
I was having the same issue but found that using the rvmsudo command worked. Instead of
sudo passenger-install-apache2-module
try using:
rvmsudo passenger-install-apache2-module
It looks like Passenger 3.0.7 is confused by newer versions of rvm, but it seems like the instructions are incorrect and it's causing trouble. If the GEM_HOME environment variable is not set you get this error.
The correct instructions should be to use your particular version first:
rvm use 1.9.2
Although I got the same error as you, after that it worked for me.
If none of the above solutions work for you and you're getting the GEM_HOME warning
delete everything in .rvmrc
rvm get head && rvm reload && rvm repair all
gem install passenger
passenger-install-apache2-module
copy/paste the end message into your apache.conf
I am still having the same issue with passenger 3.0.19 if I tried to install on gemsets other than default and global. This is soooo troublesome. I have tried many suggestions and even rvm implode, then have everything brand new. but still hitting the brick wall. my forehead almost flatten. Hope not to lose my head!
Luckily, I found myself a fix. I found out that in i am in rvm multiuser envrioment and the issue arised if I switch to user gemset using command: "rvm user gemsets" which basically will create and use .rvm folder in user's home folder. e.g.: /home/.rvm instead of /ur/local/rvm folder. Since I do not know how to switch back and could not find any documention on how to, I did the following steps:
remove .rvm folder in the user home folder,
rm -rf ~username/.rvm
added back the user to rvm group (in multi enviroment, every new user need to be added to rvm group)
sudo usermod -a -G rvm username
re-login.
Now, as long as I am using shared rvm gemset folder, phusion passenger wont complaint.
Hope that helps someone.
I fixed the Permission Denied issue with:
chmod a+x /Users/tvd/.passenger/standalone/3.0.7-x86_64-ruby1.9.2-macosx-10.6/support/helper-scripts/*
Found it in comment section on the phusion.nl blog:
Goto Comment on Phusion Blog