Ошибка при инсталляции rbenv install 2.0.0-p0 в Centos 7 (make[2]: *** [ossl_pkey_ec.o] Error 1)
$ rbenv install 2.0.0-p0
Downloading yaml-0.1.6.tar.gz...
-> http://dqw8nmjcqpjn7.cloudfront.net/7da6971b4bd08a986dd2a61353bc422362bd0edcc67d7ebaac68c95f74182749
Installing yaml-0.1.6...
Installed yaml-0.1.6 to /home/developer/.rbenv/versions/2.0.0-p0
Downloading ruby-2.0.0-p0.tar.gz...
-> http://dqw8nmjcqpjn7.cloudfront.net/aff85ba5ceb70303cb7fb616f5db8b95ec47a8820116198d1c866cc4fff151ed
Installing ruby-2.0.0-p0...
BUILD FAILED (CentOS Linux 7 using ruby-build 20141113-8-g63f6fa2)
Inspect or clean up the working tree at /tmp/ruby-build.20141119154835.15141
Results logged to /tmp/ruby-build.20141119154835.15141.log
Last 10 log lines:
make[2]: *** [ossl_pkey_ec.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[2]: Leaving directory `/tmp/ruby-build.20141119154835.15141/ruby-2.0.0-p0/ext/zlib'
make[2]: Leaving directory `/tmp/ruby-build.20141119154835.15141/ruby-2.0.0-p0/ext/openssl'
make[1]: *** [ext/openssl/all] Error 2
make[1]: *** Waiting for unfinished jobs....
linking shared-object ripper.so
make[2]: Leaving directory `/tmp/ruby-build.20141119154835.15141/ruby-2.0.0-p0/ext/ripper'
make[1]: Leaving directory `/tmp/ruby-build.20141119154835.15141/ruby-2.0.0-p0'
make: *** [build-ext] Error 2
=========================================================
=========================================================
Решение которое помогло:
$ curl -fsSL https://gist.githubusercontent.com/eric1234/e23d63f99427b39787ca/raw/7859c4b08c9ae7c0cebc69d42cce2b553838dcf0/2.0.0-p0-rbenv.patch | rbenv install --patch 2.0.0-p0
Downloading yaml-0.1.6.tar.gz...
-> http://dqw8nmjcqpjn7.cloudfront.net/7da6971b4bd08a986dd2a61353bc422362bd0edcc67d7ebaac68c95f74182749
Installing yaml-0.1.6...
Installed yaml-0.1.6 to /home/developer/.rbenv/versions/2.0.0-p0
Downloading ruby-2.0.0-p0.tar.gz...
-> http://dqw8nmjcqpjn7.cloudfront.net/aff85ba5ceb70303cb7fb616f5db8b95ec47a8820116198d1c866cc4fff151ed
Installing ruby-2.0.0-p0...
patching file ext/openssl/ossl_pkey_ec.c
Installed ruby-2.0.0-p0 to /home/developer/.rbenv/versions/2.0.0-p0
=========================================================
=========================================================
Исходники 2.0.0-p0-rbenv.patch
=========================================================
--- ext/openssl/ossl_pkey_ec.c
+++ ext/openssl/ossl_pkey_ec.c
@@ -762,8 +762,10 @@
method = EC_GFp_mont_method();
} else if (id == s_GFp_nist) {
method = EC_GFp_nist_method();
+#if !defined(OPENSSl_NO_EC2M)
} else if (id == s_GF2m_simple) {
method = EC_GF2m_simple_method();
+#endif
}
if (method) {
@@ -817,8 +819,10 @@
if (id == s_GFp) {
new_curve = EC_GROUP_new_curve_GFp;
+#if !defined(OPENSSL_NO_EC2M)
} else if (id == s_GF2m) {
new_curve = EC_GROUP_new_curve_GF2m;
+#endif
} else {
ossl_raise(rb_eArgError, "unknown symbol, must be :GFp or :GF2m");
}
===============================================================
===============================================================
$ rbenv install 2.0.0-p0
$ rbenv global 2.0.0-p0
$ gem install bundler
$ bundle install
$ rbenv rehash
$ bundle exec rake db:create
$ bundle exec rake db:migrate
$ bundle exec rails server