Sunday 15 January 2012

ruby - Post OS X 10.10 Yosemite install Rails error -



ruby - Post OS X 10.10 Yosemite install Rails error -

i did clean install of mac os yosemite, rails won't work properly.

when seek rails s tells me bundle install.

i message after trying run bundle install:

errno::eacces: permission denied - /users/giowong/rails_project/doctible_pre_treatment/vendor/bundle/ruby/2.0.0/gems/bcrypt-3.1.7/.gitignore

i did

sudo gem update --system

and

bundle install

when this, i'm getting nasty stuff:

gem::ext::builderror: error: failed build gem native extension. /system/library/frameworks/ruby.framework/versions/2.0/usr/bin/ruby -r ./siteconf20141107-39214-1ds3j4x.rb extconf.rb checking ruby/util.h... *** extconf.rb failed *** not create makefile due reason, lack of necessary libraries and/or headers. check mkmf.log file more details. may need configuration options. provided configuration options: --with-opt-dir --without-opt-dir --with-opt-include --without-opt-include=${opt-dir}/include --with-opt-lib --without-opt-lib=${opt-dir}/lib --with-make-prog --without-make-prog --srcdir=. --curdir --ruby=/system/library/frameworks/ruby.framework/versions/2.0/usr/bin/ruby /system/library/frameworks/ruby.framework/versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:434:in `try_do': compiler failed generate executable file. (runtimeerror) have install development tools first. /system/library/frameworks/ruby.framework/versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:549:in `block in try_compile' /system/library/frameworks/ruby.framework/versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:502:in `with_werror' /system/library/frameworks/ruby.framework/versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:549:in `try_compile' /system/library/frameworks/ruby.framework/versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:1044:in `block in have_header' /system/library/frameworks/ruby.framework/versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:895:in `block in checking_for' /system/library/frameworks/ruby.framework/versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:340:in `block (2 levels) in postpone' /system/library/frameworks/ruby.framework/versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:310:in `open' /system/library/frameworks/ruby.framework/versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:340:in `block in postpone' /system/library/frameworks/ruby.framework/versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:310:in `open' /system/library/frameworks/ruby.framework/versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:336:in `postpone' /system/library/frameworks/ruby.framework/versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:894:in `checking_for' /system/library/frameworks/ruby.framework/versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:1043:in `have_header' extconf.rb:14:in `<main>' extconf failed, exit code 1 gem files remain installed in /users/giowong/rails_project/doctible_pre_treatment/vendor/bundle/ruby/2.0.0/gems/bcrypt-3.1.7 inspection. results logged /users/giowong/rails_project/doctible_pre_treatment/vendor/bundle/ruby/2.0.0/extensions/universal-darwin-14/2.0.0/bcrypt-3.1.7/gem_make.out error occurred while installing bcrypt (3.1.7), , bundler cannot continue. create sure `gem install bcrypt -v '3.1.7'` succeeds before bundling.

i've tried installing using

\curl -ssl https://get.rvm.io | bash -s stable --rails

but no luck.

i don't recommend using default ruby provided os x, install rvm instead. need install xcode command line tools:

xcode-select --install # click install, not xcode

then verify if gcc installed:

gcc --version

and run:

\curl -ssl https://get.rvm.io | bash -s stable --rails

ruby-on-rails ruby rvm

No comments:

Post a Comment