I can install capybara-webkit on Mac, when I deployed code on Ubuntu, I am facing below error
Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension.
/usr/local/bin/ruby extconf.rb
Gem files will remain installed in /home/datas/.bundler/tmp/7940/gems/capybara-webkit-0.12.1 for inspection.
Results logged to /home/datas/.bundler/tmp/7940/gems/capybara-webkit-0.12.1/./gem_make.out
An error occured while installing capybara-webkit (0.12.1), and Bundler cannot continue.
Make sure that `gem install capybara-webkit -v '0.12.1'` succeeds before bundling.
Even I tried with sudo gem install capybara-webkit -v '0.12.1'
I am getting same error.
Install libqt4-dev and it will fix your problem
sudo apt-get install libqt4-dev
read this one for more information.
Please let me know if you have still problem on this