I'm trying to install Ruby 1.9.3 using rvm. However, when I type:
rvm install 1.9.3
I get the following error:
ERROR: Error running 'make ', please read /Users/nick/.rvm/log/ruby-1.9.3-rc1/make.log
ERROR: There has been an error while running make. Halting the installation.
I'm running Mac OS X Lion and my current version of Ruby is 1.9.2.
Edit: make.log:
make[1]: Entering directory `/Users/nick/.rvm/src/ruby-1.9.3/ext/readline'
/usr/bin/gcc-4.2 -I. -I../../.ext/include/x86_64-darwin11.0.0 -I../.././include -I../.././ext/readline -DRUBY_EXTCONF_H=\"extconf.h\" -I/Users/nick/.rvm/usr/include -D_XOPEN_SOURCE -D_DARWIN_C_SOURCE -fno-common -O3 -ggdb -Wextra -Wno-unused-parameter -Wno-parentheses -Wpointer-arith -Wwrite-strings -Wno-missing-field-initializers -Wshorten-64-to-32 -Wno-long-long -fno-common -pipe -o readline.o -c readline.c
readline.c: In function ‘username_completion_proc_call’:
readline.c:1386: error: ‘username_completion_function’ undeclared (first use in this function)
readline.c:1386: error: (Each undeclared identifier is reported only once
readline.c:1386: error: for each function it appears in.)
make[1]: *** [readline.o] Error 1
make[1]: Leaving directory `/Users/nick/.rvm/src/ruby-1.9.3/ext/readline'
make: *** [mkmain.sh] Error 1
The simpler, more general solution is to explicitly install the offending package and then reinstall with that package. In my case, it was aborting on openssl_missing, so:
rvm pkg install openssl
rvm install 1.9.3 -C "--with-openssl-dir=$HOME/.rvm/usr"
For your case, it's probably:
rvm pkg install readline
rvm install 1.9.3 -C "--with-readline-dir=$HOME/.rvm/usr"
This of course assumes that you installed rvm as yourself. Change accordingly...
This is an issue with readline
. Try compiling readline
yourself from source:
curl -O ftp://ftp.gnu.org/gnu/readline/readline-6.1.tar.gz
tar xzvf readline-6.1.tar.gz
cd readline-6.1
./configure --prefix=/usr/local
make
sudo make install
Source
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With