環境: Windowd+Virtualbox+vagrant+Ubuntu
bundle install が上手くできません。
恐らく、nokogiri、pkg-configがうまくインストールできないのだと思います。
Gemfileには、このように指定をしております。
Gemfile
1gem 'nokogiri', '1.10.1' 2gem 'pkg-config', '~> 1.1'
エラーが出た後、libxml2と、libxml2-devをインストールした後、bundle installを再度実行しましたが、同じエラーが出ています。
下記、エラーの内容です。
Fetching nokogiri 1.10.1 Installing nokogiri 1.10.1 with native extensions Gem::Ext::BuildError: ERROR: Failed to build gem native extension. --use-system-libraries checking if the C compiler accepts ... yes Building nokogiri using system libraries. pkg-config could not be used to find libxml-2.0 Please install either `pkg-config` or the pkg-config gem per gem install pkg-config -v "~> 1.1" pkg-config could not be used to find libxslt Please install either `pkg-config` or the pkg-config gem per gem install pkg-config -v "~> 1.1" pkg-config could not be used to find libexslt Please install either `pkg-config` or the pkg-config gem per gem install pkg-config -v "~> 1.1" ERROR: cannot discover where libxml2 is located on your system. please make sure `pkg-config` is installed. *** 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. An error occurred while installing nokogiri (1.10.1), and Bundler cannot continue. Make sure that `gem install nokogiri -v '1.10.1' --source 'https://rubygems.org/'` succeeds before bundling. ```

回答2件
あなたの回答
tips
プレビュー
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。
2019/04/18 03:42
2019/04/18 03:46
2019/04/18 03:47
2019/04/18 03:48
2019/04/19 09:14