###前提・実現したいこと
ここに質問したいことを詳細に書いてください
ruby2.4.0でのrails5.1のインストール
解決できそうなコマンドなどを詳細に記載してもらえると嬉しいです。
###発生している問題・エラーメッセージ
[~] sudo gem install rails 16:13:58 Building native extensions. This could take a while... ERROR: Error installing rails: ERROR: Failed to build gem native extension. current directory: /Users/mikamitaiga/.rbenv/versions/2.4.0/lib/ruby/gems/2.4.0/gems/nokogiri-1.8.0/ext/nokogiri /Users/mikamitaiga/.rbenv/versions/2.4.0/bin/ruby -r ./siteconf20170716-18963-14rqq95.rb extconf.rb checking if the C compiler accepts ... yes checking if the C compiler accepts -Wno-error=unused-command-line-argument-hard-error-in-future... no Building nokogiri using packaged libraries. Using mini_portile version 2.2.0 checking for iconv.h... yes checking for gzdopen() in -lz... yes checking for iconv... no Using pkg-config gem version 1.1.9 checking for libiconv... no ----- libiconv is missing. Please locate mkmf.log to investigate how it is failing. ----- *** extconf.rb failed *** Could not create Makefile due to some reason, probably lack of necessary libraries and/or headers. Check the mkmf.log file for more details. You 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=/Users/mikamitaiga/.rbenv/versions/2.4.0/bin/$(RUBY_BASE_NAME) --help --clean --use-system-libraries --enable-static --disable-static --with-zlib-dir --without-zlib-dir --with-zlib-include --without-zlib-include=${zlib-dir}/include --with-zlib-lib --without-zlib-lib=${zlib-dir}/lib --enable-cross-build --disable-cross-build To see why this extension failed to compile, please check the mkmf.log which can be found here: /Users/mikamitaiga/.rbenv/versions/2.4.0/lib/ruby/gems/2.4.0/extensions/x86_64-darwin-16/2.4.0-static/nokogiri-1.8.0/mkmf.log extconf failed, exit code 1 Gem files will remain installed in /Users/mikamitaiga/.rbenv/versions/2.4.0/lib/ruby/gems/2.4.0/gems/nokogiri-1.8.0 for inspection. Results logged to /Users/mikamitaiga/.rbenv/versions/2.4.0/lib/ruby/gems/2.4.0/extensions/x86_64-darwin-16/2.4.0-static/nokogiri-1.8.0/gem_make.out
###試したこと
前にruby2.3.1の時にはできたのですが、rbenvでrubyのバージョンを2.4.0にするとできなくなってしまいました。
回答1件
あなたの回答
tips
プレビュー
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。
2017/07/17 01:33