Skip to content

Instantly share code, notes, and snippets.

@shu0115
Created February 25, 2013 06:19
Show Gist options
  • Save shu0115/5028094 to your computer and use it in GitHub Desktop.
Save shu0115/5028094 to your computer and use it in GitHub Desktop.
Ruby 2.0.0-p0インストール(Mac OS X 10.8.2) ref: http://qiita.com/items/a24d1c8a1539f858137b
brew uninstall openssl
brew uninstall curl-ca-bundle
brew uninstall readline
brew update
rbenv global 2.0.0-p0
ruby -v
----------
ruby 2.0.0p0 (2013-02-24 revision 39474) [x86_64-darwin12.2.1]
----------
rbenv versions
----------
system
1.9.3-p327
1.9.3-p385
1.9.3-p392
* 2.0.0-p0 (set by /Users/shu/.rbenv/version)
----------
rbenv version
----------
2.0.0-p0 (set by /Users/shu/.rbenv/version)
----------
gem i bundler -v 1.3.0.pre
----------
Fetching: bundler-1.3.0.pre.gem (100%)
Successfully installed bundler-1.3.0.pre
Done installing documentation for bundler (0 sec).
1 gem installed
----------
gem list bundler
----------
*** LOCAL GEMS ***
bundler (1.3.0.pre)
----------
gem i bundler
----------
ERROR: Your gem push credentials file located at:
/Users/shu/.gem/credentials
has file permissions of 0644 but 0600 is required.
You should reset your credentials at:
https://rubygems.org/profile/edit
if you believe they were disclosed to a third party.
----------
chmod 600 /Users/shu/.gem/credentials
rbenv rehash
source 'https://rubygems.org'
ruby "2.0.0"
cd RAILS_ROOT
bundle install
brew upgrade ruby-build
bundle install
----------
Unfortunately, a fatal error has occurred. Please see the Bundler
troubleshooting documentation at http://bit.ly/bundler-issues. Thanks!
/Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/2.0.0/net/http.rb:917:in `connect': SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed (OpenSSL::SSL::SSLError)
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/2.0.0/net/http.rb:917:in `block in connect'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/2.0.0/timeout.rb:51:in `timeout'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/2.0.0/net/http.rb:917:in `connect'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/2.0.0/net/http.rb:861:in `do_start'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/2.0.0/net/http.rb:856:in `start'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/bundler-1.3.0.pre.8/lib/bundler/vendor/net/http/persistent.rb:628:in `start'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/bundler-1.3.0.pre.8/lib/bundler/vendor/net/http/persistent.rb:570:in `connection_for'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/bundler-1.3.0.pre.8/lib/bundler/vendor/net/http/persistent.rb:930:in `request'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/bundler-1.3.0.pre.8/lib/bundler/fetcher.rb:169:in `fetch'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/bundler-1.3.0.pre.8/lib/bundler/fetcher.rb:151:in `use_api'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/bundler-1.3.0.pre.8/lib/bundler/source/rubygems.rb:223:in `block in remote_specs'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/bundler-1.3.0.pre.8/lib/bundler/source/rubygems.rb:223:in `select'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/bundler-1.3.0.pre.8/lib/bundler/source/rubygems.rb:223:in `remote_specs'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/bundler-1.3.0.pre.8/lib/bundler/source/rubygems.rb:162:in `fetch_specs'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/bundler-1.3.0.pre.8/lib/bundler/source/rubygems.rb:66:in `specs'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/bundler-1.3.0.pre.8/lib/bundler/lazy_specification.rb:52:in `__materialize__'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/bundler-1.3.0.pre.8/lib/bundler/spec_set.rb:86:in `block in materialize'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/bundler-1.3.0.pre.8/lib/bundler/spec_set.rb:83:in `map!'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/bundler-1.3.0.pre.8/lib/bundler/spec_set.rb:83:in `materialize'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/bundler-1.3.0.pre.8/lib/bundler/definition.rb:114:in `specs'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/bundler-1.3.0.pre.8/lib/bundler/definition.rb:109:in `resolve_remotely!'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/bundler-1.3.0.pre.8/lib/bundler/installer.rb:83:in `run'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/bundler-1.3.0.pre.8/lib/bundler/installer.rb:14:in `install'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/bundler-1.3.0.pre.8/lib/bundler/cli.rb:247:in `install'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/bundler-1.3.0.pre.8/lib/bundler/vendor/thor/task.rb:27:in `run'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/bundler-1.3.0.pre.8/lib/bundler/vendor/thor/invocation.rb:120:in `invoke_task'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/bundler-1.3.0.pre.8/lib/bundler/vendor/thor.rb:344:in `dispatch'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/bundler-1.3.0.pre.8/lib/bundler/vendor/thor/base.rb:434:in `start'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/bundler-1.3.0.pre.8/bin/bundle:20:in `block in <top (required)>'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/bundler-1.3.0.pre.8/lib/bundler/friendly_errors.rb:4:in `with_friendly_errors'
from /Users/shu/.rbenv/versions/2.0.0-p0/lib/ruby/gems/2.0.0/gems/bundler-1.3.0.pre.8/bin/bundle:20:in `<top (required)>'
from /Users/shu/.rbenv/versions/2.0.0-p0/bin/bundle:23:in `load'
from /Users/shu/.rbenv/versions/2.0.0-p0/bin/bundle:23:in `<main>'
----------
rbenv install -l
----------
2.0.0-p0
----------
brew install openssl
----------
==> Downloading http://openssl.org/source/openssl-1.0.1e.tar.gz
Already downloaded: /Library/Caches/Homebrew/openssl-1.0.1e.tar.gz
==> perl ./Configure --prefix=/usr/local/Cellar/openssl/1.0.1e --openssldir=/usr/local/etc/openssl zlib-dynamic shared d
==> make
==> make test
==> make install MANDIR=/usr/local/Cellar/openssl/1.0.1e/share/man MANSUFFIX=ssl
==> Caveats
To install updated CA certs from Mozilla.org:
brew install curl-ca-bundle
This formula is keg-only: so it was not symlinked into /usr/local.
Mac OS X already provides this software and installing another version in
parallel can cause all kinds of trouble.
The OpenSSL provided by OS X is too old for some software.
Generally there are no consequences of this for you. If you build your
own software and it requires this formula, you'll need to add to your
build variables:
LDFLAGS: -L/usr/local/opt/openssl/lib
CPPFLAGS: -I/usr/local/opt/openssl/include
==> Summary
 /usr/local/Cellar/openssl/1.0.1e: 429 files, 15M, built in 3.7 minutes
