LoginSignup
1
1

More than 5 years have passed since last update.

capybara-webkit インストール時のトラブルシューティング #01

Posted at

環境

項目 バージョン
OS CentOS 6.5
Ruby ruby 2.1.3p242 (2014-09-19 revision 47630) [x86_64-linux]
Rails 4.1.6

状況

  1. rails new で新規プロジェクトを作成
  2. Gemfile に capybaracapybara-webkit を追加
  3. bundle install を実行
  4. 次のエラーが発生
エラー
[vagrant@vagrant-centos65 foo]$ bundle
Fetching gem metadata from https://rubygems.org/..........
Resolving dependencies...
Using rake 10.4.2
# --- 省略 ---
Installing mini_portile 0.6.1
Installing nokogiri 1.6.5
Installing xpath 2.0.0
Installing capybara 2.4.4

Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

    /home/vagrant/.rbenv/versions/2.1.3/bin/ruby extconf.rb 
Command 'qmake -spec linux-g++ ' not available

Makefile not found

Gem files will remain installed in /home/vagrant/.rbenv/versions/2.1.3/lib/ruby/gems/2.1.0/gems/capybara-webkit-1.3.1 for inspection.
Results logged to /home/vagrant/.rbenv/versions/2.1.3/lib/ruby/gems/2.1.0/extensions/x86_64-linux/2.1.0-static/capybara-webkit-1.3.1/gem_make.out
An error occurred while installing capybara-webkit (1.3.1), and Bundler cannot continue.
Make sure that `gem install capybara-webkit -v '1.3.1'` succeeds before bundling.

対策

$ sudo yum install -y libxml2-devel
$ sudo yum install -y libxslt-devel
1
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
1