-
-
Save ruycer/4711503 to your computer and use it in GitHub Desktop.
| I try to install via rvm Ruby 1.9.3 in my machine but I get this error: | |
| ruycer:~ ruycer$ rvm install 1.9.3 | |
| Searching for binary rubies, this might take some time. | |
| No binary rubies available for: osx/10.8/x86_64/ruby-1.9.3-p374. | |
| Continuing with compilation. Please read 'rvm mount' to get more information on binary rubies. | |
| Installing Ruby from source to: /Users/ruycer/.rvm/rubies/ruby-1.9.3-p374, this may take a while depending on your cpu(s)... | |
| ruby-1.9.3-p374 - #downloading ruby-1.9.3-p374, this may take a while depending on your connection... | |
| ruby-1.9.3-p374 - #extracted to /Users/ruycer/.rvm/src/ruby-1.9.3-p374 (already extracted) | |
| ruby-1.9.3-p374 - #configuring | |
| ruby-1.9.3-p374 - #compiling | |
| Error running 'make', please read /Users/ruycer/.rvm/log/ruby-1.9.3-p374/make.log | |
| There has been an error while running make. Halting the installation. | |
| I have installed all the packages via homebrew (updated them also) | |
| apple-gcc42 automake libgpg-error libtool libxslt openssl readline | |
| autoconf git libksba libxml2 libyaml pkg-config sqlite | |
| The log of make looks like this: | |
| [2013-02-04 19:31:30] make | |
| CC = /usr/local/bin/gcc-4.2 | |
| LD = ld | |
| LDSHARED = /usr/local/bin/gcc-4.2 -dynamic -bundle | |
| CFLAGS = -O3 -ggdb -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wno-long-long -Wno-missing-field-initializers -Werror=pointer-arith -Werror=write-strings -Werror=declaration-after-statement -Werror=shorten-64-to-32 -Werror=implicit-function-declaration -pipe | |
| XCFLAGS = -include ruby/config.h -include ruby/missing.h -fvisibility=hidden -DRUBY_EXPORT | |
| CPPFLAGS = -D_XOPEN_SOURCE -D_DARWIN_C_SOURCE -I/Users/ruycer/.rvm/usr/include -I. -I.ext/include/x86_64-darwin12.2.1 -I./include -I. | |
| DLDFLAGS = -Wl,-undefined,dynamic_lookup -Wl,-multiply_defined,suppress -Wl,-flat_namespace | |
| SOLIBS = | |
| linking miniruby | |
| rbconfig.rb unchanged | |
| generating enc.mk | |
| generating prelude.c | |
| compiling prelude.c | |
| linking static-library libruby-static.a | |
| generating encdb.h | |
| encdb.h unchanged | |
| making enc | |
| make[1]: Nothing to be done for `enc'. | |
| making srcs under enc | |
| make[1]: Nothing to be done for `srcs'. | |
| generating transdb.h | |
| transdb.h unchanged | |
| making trans | |
| make[1]: Nothing to be done for `./enc/trans'. | |
| making encs | |
| installing default resize libraries | |
| installing default bug libraries | |
| installing default bug libraries | |
| installing default funcall libraries | |
| installing default dot.dot libraries | |
| installing default old_thread_select libraries | |
| installing default numhash libraries | |
| installing default string libraries | |
| installing default wait_for_single_fd libraries | |
| make[2]: Nothing to be done for `all'. | |
| make[2]: Nothing to be done for `all'. | |
| installing default bigdecimal libraries | |
| installing default continuation libraries | |
| installing default coverage libraries | |
| installing default curses libraries | |
| installing default date_core libraries | |
| installing default dbm libraries | |
| installing digest libraries | |
| installing default digest libraries | |
| installing default bubblebabble libraries | |
| installing default md5 libraries | |
| installing default rmd160 libraries | |
| linking shared-object digest/sha1.bundle | |
| collect2: ld terminated with signal 11 [Segmentation fault: 11] | |
| make[2]: *** [../../../.ext/x86_64-darwin12.2.1/digest/sha1.bundle] Error 1 | |
| make[1]: *** [ext/digest/sha1/all] Error 2 | |
| make: *** [build-ext] Error 2 |
Same here, any insights from your side?
I guess I have a solution
The weird thing was that it perfectly compiled when I did a make clean, ./configure, make, make test, and make install in the .rvm/src directory.
After comparing the Makefiles, I found out that the thing that caused the error was the config flag --with-opt-dir=/Userpath/.rvm/usr
Finally, I figured that he openssl in that path was the problem. So I removed it. It worked.
herbertbay any chance you might be willing to explain your process to get this working in some more detail for a relative newbie? I haven't been able to figure it out so far.
I second that AaronCPacheco.
I was having the same problem after recently setting up an OSX 10.8.2 machine. I installed XCode 4.6 with the most recent version of Command Line Tools and was unable to successfully use rvm to install rubies. I was able to get 1.9.3 installed by specifying gcc to be used for compiling rvm install 1.9.3 --with-gcc=gcc This example assumes gcc is in your system path. Otherwise, you can specify which gcc binary name/path you'd like to use that is installed on your system.
@AaronCPacheco and @gillesguillemin
To clarify herbertbay's solution:
The problem seems to be caused by an openssl package installed by rvm. To remove this package you need to run
rvm pkg uninstall openssl
and reinstall ruby. If this doesn't work, try removing all the packages, using
rvm pkg remove #
and reinstalling ruby (via rvm)
Thanks, I had the exact same error and was going crazy. Removing openssl fixed it.
Thanks @KettlebellAddict. In my case tip #1 didn't work but tip #2 made the trick.
I have been all over the internet for days looking for a way to install Ruby and this is the only solution that appears to have actually worked. (tip #2)
Thank you soooooooo much!
@KettlebellAddict thanks, #1 failed but tip #2 worked for me as well
@KettlebellAddict Dido for me. Tip 2 worked!
Keep on swinging those kettlebells!
I am having the same exact errors... Could you get your Ruby to work?