----------
brew install curl-ca-bundle
----------
==> Downloading https://downloads.sourceforge.net/project/machomebrew/mirror/curl-ca-bundle-1.87.tar.bz2
Already downloaded: /Library/Caches/Homebrew/curl-ca-bundle-1.87.tar.bz2
 /usr/local/Cellar/curl-ca-bundle/1.87: 2 files, 252K, built in 2 seconds
----------
cp /usr/local/Cellar/curl-ca-bundle/1.87/share/ca-bundle.crt /usr/local/etc/openssl/cert.pem
brew install readline
----------
==> Downloading http://ftpmirror.gnu.org/readline/readline-6.2.tar.gz
Already downloaded: /Library/Caches/Homebrew/readline-6.2.4.tar.gz
==> Patching
patching file callback.c
patching file input.c
patching file patchlevel
patching file support/shobj-conf
patching file vi_mode.c
==> ./configure --prefix=/usr/local/Cellar/readline/6.2.4 --mandir=/usr/local/Cellar/readline/6.2.4/share/man --infodir=
==> make install
==> Caveats
This formula is keg-only: so it was not symlinked into /usr/local.
OS X provides the BSD libedit library, which shadows libreadline.
In order to prevent conflicts when programs look for libreadline we are
defaulting this GNU Readline installation to keg-only.
Generally there are no consequences of this for you. If you build your
own software and it requires this formula, you'll need to add to your
build variables:
LDFLAGS: -L/usr/local/opt/readline/lib
CPPFLAGS: -I/usr/local/opt/readline/include
==> Summary
 /usr/local/Cellar/readline/6.2.4: 31 files, 1.6M, built in 17 seconds
----------
brew upgrade readline
rbenv install 2.0.0-p0
----------
Downloading openssl-1.0.1e.tar.gz...
-> https://www.openssl.org/source/openssl-1.0.1e.tar.gz
Installing openssl-1.0.1e...
Installed openssl-1.0.1e to /Users/shu/.rbenv/versions/2.0.0-p0
Downloading ruby-2.0.0-p0.tar.gz...
-> http://ftp.ruby-lang.org/pub/ruby/2.0/ruby-2.0.0-p0.tar.gz
Installing ruby-2.0.0-p0...
Installed ruby-2.0.0-p0 to /Users/shu/.rbenv/versions/2.0.0-p0
----------
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment