I ran into some trouble with whimsy secmail after branching a local repository.

tl;dr Nokogiri has trouble on MacOSX. It needs special treatment that we might 
want to document for MacOSX users.

Following the instructions:

    14  15:01   git clone https://github.com/apache/whimsy.git --branch secmail
worked fine
    19  15:02   cd whimsy/www/secmail/
worked fine
    21  15:02   rake fetch1
failed
    22  15:02   rake server
failed
clr% sudo gem install bundler
worked 
clr% rake fetch1
failed
Installing nokogiri 1.6.7 with native extensions

Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native 
extension.

    /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/bin/ruby 
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.
Using mini_portile version 2.0.0
checking for iconv.h... yes
checking for gzdopen() in -lz... yes
checking for iconv... no
-----
libiconv 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.

Looked on the internet and found a solution.
clr% sudo gem install nokogiri -v '1.6.7'
failed:
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 
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.
Using mini_portile version 2.0.0
checking for iconv.h... yes
checking for gzdopen() in -lz... yes
checking for iconv... no
-----
libiconv 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.

Tried another solution from the internet
clr% sudo gem install nokogiri -v '1.6.7' -- --use-system-libraries
Building native extensions with: '--use-system-libraries'
This could take a while...
Successfully installed nokogiri-1.6.7
Parsing documentation for nokogiri-1.6.7
unable to convert "\xCA" from ASCII-8BIT to UTF-8 for 
lib/nokogiri/nokogiri.bundle, skipping
Installing ri documentation for nokogiri-1.6.7
1 gem installed
clr% rake fetch1
receiving file list ... done
201512

sent 42 bytes  received 59740694 bytes  1783305.55 bytes/sec
total size is 59733277  speedup is 1.00
officers-secretary/201512

More trouble when I came back to it and Nokogiri needed an update.
clr% rake server
Using mail 2.6.3
Installing nokogiri 1.6.7.1 (was 1.6.7) with native extensions

Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native 
extension.
clr% sudo gem install nokogiri -v '1.6.7.1'
failed
clr% sudo gem install nokogiri -v '1.6.7.1' -- --use-system-libraries
worked

So, is there something to be learned here?

Craig




Craig L Russell
Architect, Oracle
http://db.apache.org/jdo
408 276-5638 mailto:[email protected]
P.S. A good JDO? O, Gasp!

Reply via email to