*** extconf.rb failed *** Could not create Makefile due to some reason

896 views
Skip to first unread message

Arkadiusz Zdanowski

unread,
Aug 31, 2016, 10:40:41 PM8/31/16
to nokogiri-talk
Running Ubuntu 16.04 
I am unable to install nokogiri.
Help please!


Installing nokogiri 1.6.8 with native extensions

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

    current directory: /home/arqpc/Desktop/Apki Rails/NaGitHubie/rspec-getting-started/.bundle/ruby/2.3.0/gems/nokogiri-1.6.8/ext/nokogiri
/home/arqpc/.rbenv/versions/2.3.1/bin/ruby -r ./siteconf20160831-21188-1ovnr6y.rb extconf.rb
Using pkg-config version 1.1.7
checking if the C compiler accepts ... yes
Building nokogiri using packaged libraries.
Using mini_portile version 2.1.0
checking for gzdopen() in -lz... yes
checking for iconv... yes
************************************************************************
IMPORTANT NOTICE:

Building Nokogiri with a packaged version of libxml2-2.9.4.

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.4.tar.gz into tmp/x86_64-pc-linux-gnu/ports/libxml2/2.9.4... OK
Running 'configure' for libxml2 2.9.4... OK
Running 'compile' for libxml2 2.9.4... OK
Running 'install' for libxml2 2.9.4... ERROR, review '/home/arqpc/Desktop/Apki Rails/NaGitHubie/rspec-getting-started/.bundle/ruby/2.3.0/gems/nokogiri-1.6.8/ext/nokogiri/tmp/x86_64-pc-linux-gnu/ports/libxml2/2.9.4/install.log' to see what happened. Last lines are:
========================================================================
make[3]: Leaving directory '/home/arqpc/Desktop/Apki Rails/NaGitHubie/rspec-getting-started/.bundle/ruby/2.3.0/gems/nokogiri-1.6.8/ext/nokogiri/tmp/x86_64-pc-linux-gnu/ports/libxml2/2.9.4/libxml2-2.9.4/include'
make[2]: Leaving directory '/home/arqpc/Desktop/Apki Rails/NaGitHubie/rspec-getting-started/.bundle/ruby/2.3.0/gems/nokogiri-1.6.8/ext/nokogiri/tmp/x86_64-pc-linux-gnu/ports/libxml2/2.9.4/libxml2-2.9.4/include'
Making install in .
make[2]: Entering directory '/home/arqpc/Desktop/Apki Rails/NaGitHubie/rspec-getting-started/.bundle/ruby/2.3.0/gems/nokogiri-1.6.8/ext/nokogiri/tmp/x86_64-pc-linux-gnu/ports/libxml2/2.9.4/libxml2-2.9.4'
make[3]: Entering directory '/home/arqpc/Desktop/Apki Rails/NaGitHubie/rspec-getting-started/.bundle/ruby/2.3.0/gems/nokogiri-1.6.8/ext/nokogiri/tmp/x86_64-pc-linux-gnu/ports/libxml2/2.9.4/libxml2-2.9.4'
 /bin/mkdir -p '/home/arqpc/Desktop/Apki Rails/NaGitHubie/rspec-getting-started/.bundle/ruby/2.3.0/gems/nokogiri-1.6.8/ports/x86_64-pc-linux-gnu/libxml2/2.9.4/lib'
 /bin/bash ./libtool   --mode=install /usr/bin/install -c   libxml2.la '/home/arqpc/Desktop/Apki Rails/NaGitHubie/rspec-getting-started/.bundle/ruby/2.3.0/gems/nokogiri-1.6.8/ports/x86_64-pc-linux-gnu/libxml2/2.9.4/lib'
