running OS X 10.1.1, currently installed rbenv 2.1.4
> brew update && brew upgrade ruby-build
> rbenv install 2.1.5
Downloading ruby-2.1.5.tar.gz...
-> http://dqw8nmjcqpjn7.cloudfront.net/4305cc6ceb094df55210d83548dcbeb5117d74eea25196a9b14fa268d354b100
Installing ruby-2.1.5...
BUILD FAILED (OS X 10.10.1 using ruby-build 20141113)
Inspect or clean up the working tree at /var/folders/qv/jbvzshbs76n4tqm3w4mfcx680000gn/T/ruby-build.20141127071426.92947
Results logged to /var/folders/qv/jbvzshbs76n4tqm3w4mfcx680000gn/T/ruby-build.20141127071426.92947.log
Last 10 log lines:
make[1]: *** [ext/openssl/all] Error 2
make[1]: *** Waiting for unfinished jobs....
installing default readline libraries
checking ../.././parse.y and ../.././ext/ripper/eventids2.c
linking shared-object readline.bundle
linking shared-object psych.bundle
installing default psych libraries
installing default ripper libraries
linking shared-object ripper.bundle
make: *** [build-ext] Error 2
====== from build log ...
compiling ossl_asn1.c
In file included from openssl_missing.c:22:
./openssl_missing.h:71:6: error: conflicting types for 'HMAC_CTX_copy'
void HMAC_CTX_copy(HMAC_CTX *out, HMAC_CTX *in);
^
/usr/include/openssl/hmac.h:102:5: note: previous declaration is here
int HMAC_CTX_copy(HMAC_CTX *dctx, HMAC_CTX *sctx);
^
In file included from openssl_missing.c:22:
./openssl_missing.h:95:5: error: conflicting types for 'EVP_CIPHER_CTX_copy'
int EVP_CIPHER_CTX_copy(EVP_CIPHER_CTX *out, EVP_CIPHER_CTX *in);
^
/usr/include/openssl/evp.h:502:5: note: previous declaration is here
int EVP_CIPHER_CTX_copy(EVP_CIPHER_CTX *out, const EVP_CIPHER_CTX *in);
^
openssl_missing.c:26:1: error: conflicting types for 'HMAC_CTX_copy'
HMAC_CTX_copy(HMAC_CTX *out, HMAC_CTX *in)
^
/usr/include/openssl/hmac.h:102:5: note: previous declaration is here
int HMAC_CTX_copy(HMAC_CTX *dctx, HMAC_CTX *sctx);
^
openssl_missing.c:121:1: error: conflicting types for 'EVP_CIPHER_CTX_copy'
EVP_CIPHER_CTX_copy(EVP_CIPHER_CTX *out, EVP_CIPHER_CTX *in)
^
/usr/include/openssl/evp.h:502:5: note: previous declaration is here
int EVP_CIPHER_CTX_copy(EVP_CIPHER_CTX *out, const EVP_CIPHER_CTX *in);
^
4 errors generated.
make[2]: *** [openssl_missing.o] Error 1
make[2]: *** Waiting for unfinished jobs....
Can you report us the result of:
for openssl in `which -a openssl`; do echo $openssl `$openssl version | head -1`; done
Homebrew breaks Ruby on Yosemite ( I guess you mean OSX 10.10.1 ) in a couple of ways.
brew uninstall ruby
Then try again. Either use a ruby provided by rbenv or rvm, but never install python or ruby with Homebrew, as it does not play well currently.
I should also add that Ruby 2 gets shipped with Yosemite, so you should not have a problem getting rbenv (which you CAN install with brew) to work.
@erwin Did you solve your issue?
Closing due to stale. Further reports should go to https://github.com/sstephenson/ruby-build/issues tracker instead. Thanks!
If someone stumbles over this - this worked for me: https://github.com/rbenv/ruby-build/issues/1489
Most helpful comment
If someone stumbles over this - this worked for me: https://github.com/rbenv/ruby-build/issues/1489