使用する、OSはCentOS Linux release 7.3.1611 (Core)、でCapybaraをインストールしようとすると、qmakeが無いと言われる

*** 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:
Command 'qmake ' not available

extconf failed, exit code 1

巷ではなぜか、CentOS7(el7)なのにfedoraのレポジトリのqt48(el6用)を使うように紹介されていることが多いが、調べてみたところ、baseのレポジトリにqt 4.8があるようなのでこちらを使う

sudo yum -y install qt-webkit-devel

 Package                             アーキテクチャー バージョン               リポジトリー   容量
 qtwebkit-devel                      x86_64           2.3.4-6.el7              epel           32 k
 expat-devel                         x86_64           2.1.0-10.el7_3           updates        57 k
 fontconfig-devel                    x86_64           2.10.95-10.el7           base          128 k
 gl-manpages                         noarch           1.1-7.20130122.el7       base          994 k
 libXcursor-devel                    x86_64           1.1.14-2.1.el7           base           23 k
 libXdamage-devel                    x86_64           1.1.4-4.1.el7            base          9.7 k
 libXfixes-devel                     x86_64           5.0.1-2.1.el7            base           13 k
 libXft-devel                        x86_64           2.3.2-2.el7              base           19 k
 libXi-devel                         x86_64           1.7.4-2.el7              base          105 k
 libXinerama-devel                   x86_64           1.1.3-2.1.el7            base           13 k
 libXrandr-devel                     x86_64           1.4.2-2.el7              base           21 k
 libXrender-devel                    x86_64           0.9.8-2.1.el7            base           16 k
 libXv-devel                         x86_64           1.0.10-2.el7             base           40 k
 libXxf86vm-devel                    x86_64           1.1.3-2.1.el7            base           18 k
 libdrm-devel                        x86_64           2.4.67-3.el7             base          114 k
 mesa-libGL-devel                    x86_64           11.2.2-2.20160614.el7    base          149 k
 mesa-libGLU-devel                   x86_64           9.0.0-4.el7              base          9.0 k
 qt-devel                            x86_64           1:4.8.5-13.el7           base           11 M
 qtwebkit                            x86_64           2.3.4-6.el7              epel           10 M


ln -s /usr/bin/qmake-qt4 /usr/bin/qmake


gem install capybara-webkit

 Building native extensions.  This could take a while...
 Successfully installed capybara-webkit-1.14.0
 Parsing documentation for capybara-webkit-1.14.0
 Installing ri documentation for capybara-webkit-1.14.0
 Done installing documentation for capybara-webkit after 0 seconds
 1 gem installed


Sign up for free and join this conversation.
Sign Up
If you already have a Qiita account log in.