libtool: install: /usr/bin/install -c .libs/libxml2.lai /home/arqpc/Desktop/Apki Rails/NaGitHubie/rspec-getting-started/.bundle/ruby/2.3.0/gems/nokogiri-1.6.8/ports/x86_64-pc-linux-gnu/libxml2/2.9.4/lib/libxml2.la
/usr/bin/install: target 'Rails/NaGitHubie/rspec-getting-started/.bundle/ruby/2.3.0/gems/nokogiri-1.6.8/ports/x86_64-pc-linux-gnu/libxml2/2.9.4/lib/libxml2.la' is not a directory
Makefile:923: recipe for target 'install-libLTLIBRARIES' failed
make[3]: *** [install-libLTLIBRARIES] Error 1
make[3]: Leaving directory '/home/arqpc/Desktop/Apki Rails/NaGitHubie/rspec-getting-started/.bundle/ruby/2.3.0/gems/nokogiri-1.6.8/ext/nokogiri/tmp/x86_64-pc-linux-gnu/ports/libxml2/2.9.4/libxml2-2.9.4'
Makefile:1749: recipe for target 'install-am' failed
make[2]: *** [install-am] Error 2
make[2]: Leaving directory '/home/arqpc/Desktop/Apki Rails/NaGitHubie/rspec-getting-started/.bundle/ruby/2.3.0/gems/nokogiri-1.6.8/ext/nokogiri/tmp/x86_64-pc-linux-gnu/ports/libxml2/2.9.4/libxml2-2.9.4'
Makefile:1440: recipe for target 'install-recursive' failed
make[1]: *** [install-recursive] Error 1
make[1]: Leaving directory '/home/arqpc/Desktop/Apki Rails/NaGitHubie/rspec-getting-started/.bundle/ruby/2.3.0/gems/nokogiri-1.6.8/ext/nokogiri/tmp/x86_64-pc-linux-gnu/ports/libxml2/2.9.4/libxml2-2.9.4'
Makefile:1743: recipe for target 'install' failed
make: *** [install] Error 2
========================================================================
*** 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/arqpc/.rbenv/versions/2.3.1/bin/$(RUBY_BASE_NAME)
--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
/home/arqpc/Desktop/Apki Rails/NaGitHubie/rspec-getting-started/.bundle/ruby/2.3.0/gems/mini_portile2-2.1.0/lib/mini_portile2/mini_portile.rb:366:in `block in execute': Failed to complete install task (RuntimeError)
from /home/arqpc/Desktop/Apki Rails/NaGitHubie/rspec-getting-started/.bundle/ruby/2.3.0/gems/mini_portile2-2.1.0/lib/mini_portile2/mini_portile.rb:337:in `chdir'
from /home/arqpc/Desktop/Apki Rails/NaGitHubie/rspec-getting-started/.bundle/ruby/2.3.0/gems/mini_portile2-2.1.0/lib/mini_portile2/mini_portile.rb:337:in `execute'
from /home/arqpc/Desktop/Apki Rails/NaGitHubie/rspec-getting-started/.bundle/ruby/2.3.0/gems/mini_portile2-2.1.0/lib/mini_portile2/mini_portile.rb:116:in `install'
from /home/arqpc/Desktop/Apki Rails/NaGitHubie/rspec-getting-started/.bundle/ruby/2.3.0/gems/mini_portile2-2.1.0/lib/mini_portile2/mini_portile.rb:151:in `cook'
from extconf.rb:364:in `block (2 levels) in process_recipe'
from extconf.rb:257:in `block in chdir_for_build'
from extconf.rb:256:in `chdir'
from extconf.rb:256:in `chdir_for_build'
from extconf.rb:363:in `block in process_recipe'
from extconf.rb:262:in `tap'
from extconf.rb:262:in `process_recipe'
from extconf.rb:555:in `<main>'

To see why this extension failed to compile, please check the mkmf.log which can be found here:

  /home/arqpc/Desktop/Apki Rails/NaGitHubie/rspec-getting-started/.bundle/ruby/2.3.0/extensions/x86_64-linux/2.3.0-static/nokogiri-1.6.8/mkmf.log

extconf failed, exit code 1

Gem files will remain installed in /home/arqpc/Desktop/Apki Rails/NaGitHubie/rspec-getting-started/.bundle/ruby/2.3.0/gems/nokogiri-1.6.8 for inspection.
Results logged to /home/arqpc/Desktop/Apki Rails/NaGitHubie/rspec-getting-started/.bundle/ruby/2.3.0/extensions/x86_64-linux/2.3.0-static/nokogiri-1.6.8/gem_make.out
Using rack-test 0.6.3
Using mime-types 3.1
Using binding_of_caller 0.7.2
Using coffee-script 2.4.1
Using uglifier 3.0.2
Using sprockets 3.7.0
Using rspec-core 3.5.2
Using rspec-expectations 3.5.0
Using rspec-mocks 3.5.0
Using turbolinks 5.0.1
Using sdoc 0.4.1
Using activesupport 4.2.6
An error occurred while installing nokogiri (1.6.8), and Bundler cannot
continue.
Make sure that `gem install nokogiri -v '1.6.8'` succeeds before bundling.







Lars Kanis

unread,
Sep 1, 2016, 12:50:16 AM9/1/16
to nokogi...@googlegroups.com

Please use a path without spaces. The libxml2 installation process doesn't work with spaces in the path.

Reply all
Reply to author
Forward
0 new messages