Hi, I've some problems with coquelicot installation on my Debian GNU/Linux Wheezy server:
root@server-713:/var/www# git clone https://coquelicot.potager.org/coquelicot.git Cloning into 'coquelicot'... root@server-713:/var/www# cd coquelicot root@server-713:/var/www/coquelicot# git tag -v coquelicot-0.9.2 object 069a8c16bb82b9daebd9918b34c582a9b3d346af type commit tag coquelicot-0.9.2 tagger Lunar lunar@anargeek.net 1365437455 +0200
coquelicot 0.9.2 gpg: Signature made Mon Apr 8 18:10:55 2013 CEST using RSA key ID A8D1112A gpg: Can't check signature: public key not found error: could not verify the tag 'coquelicot-0.9.2' root@server-713:/var/www/coquelicot# git checkout -b production coquelicot-0.9.2 Switched to a new branch 'production' root@server-713:/var/www/coquelicot# less INSTALL root@server-713:/var/www/coquelicot# apt-get install rubygems Reading package lists... Done Building dependency tree Reading state information... Done rubygems is already the newest version. 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. root@server-713:/var/www/coquelicot# less INSTALL root@server-713:/var/www/coquelicot# gem install bundler Successfully installed bundler-1.3.5 1 gem installed Installing ri documentation for bundler-1.3.5... Installing RDoc documentation for bundler-1.3.5... root@server-713:/var/www/coquelicot# bundle install --deployment Fetching gem metadata from https://rubygems.org/......... Fetching gem metadata from https://rubygems.org/.. Installing rake (10.0.3) Installing activesupport (3.0.0) Installing active_support (3.0.0) Installing backports (3.1.0) Installing mime-types (1.17.2) Installing nokogiri (1.5.0) Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension.
/usr/bin/ruby1.9.1 extconf.rb /usr/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in `require': cannot load such file -- mkmf (LoadError) from /usr/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in `require' from extconf.rb:5:in `<main>'
Gem files will remain installed in /srv/www/coquelicot/vendor/bundle/ruby/1.9.1/gems/nokogiri-1.5.0 for inspection. Results logged to /srv/www/coquelicot/vendor/bundle/ruby/1.9.1/gems/nokogiri-1.5.0/ext/nokogiri/gem_make.out An error occurred while installing nokogiri (1.5.0), and Bundler cannot continue. Make sure that `gem install nokogiri -v '1.5.0'` succeeds before bundling. root@server-713:/var/www/coquelicot#
What does this error mean?
PS : Is this mailing-list english or french?
Garreau Alexandre:
Hi, I've some problems with coquelicot installation on my Debian GNU/Linux Wheezy server:
[…] root@server-713:/var/www/coquelicot# gem install bundler Successfully installed bundler-1.3.5 1 gem installed Installing ri documentation for bundler-1.3.5... Installing RDoc documentation for bundler-1.3.5... root@server-713:/var/www/coquelicot# bundle install --deployment Fetching gem metadata from https://rubygems.org/......... Fetching gem metadata from https://rubygems.org/.. Installing rake (10.0.3) Installing activesupport (3.0.0) Installing active_support (3.0.0) Installing backports (3.1.0) Installing mime-types (1.17.2) Installing nokogiri (1.5.0) Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension. […] What does this error mean?
Means that you are missing the parts of Ruby that allows to build native extension. What distribution are you using?
For Debian, the package you are probably missing is called ruby-dev.
Lunar:
Garreau Alexandre:
Hi, I've some problems with coquelicot installation on my Debian GNU/Linux Wheezy server:
[…] root@server-713:/var/www/coquelicot# gem install bundler Successfully installed bundler-1.3.5 1 gem installed Installing ri documentation for bundler-1.3.5... Installing RDoc documentation for bundler-1.3.5... root@server-713:/var/www/coquelicot# bundle install --deployment Fetching gem metadata from https://rubygems.org/......... Fetching gem metadata from https://rubygems.org/.. Installing rake (10.0.3) Installing activesupport (3.0.0) Installing active_support (3.0.0) Installing backports (3.1.0) Installing mime-types (1.17.2) Installing nokogiri (1.5.0) Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension. […] What does this error mean?
Means that you are missing the parts of Ruby that allows to build native extension. What distribution are you using?
For Debian, the package you are probably missing is called ruby-dev.
As I've said, I use Debian GNU/Linux Wheezy on my server. I've installed ruby-dev, but that didn't fixed the problem: same error.
Garreau Alexandre:
As I've said, I use Debian GNU/Linux Wheezy on my server. I've installed ruby-dev, but that didn't fixed the problem: same error.
Buildig nokogiri requires libxml2-dev and libxslt-dev. Installing those two packages should fix the issue. At least it did in a fresh live Wheezy system.
I have updated the INSTALL documentation accordingly, thanks for the report.
Le samedi 06 juillet 2013 à 22:19 +0200, Lunar a écrit :
Garreau Alexandre:
As I've said, I use Debian GNU/Linux Wheezy on my server. I've installed ruby-dev, but that didn't fixed the problem: same error.
Buildig nokogiri requires libxml2-dev and libxslt-dev. Installing those two packages should fix the issue. At least it did in a fresh live Wheezy system.
I have updated the INSTALL documentation accordingly, thanks for the report.
Good :)
But, even installing libxml2-dev and libxslt-dev, it still doesn't work :/
root@server-713:/var/www/coquelicot# bundle install --deployment Fetching gem metadata from https://rubygems.org/......... Fetching gem metadata from https://rubygems.org/.. Installing rake (10.0.3) Installing activesupport (3.0.0) Installing active_support (3.0.0) Installing backports (3.1.0) Installing mime-types (1.17.2) Installing nokogiri (1.5.0) Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension.
/usr/bin/ruby1.9.1 extconf.rb extconf.rb:10: Use RbConfig instead of obsolete and deprecated Config. checking for libxml/parser.h... yes checking for libxslt/xslt.h... yes checking for libexslt/exslt.h... yes checking for iconv_open() in iconv.h... yes checking for xmlParseDoc() in -lxml2... yes checking for xsltParseStylesheetDoc() in -lxslt... yes checking for exsltFuncRegister() in -lexslt... yes checking for xmlHasFeature()... yes checking for xmlFirstElementChild()... yes checking for xmlRelaxNGSetParserStructuredErrors()... yes checking for xmlRelaxNGSetParserStructuredErrors()... yes checking for xmlRelaxNGSetValidStructuredErrors()... yes checking for xmlSchemaSetValidStructuredErrors()... yes checking for xmlSchemaSetParserStructuredErrors()... yes creating Makefile
make compiling html_element_description.c html_element_description.c: In function ‘get_description’: html_element_description.c:249:10: warning: cast discards ‘__attribute__((const))’ qualifier from pointer target type [-Wcast-qual] compiling xml_sax_parser_context.c compiling xml_element_content.c compiling xml_comment.c compiling xml_processing_instruction.c compiling xml_element_decl.c compiling xml_encoding_handler.c compiling xslt_stylesheet.c compiling html_sax_parser_context.c compiling xml_document.c compiling xml_entity_reference.c compiling xml_libxml2_hacks.c compiling xml_schema.c compiling xml_relax_ng.c compiling xml_text.c compiling xml_sax_push_parser.c compiling xml_namespace.c xml_namespace.c: In function ‘prefix’: xml_namespace.c:14:13: warning: variable ‘doc’ set but not used [-Wunused-but-set-variable] xml_namespace.c: In function ‘href’: xml_namespace.c:33:13: warning: variable ‘doc’ set but not used [-Wunused-but-set-variable] compiling html_entity_lookup.c compiling xml_entity_decl.c compiling xml_reader.c compiling xml_document_fragment.c compiling xml_xpath_context.c xml_xpath_context.c: In function ‘xpath_generic_exception_handler’: xml_xpath_context.c:184:3: error: format not a string literal and no format arguments [-Werror=format-security] cc1: some warnings being treated as errors make: *** [xml_xpath_context.o] Erreur 1
Gem files will remain installed in /srv/www/coquelicot/vendor/bundle/ruby/1.9.1/gems/nokogiri-1.5.0 for inspection. Results logged to /srv/www/coquelicot/vendor/bundle/ruby/1.9.1/gems/nokogiri-1.5.0/ext/nokogiri/gem_make.out An error occurred while installing nokogiri (1.5.0), and Bundler cannot continue. Make sure that `gem install nokogiri -v '1.5.0'` succeeds before bundling. root@server-713:/var/www/coquelicot#
Compilation errors…
Garreau Alexandre:
Le samedi 06 juillet 2013 à 22:19 +0200, Lunar a écrit :
Garreau Alexandre:
As I've said, I use Debian GNU/Linux Wheezy on my server. I've installed ruby-dev, but that didn't fixed the problem: same error.
Buildig nokogiri requires libxml2-dev and libxslt-dev. Installing those two packages should fix the issue. At least it did in a fresh live Wheezy system.
I have updated the INSTALL documentation accordingly, thanks for the report.
Good :)
But, even installing libxml2-dev and libxslt-dev, it still doesn't work :/ […] xml_xpath_context.c:184:3: error: format not a string literal and no format arguments [-Werror=format-security] cc1: some warnings being treated as errors make: *** [xml_xpath_context.o] Erreur 1
I am sorry but I can't reproduce this. IIRC, this issue has been fixed in a more recent release of nokogiri.
I'll take care of updating the bundle before the next release, but it probably won't happen before at least a few weeks.
In the meantime, feel free to experiment with updating the bundle yourself.
Le lundi 08 juillet 2013 à 22:29 +0200, Lunar a écrit :
I am sorry but I can't reproduce this. IIRC, this issue has been fixed in a more recent release of nokogiri.
I'll take care of updating the bundle before the next release, but it probably won't happen before at least a few weeks.
In the meantime, feel free to experiment with updating the bundle yourself.
Ok, I solved the issue: it was a dependencies problem, just hack into Gemfile.lock solved the problem, here’s the patch:
--- coquelicot-orig/Gemfile.lock 2013-08-31 22:07:22.413193420 +0200 +++ coquelicot/Gemfile.lock 2013-08-30 00:52:04.483311888 +0200 @@ -50,10 +50,12 @@ maruku (0.6.1) syntax (>= 1.0.0) mime-types (1.17.2) + mini_portile (0.5.1) moneta (0.7.14) multi_json (1.0.4) multipart-parser (0.1.1) - nokogiri (1.5.0) + nokogiri (1.6.0) + mini_portile rack (1.4.1) rack-protection (1.4.0) rack