Im trying to install vagrant-hostmanager and suddenly this error appears and i have no clue why.
Would be nice if someone can help me!
im using Vagrant 1.6.5 and this is the errormessage:
Bundler, the underlying system Vagrant uses to install plugins,
reported an error. The error is shown below. These errors are usually
caused by misconfigured plugin installations or transient network
issues. The error from Bundler is:
An error occurred while installing nokogiri (1.6.6.2), and Bundler cannot continue.
Make sure that `gem install nokogiri -v '1.6.6.2'` succeeds before bundling.
Gem::Ext::BuildError: ERROR: Failed to build gem native extension.
/usr/bin/ruby2.1 extconf.rb
checking if the C compiler accepts ... yes
Building nokogiri using packaged libraries.
checking for gzdopen() in -lz... no
zlib is missing; necessary for building libxml2
*** 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=/usr/bin/ruby2.1
--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
extconf failed, exit code 1
Gem files will remain installed in /home/eike/.vagrant.d/gems/gems/nokogiri-1.6.6.2 for inspection.
Results logged to /home/eike/.vagrant.d/gems/extensions/x86_64-linux/2.1.0/nokogiri-1.6.6.2/gem_make.out
would be nice if someone can help me :-)
it complains about a missing native library zlib
on ubuntu, you can install with sudo apt-get install zlib and you should be fine to reinstall the plugin
Related
Problem with install of twilio-ruby. I have installed libxml2 using homebrew and confirmed it is there. However when I try running
gem install twilio-ruby
I recieve an error that it cannot find libxml2. I have tried specifying the path to libxml2 but still can't get it to install. Any suggestions?
I have tried the following
gem install twilio-ruby -- --with-xml2-dir=/usr/local/Cellar/libxml2
gem install twilio-ruby -- --use-system-libraries
Then all of these three together:
gem install twilio-ruby -- --with-xml2-dir=/usr/local/Cellar/libxml2/2.9.1 --with-xml2-lib=/usr/local/Cellar/libxml2/2.9.1/lib --with-xml2-include=/usr/local/Cellar/libxml2/2.9.1/include
Each time I get output similar to the below.
gem install twilio-ruby -- --with-xml2-dir=/usr/local/Cellar/libxml2
Building native extensions with: '--with-xml2-dir=/usr/local/Cellar/libxml2'
This could take a while...
ERROR: Error installing twilio-ruby:
ERROR: Failed to build gem native extension.
/Users/tom/.rvm/rubies/ruby-2.1.1/bin/ruby extconf.rb --with-xml2-dir=/usr/local/Cellar/libxml2
checking for libxml/xmlversion.h in /opt/include/libxml2,/opt/local/include/libxml2,/usr/local/include/libxml2,/usr/include/libxml2... no
*** 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/tom/.rvm/rubies/ruby-2.1.1/bin/ruby
--with-xml2-config
--without-xml2-config
--with-xml2-dir
--with-xml2-include
--without-xml2-include=${xml2-dir}/include
--with-xml2-lib
--without-xml2-lib=${xml2-dir}/lib
extconf failure: need libxml2.
Install the library or try one of the following options to extconf.rb:
--with-xml2-config=/path/to/xml2-config
--with-xml2-dir=/path/to/libxml2
--with-xml2-lib=/path/to/libxml2/lib
--with-xml2-include=/path/to/libxml2/include
extconf failed, exit code 1
Gem files will remain installed in /Users/tom/.rvm/gems/ruby-2.1.1#carecoach/gems/libxml-ruby-3.0.0 for inspection.
Results logged to /Users/tom/.rvm/gems/ruby-2.1.1#carecoach/extensions/x86_64-darwin-12/2.1.0-static/libxml-ruby-3.0.0/gem_make.out
'
So after much pain and frustration, and trying a bunch of stuff the solution was the following:
gem update --system
xcode-select --install # Then agree to the terms, even if you have done this before!
I've been trying to install the Capybara-Webkit gem with bundler and after following these instructions: https://github.com/thoughtbot/capybara-webkit/wiki/Installing-Qt-and-compiling-capybara-webkit#macos-sierra-1012
I keep running into the error of the Makefile not being found. I've updated Homebrew, the gem system, and updated Xcode 8 with cli tools to no avail. Would really appreciate any help!
sudo gem install capybara-webkit PATH=/Users/caren/Qt5.5.1/5.5/clang_64/bin:$PATH gem install capybara-webkit
Password:
Building native extensions. This could take a while...
ERROR: Error installing capybara-webkit:
ERROR: Failed to build gem native extension.
/Users/caren/.rbenv/versions/2.2.3/bin/ruby -r ./siteconf20161108-5610-m00680.rb extconf.rb
*** 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/caren/.rbenv/versions/2.2.3/bin/$(RUBY_BASE_NAME)
--with-gl-dir
--without-gl-dir
--with-gl-include
--without-gl-include=${gl-dir}/include
--with-gl-lib
--without-gl-lib=${gl-dir}/lib
--with-zlib-dir
--without-zlib-dir
--with-zlib-include
--without-zlib-include=${zlib-dir}/include
--with-zlib-lib
--without-zlib-lib=${zlib-dir}/lib
Command 'qmake ' not available
extconf failed, exit code 1
Gem files will remain installed in /Users/caren/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/capybara-webkit-1.11.1 for inspection.
Results logged to /Users/caren/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/extensions/x86_64-darwin-15/2.2.0-static/capybara-webkit-1.11.1/gem_make.out
ERROR: Could not find a valid gem 'PATH=/Users/caren/Qt5.5.1/5.5/clang_64/bin:/Library/Frameworks/Python.framework/Versions/3.5/bin:/Users/caren/.nvm/versions/node/v5.4.0/bin:/Users/caren/.rbenv/shims:/usr/local/opt/coreutils/libexec/gnubin:/usr/local/heroku/bin:/usr/local/bin:/usr/local/sbin:/usr/local/share/npm/bin:/Users/caren/.rbenv/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin' (>= 0) in any repository
ERROR: Could not find a valid gem 'gem' (>= 0) in any repository
ERROR: Could not find a valid gem 'install' (>= 0) in any repository
ERROR: Possible alternatives: installr, instant, instana, instacli, instapi
Building native extensions. This could take a while...
ERROR: Error installing capybara-webkit:
ERROR: Failed to build gem native extension.
/Users/caren/.rbenv/versions/2.2.3/bin/ruby -r ./siteconf20161108-5610-97n2eh.rb extconf.rb
*** 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/caren/.rbenv/versions/2.2.3/bin/$(RUBY_BASE_NAME)
--with-gl-dir
--without-gl-dir
--with-gl-include
--without-gl-include=${gl-dir}/include
--with-gl-lib
--without-gl-lib=${gl-dir}/lib
--with-zlib-dir
--without-zlib-dir
--with-zlib-include
--without-zlib-include=${zlib-dir}/include
--with-zlib-lib
--without-zlib-lib=${zlib-dir}/lib
Command 'qmake ' not available
extconf failed, exit code 1
Gem files will remain installed in /Users/caren/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/gems/capybara-webkit-1.11.1 for inspection.
Results logged to /Users/caren/.rbenv/versions/2.2.3/lib/ruby/gems/2.2.0/extensions/x86_64-darwin-15/2.2.0-static/capybara-webkit-1.11.1/gem_make.out
The following did the trick for me (using Homebrew):
brew install qt5 --with-qtwebkit
brew link --force qt5
gem install capybara-webkit
Note: It will take a while to install the first step, and you'll need to have Xcode installed.
I hope it will help someone.
brew install qt5 --with-qtwebkit
brew install qt#5.5 or brew reinstall qt#5.5
echo ‘export PATH=“/usr/local/opt/qt#5.5/bin:$PATH”’ >> ~/.bash_profile
source ~/.bash_profile
brew unlink qt#5.5 && brew link --force qt#5.5
I'm having some trouble installing a Ruby Gem called Lingust for my Mac. I get the error message below and have no idea how to solve the issue. Any help would be greatly appreciated.
gem install github-linguist
Building native extensions. This could take a while...
ERROR: Error installing github-linguist:
ERROR: Failed to build gem native extension.
/Users/kanery/.rvm/rubies/ruby-2.0.0-p643/bin/ruby -r./siteconf20151008-9054-b4exbs.rb extconf.rb
checking for gmake... no
checking for make... yes
checking for cmake... no
ERROR: CMake is required to build Rugged.
*** 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/kanery/.rvm/rubies/ruby-2.0.0-p643/bin/ruby
--use-system-libraries
extconf failed, exit code 1
Gem files will remain installed in /Users/kanery/.rvm/gems/ruby-2.0.0-p643/gems/rugged-0.24.0b0 for inspection.
Reading the installation instructions of Rugged, you can see that both CMake and pkg-config are required. Looking at your error message, it seems like CMake is not installed on your system.
If you are using Homebrew, you can install it by running
brew install cmake
Or you can install it from the source following these instructions.
I have:
Mac OS X Yosemite 10.10.3
MacPorts (not Brew)
Ruby 2 in system (not RVM)
I want to install Nokogiri and tried:
port install nokogiri
and got:
Building native extensions. This could take a while... ERROR: Error
installing nokogiri: ERROR: Failed to build gem native extension.
/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/bin/ruby -r
./siteconf20150323-30174-1mqhl4i.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. checking for gzdopen() in
-lz... yes checking for iconv... yes
************************************************************************ IMPORTANT NOTICE:
Building Nokogiri with a packaged version of libxml2-2.9.2 with the
following patches applied:
- 0001-Revert-Missing-initialization-for-the-catalog-module.patch
- 0002-Fix-missing-entities-after-CVE-2014-3660-fix.patch
Team Nokogiri will keep on doing their best to provide security
updates in a timely manner, but if this is a concern for you and want
to use the system library instead; abort this installation process and
reinstall nokogiri as follows:
gem install nokogiri -- --use-system-libraries
[--with-xml2-config=/path/to/xml2-config]
[--with-xslt-config=/path/to/xslt-config]
If you are using Bundler, tell it to use the option:
bundle config build.nokogiri --use-system-libraries
bundle install
Note, however, that nokogiri is not fully compatible with arbitrary
versions of libxml2 provided by OS/package vendors.
************************************************************************ Extracting libxml2-2.9.2.tar.gz into
tmp/x86_64-apple-darwin14/ports/libxml2/2.9.2... OK Running patch with
/Library/Ruby/Gems/2.0.0/gems/nokogiri-1.6.6.2/ports/patches/libxml2/0001-Revert-Missing-initialization-for-the-catalog-module.patch...
Running 'patch' for libxml2 2.9.2... OK Running patch with
/Library/Ruby/Gems/2.0.0/gems/nokogiri-1.6.6.2/ports/patches/libxml2/0002-Fix-missing-entities-after-CVE-2014-3660-fix.patch...
Running 'patch' for libxml2 2.9.2... OK Running 'configure' for
libxml2 2.9.2... OK Running 'compile' for libxml2 2.9.2... ERROR,
review
'/Library/Ruby/Gems/2.0.0/gems/nokogiri-1.6.6.2/ext/nokogiri/tmp/x86_64-apple-darwin14/ports/libxml2/2.9.2/compile.log'
to see what happened.
*** 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=/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/bin/ruby
--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
/Library/Ruby/Gems/2.0.0/gems/mini_portile-0.6.2/lib/mini_portile.rb:279:in
`block in execute': Failed to complete compile task (RuntimeError)
from
/Library/Ruby/Gems/2.0.0/gems/mini_portile-0.6.2/lib/mini_portile.rb:271:in
`chdir' from
/Library/Ruby/Gems/2.0.0/gems/mini_portile-0.6.2/lib/mini_portile.rb:271:in
`execute' from
/Library/Ruby/Gems/2.0.0/gems/mini_portile-0.6.2/lib/mini_portile.rb:70:in
`compile' from
/Library/Ruby/Gems/2.0.0/gems/mini_portile-0.6.2/lib/mini_portile.rb:110:in
`cook' from extconf.rb:278:in `block in process_recipe' from
extconf.rb:177:in `tap' from extconf.rb:177:in `process_recipe' from
extconf.rb:475:in `<main>'
extconf failed, exit code 1
Gem files will remain installed in
/Library/Ruby/Gems/2.0.0/gems/nokogiri-1.6.6.2 for inspection. Results
logged to
/Library/Ruby/Gems/2.0.0/extensions/universal-darwin-14/2.0.0/nokogiri-1.6.6.2/gem_make.out
I tried:
gem install nokogiri -- --use-system-libraries
and got:
Building native extensions with: '--use-system-libraries' This could
take a while... ERROR: Error installing nokogiri: ERROR: Failed to
build gem native extension.
/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/bin/ruby -r
./siteconf20150323-34882-16v74a8.rb extconf.rb --use-system-libraries
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 system libraries. checking for xmlParseDoc()
in libxml/parser.h... no checking for xmlParseDoc() in -lxml2... no
checking for xmlParseDoc() in -llibxml2... no
----- libxml2 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=/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/bin/ruby
--help --clean --use-system-libraries --with-zlib-dir
--without-zlib-dir --with-zlib-include
--without-zlib-include=${zlib-dir}/include --with-zlib-lib
--without-zlib-lib=${zlib-dir}/lib --with-xml2-dir
--without-xml2-dir --with-xml2-include
--without-xml2-include=${xml2-dir}/include --with-xml2-lib
--without-xml2-lib=${xml2-dir}/lib --with-libxml-2.0-config
--without-libxml-2.0-config --with-pkg-config --without-pkg-config
--with-xslt-dir --without-xslt-dir --with-xslt-include
--without-xslt-include=${xslt-dir}/include --with-xslt-lib
--without-xslt-lib=${xslt-dir}/lib --with-libxslt-config
--without-libxslt-config --with-exslt-dir --without-exslt-dir
--with-exslt-include --without-exslt-include=${exslt-dir}/include
--with-exslt-lib --without-exslt-lib=${exslt-dir}/lib
--with-libexslt-config --without-libexslt-config --with-xml2lib
--without-xml2lib --with-libxml2lib --without-libxml2lib
extconf failed, exit code 1
Gem files will remain installed in
/Library/Ruby/Gems/2.0.0/gems/nokogiri-1.6.6.2 for inspection. Results
logged to
/Library/Ruby/Gems/2.0.0/extensions/universal-darwin-14/2.0.0/nokogiri-1.6.6.2/gem_make.out
I tried:
port install libxml2
and got:
---> Computing dependencies for libxml2
---> Cleaning libxml2
---> Scanning binaries for linking errors
---> No broken files found.
What else I can do to install Nokogiri?
Because MacPorts (and other similar package managers) install packages in non-standard locations, it cannot automatically determine the path to libxml2. The warning in your first attempt provided information on how to resolve this:
gem install nokogiri -- --use-system-libraries
[--with-xml2-config=/path/to/xml2-config]
[--with-xslt-config=/path/to/xslt-config]
You said that you tried gem install nokogiri -- --use-system-libraries. The Nokogiri documentation suggests that you need to add either of the following two options:
--with-xml2-config - Path to the xml2-config binary (try which xml2-config)
--with-xml2-dir - Path to the libxml2 base installation directory
If you’ve got libxml2 and/or libxslt installed in a nonstandard place
(read as “not /opt/local, /usr/local, /usr or the standard Ruby
directories”), you can use command-line parameters to the gem install
command to grease the wheels.
gem install nokogiri -- \
--use-system-libraries \
--with-xml2-dir=/path/to/dir \
--with-xslt-dir=/path/to/dir
This page gives appropriate commands for various package managers, including MacPorts:
gem install nokogiri -- \
--with-xml2-include=/opt/local/include/libxml2 \
--with-xml2-lib=/opt/local/lib \
--with-xslt-dir=/opt/local
Check to see if Xcode is installed on your machine then run xcode-select --install in the terminal. This should do the trick and allow you to run sudo gem install rails
Getting the below error after trying to install therubyracer gem.
Not sure why it's complaining about v8 when i have the gem downloaded already.
I had original troubles installing libv8 but then manage to install with --system-v8 flags, but now its rubyracer complaining.
Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension.
/home/glenn/.rvm/rubies/ruby-1.9.3-p392/bin/ruby extconf.rb
checking for main() in -lpthread... yes
checking for v8.h... no
*** 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=/home/glenn/.rvm/rubies/ruby-1.9.3-p392/bin/ruby
--with-pthreadlib
--without-pthreadlib
--enable-debug
--disable-debug
--with-v8-dir
--without-v8-dir
--with-v8-include
--without-v8-include=${v8-dir}/include
--with-v8-lib
--without-v8-lib=${v8-dir}/
/home/glenn/.rvm/gems/ruby-1.9.3-p392/gems/libv8-3.11.8.17/ext/libv8/location.rb:50:in `configure': You have chosen to use the version of V8 found on your system (Libv8::Location::System::NotFoundError)
and *not* the one that is bundle with the libv8 rubygem. However,
it could not be located. please make sure you have a version of
v8 that is compatible with 3.11.8.17 installed. You may
need to special --with-v8-dir options if it is in a non-standard
location
thanks,
The Mgmt
from /home/glenn/.rvm/gems/ruby-1.9.3-p392/gems/libv8-3.11.8.17/lib/libv8.rb:7:in `configure_makefile'
from extconf.rb:32:in `<main>'
Gem files will remain installed in /home/glenn/.rvm/gems/ruby-1.9.3-p392/gems/therubyracer-0.11.4 for inspection.
Results logged to /home/glenn/.rvm/gems/ruby-1.9.3-p392/gems/therubyracer-0.11.4/ext/v8/gem_make.out
I assume that you're using a Linux distribution on your Chromebook (either directly or via chroot). Is this correct?
It's looking for v8.h, so you'll need to install the v8 development package as well: it's libv8-dev on Debian/Ubuntu (and something -devel on RedHat and similar).