Ruby gemのgoogle_driveをインストールする際に下記のようなエラーが出てしまいます。
Winodws内にCygwinを入れてRubyを実行しています。
(WindowsにCygwinをを通さず直接、google_driveをインストールすることはできました)
Cygwinが問題ではないような、nokogiriに関係してそうな感じがしているのですが、
原因が分かっていません。
(Cygwinにnokogiri-1.10.10が入ってます)
アドバイスいただけますと幸いです。
ruby
1$ gem install google_drive 2Building native extensions. This could take a while... 3ERROR: Error installing google_drive: 4 ERROR: Failed to build gem native extension. 5 6 current directory: /home/1/.rbenv/versions/2.7.1/lib/ruby/gems/2.7.0/gems/nokogiri-1.10.10/ext/nokogiri 7/home/1/.rbenv/versions/2.7.1/bin/ruby.exe -I /home/1/.rbenv/versions/2.7.1/lib/ruby/2.7.0 -r ./siteconf20200912-2067-zu07l7.rb extconf.rb 8checking if the C compiler accepts ... yes 9Building nokogiri using packaged libraries. 10Using mini_portile version 2.4.0 11checking for gzdopen() in -lz... yes 12checking for iconv... yes 13************************************************************************ 14IMPORTANT NOTICE: 15 16Building Nokogiri with a packaged version of libxml2-2.9.10 17with the following patches applied: 18 - 0001-Revert-Do-not-URI-escape-in-server-side-includes.patch 19 - 0002-Remove-script-macro-support.patch 20 - 0003-Update-entities-to-remove-handling-of-ssi.patch 21 - 0004-libxml2.la-is-in-top_builddir.patch 22 - 0005-Fix-infinite-loop-in-xmlStringLenDecodeEntities.patch 23 24Team Nokogiri will keep on doing their best to provide security 25updates in a timely manner, but if this is a concern for you and want 26to use the system library instead; abort this installation process and 27reinstall nokogiri as follows: 28 29 gem install nokogiri -- --use-system-libraries 30 [--with-xml2-config=/path/to/xml2-config] 31 [--with-xslt-config=/path/to/xslt-config] 32 33If you are using Bundler, tell it to use the option: 34 35 bundle config build.nokogiri --use-system-libraries 36 bundle install 37 38Note, however, that nokogiri is not fully compatible with arbitrary 39versions of libxml2 provided by OS/package vendors. 40************************************************************************ 41Extracting libxml2-2.9.10.tar.gz into tmp/x86_64-pc-cygwin/ports/libxml2/2.9.10... OK 42Running git apply with /home/1/.rbenv/versions/2.7.1/lib/ruby/gems/2.7.0/gems/nokogiri-1.10.10/patches/libxml2/0001-Revert-Do-not-URI-escape-in-server-side-includes.patch... OK 43Running git apply with /home/1/.rbenv/versions/2.7.1/lib/ruby/gems/2.7.0/gems/nokogiri-1.10.10/patches/libxml2/0002-Remove-script-macro-support.patch... OK 44Running git apply with /home/1/.rbenv/versions/2.7.1/lib/ruby/gems/2.7.0/gems/nokogiri-1.10.10/patches/libxml2/0003-Update-entities-to-remove-handling-of-ssi.patch... OK 45Running git apply with /home/1/.rbenv/versions/2.7.1/lib/ruby/gems/2.7.0/gems/nokogiri-1.10.10/patches/libxml2/0004-libxml2.la-is-in-top_builddir.patch... OK 46Running git apply with /home/1/.rbenv/versions/2.7.1/lib/ruby/gems/2.7.0/gems/nokogiri-1.10.10/patches/libxml2/0005-Fix-infinite-loop-in-xmlStringLenDecodeEntities.patch... OK 47Running 'configure' for libxml2 2.9.10... OK 48Running 'compile' for libxml2 2.9.10... OK 49Running 'install' for libxml2 2.9.10... OK 50Activating libxml2 2.9.10 (from /home/1/.rbenv/versions/2.7.1/lib/ruby/gems/2.7.0/gems/nokogiri-1.10.10/ports/x86_64-pc-cygwin/libxml2/2.9.10)... 51************************************************************************ 52IMPORTANT NOTICE: 53 54Building Nokogiri with a packaged version of libxslt-1.1.34. 55 56Team Nokogiri will keep on doing their best to provide security 57updates in a timely manner, but if this is a concern for you and want 58to use the system library instead; abort this installation process and 59reinstall nokogiri as follows: 60 61 gem install nokogiri -- --use-system-libraries 62 [--with-xml2-config=/path/to/xml2-config] 63 [--with-xslt-config=/path/to/xslt-config] 64 65If you are using Bundler, tell it to use the option: 66 67 bundle config build.nokogiri --use-system-libraries 68 bundle install 69************************************************************************ 70Extracting libxslt-1.1.34.tar.gz into tmp/x86_64-pc-cygwin/ports/libxslt/1.1.34... OK 71Running 'configure' for libxslt 1.1.34... OK 72Running 'compile' for libxslt 1.1.34... ERROR, review '/home/1/.rbenv/versions/2.7.1/lib/ruby/gems/2.7.0/gems/nokogiri-1.10.10/ext/nokogiri/tmp/x86_64-pc-cygwin/ports/libxslt/1.1.34/compile.log' to see what happened. Last lines are: 73======================================================================== 74/usr/lib/gcc/x86_64-pc-cygwin/9.3.0/../../../../x86_64-pc-cygwin/bin/ld: ../libexslt/.libs/libexslt.a(date.o):date.c:(.text+0x738f): undefined reference to `__imp_xsltGenericDebug' 75/usr/lib/gcc/x86_64-pc-cygwin/9.3.0/../../../../x86_64-pc-cygwin/bin/ld: ../libexslt/.libs/libexslt.a(date.o):date.c:(.text+0x7399): undefined reference to `__imp_xsltGenericDebugContext' 76/usr/lib/gcc/x86_64-pc-cygwin/9.3.0/../../../../x86_64-pc-cygwin/bin/ld: ../libexslt/.libs/libexslt.a(date.o):date.c:(.text+0x74d5): undefined reference to `__imp_xsltGenericDebug' 77/usr/lib/gcc/x86_64-pc-cygwin/9.3.0/../../../../x86_64-pc-cygwin/bin/ld: ../libexslt/.libs/libexslt.a(date.o):date.c:(.text+0x74df): undefined reference to `__imp_xsltGenericDebugContext' 78/usr/lib/gcc/x86_64-pc-cygwin/9.3.0/../../../../x86_64-pc-cygwin/bin/ld: ../libexslt/.libs/libexslt.a(saxon.o):saxon.c:(.text+0x613): undefined reference to `__imp_xsltGenericError' 79/usr/lib/gcc/x86_64-pc-cygwin/9.3.0/../../../../x86_64-pc-cygwin/bin/ld: ../libexslt/.libs/libexslt.a(saxon.o):saxon.c:(.text+0x61d): undefined reference to `__imp_xsltGenericErrorContext' 80/usr/lib/gcc/x86_64-pc-cygwin/9.3.0/../../../../x86_64-pc-cygwin/bin/ld: ../libexslt/.libs/libexslt.a(dynamic.o):dynamic.c:(.text+0x4f): undefined reference to `__imp_xsltGenericError' 81/usr/lib/gcc/x86_64-pc-cygwin/9.3.0/../../../../x86_64-pc-cygwin/bin/ld: ../libexslt/.libs/libexslt.a(dynamic.o):dynamic.c:(.text+0x59): undefined reference to `__imp_xsltGenericErrorContext' 82 83collect2: error: ld returned 1 exit status 84make[2]: *** [Makefile:484: xsltproc.exe] エラー 1 85make[2]: ディレクトリ '/home/1/.rbenv/versions/2.7.1/lib/ruby/gems/2.7.0/gems/nokogiri-1.10.10/ext/nokogiri/tmp/x86_64-pc-cygwin/ports/libxslt/1.1.34/libxslt-1.1.34/xsltproc' から出ます 86make[1]: *** [Makefile:615: all-recursive] エラー 1 87make[1]: ディレクトリ '/home/1/.rbenv/versions/2.7.1/lib/ruby/gems/2.7.0/gems/nokogiri-1.10.10/ext/nokogiri/tmp/x86_64-pc-cygwin/ports/libxslt/1.1.34/libxslt-1.1.34' から出ます 88make: *** [Makefile:441: all] エラー 2 89======================================================================== 90*** extconf.rb failed *** 91Could not create Makefile due to some reason, probably lack of necessary 92libraries and/or headers. Check the mkmf.log file for more details. You may 93need configuration options. 94 95Provided configuration options: 96 --with-opt-dir 97 --without-opt-dir 98 --with-opt-include 99 --without-opt-include=${opt-dir}/include 100 --with-opt-lib 101 --without-opt-lib=${opt-dir}/lib 102 --with-make-prog 103 --without-make-prog 104 --srcdir=. 105 --curdir 106 --ruby=/home/1/.rbenv/versions/2.7.1/bin/$(RUBY_BASE_NAME) 107 --help 108 --clean 109 --use-system-libraries 110 --enable-static 111 --disable-static 112 --with-zlib-dir 113 --without-zlib-dir 114 --with-zlib-include 115 --without-zlib-include=${zlib-dir}/include 116 --with-zlib-lib 117 --without-zlib-lib=${zlib-dir}/lib 118 --enable-cross-build 119 --disable-cross-build 120/home/1/.rbenv/versions/2.7.1/lib/ruby/gems/2.7.0/gems/mini_portile2-2.4.0/lib/mini_portile2/mini_portile.rb:402:in `block in execute': Failed to complete compile task (RuntimeError) 121 from /home/1/.rbenv/versions/2.7.1/lib/ruby/gems/2.7.0/gems/mini_portile2-2.4.0/lib/mini_portile2/mini_portile.rb:373:in `chdir' 122 from /home/1/.rbenv/versions/2.7.1/lib/ruby/gems/2.7.0/gems/mini_portile2-2.4.0/lib/mini_portile2/mini_portile.rb:373:in `execute' 123 from /home/1/.rbenv/versions/2.7.1/lib/ruby/gems/2.7.0/gems/mini_portile2-2.4.0/lib/mini_portile2/mini_portile.rb:115:in `compile' 124 from /home/1/.rbenv/versions/2.7.1/lib/ruby/gems/2.7.0/gems/mini_portile2-2.4.0/lib/mini_portile2/mini_portile.rb:154:in `cook' 125 from extconf.rb:365:in `block (2 levels) in process_recipe' 126 from extconf.rb:257:in `block in chdir_for_build' 127 from extconf.rb:256:in `chdir' 128 from extconf.rb:256:in `chdir_for_build' 129 from extconf.rb:364:in `block in process_recipe' 130 from extconf.rb:262:in `tap' 131 from extconf.rb:262:in `process_recipe' 132 from extconf.rb:574:in `<main>' 133 134To see why this extension failed to compile, please check the mkmf.log which can be found here: 135 136 /home/1/.rbenv/versions/2.7.1/lib/ruby/gems/2.7.0/extensions/x86_64-cygwin/2.7.0/nokogiri-1.10.10/mkmf.log 137 138extconf failed, exit code 1 139 140Gem files will remain installed in /home/1/.rbenv/versions/2.7.1/lib/ruby/gems/2.7.0/gems/nokogiri-1.10.10 for inspection. 141Results logged to /home/1/.rbenv/versions/2.7.1/lib/ruby/gems/2.7.0/extensions/x86_64-cygwin/2.7.0/nokogiri-1.10.10/gem_make.out 142
回答2件
あなたの回答
tips
プレビュー