Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Why won't Ruby 1.9.2-head install using RVM?

Tags:

ruby

rvm

ruby-1.9

I have been trying to install Ruby 1.9.2-head using RVM, but have been getting this error message:

echo executable host ruby is required

Is it compulsory to have system Ruby in order to install Ruby through RVM?

I have all the dependencies given in rvm notes, but I do not have any system Ruby installed. The error log shows:

[2011-05-02 07:42:19] make 
gcc -O3 -ggdb -Wextra -Wno-unused-parameter -Wno-parentheses -Wpointer-arith -Wwrite-strings -Wno-missing-field-initializers -Wno-long-long  -fPIC -I. -I.ext/include/i686-linux -I./include -I. -DRUBY_EXPORT   -o main.o -c main.c
gcc -O3 -ggdb -Wextra -Wno-unused-parameter -Wno-parentheses -Wpointer-arith -Wwrite-strings -Wno-missing-field-initializers -Wno-long-long  -fPIC -I. -I.ext/include/i686-linux -I./include -I. -DRUBY_EXPORT   -o dln.o -c dln.c
gcc -O3 -ggdb -Wextra -Wno-unused-parameter -Wno-parentheses -Wpointer-arith -Wwrite-strings -Wno-missing-field-initializers -Wno-long-long  -fPIC -I. -I.ext/include/i686-linux -I./include -I. -DRUBY_EXPORT   -o dmydln.o -c dmydln.c
gcc -O3 -ggdb -Wextra -Wno-unused-parameter -Wno-parentheses -Wpointer-arith -Wwrite-strings -Wno-missing-field-initializers -Wno-long-long  -fPIC -I. -I.ext/include/i686-linux -I./include -I. -DRUBY_EXPORT   -o dmyencoding.o -c dmyencoding.c
gcc -O3 -ggdb -Wextra -Wno-unused-parameter -Wno-parentheses -Wpointer-arith -Wwrite-strings -Wno-missing-field-initializers -Wno-long-long  -fPIC -I. -I.ext/include/i686-linux -I./include -I. -DRUBY_EXPORT   -o version.o -c version.c
gcc -O3 -ggdb -Wextra -Wno-unused-parameter -Wno-parentheses -Wpointer-arith -Wwrite-strings -Wno-missing-field-initializers -Wno-long-long  -fPIC -I. -I.ext/include/i686-linux -I./include -I. -DRUBY_EXPORT   -o dmyversion.o -c dmyversion.c
echo executable host ruby is required.  use --with-baseruby option.; false -I. ./tool/compile_prelude.rb ./prelude.rb miniprelude.c
executable host ruby is required. use --with-baseruby option.
make: *** [miniprelude.c] Error 1
like image 911
jayandra Avatar asked May 02 '11 02:05

jayandra


2 Answers

rvm notes also says

To install Ruby 1.9.2 you need to have Ruby 1.8.7 installed and set.

So, install Ruby 1.8.7, load it to the environment and install ruby 1.9.2

rvm install ruby-1.8.7-head
rvm use ruby-1.8.7-head
rvm install ruby-1.9.2-head

This solution has been tested.

like image 65
Shreyas Avatar answered Oct 15 '22 19:10

Shreyas


You don't have to have a system Ruby, so long as you've installed another Ruby (probably Ruby MRI 1.8) through RVM.

Thankfully, Ruby 1.8 doesn't require you have Ruby installed, so you don't have a bootstrapping problem.

like image 26
Andrew Grimm Avatar answered Oct 15 '22 19:10

Andrew Grimm