curbを使いたいのですが、gem install curbをやっても上手くインストールすることができません。
下のサイトを参考に次のコードを試してみましたがエラーがでてしまいました。
Ruby
1gem install curb --version 0.7.18 --platform=ruby -- -- --with-curl-lib="C:/Ruby25-x64/bin" - 2-with-curl-include="C:/Ruby25-x64/includes"
libcurl.dllとcurl.exeは/Ruby25-x64/binの直下に置いてあります。
どうしたら上手くインストールできるでしょうか?
ruby
1▼▼▼エラーメッセージ▼▼▼ 2Temporarily enhancing PATH for MSYS/MINGW... 3Building native extensions with: '-- --with-curl-lib=C:/Ruby25-x64/bin --with-curl-include=C:/Ruby25-x64/includes' 4This could take a while... 5ERROR: Error installing curb: 6 ERROR: Failed to build gem native extension. 7 8 current directory: C:/Ruby25-x64/lib/ruby/gems/2.5.0/gems/curb-0.7.18/ext 9C:/Ruby25-x64/bin/ruby.exe -r ./siteconf20190416-3216-1oii1yc.rb extconf.rb -- --with-curl-lib=C:/Ruby25-x64/bin --with-c 10url-include=C:/Ruby25-x64/includes 11checking for curl-config... no 12checking for -lcurl... yes 13checking for curl/curl.h... no 14*** extconf.rb failed *** 15Could not create Makefile due to some reason, probably lack of necessary 16libraries and/or headers. Check the mkmf.log file for more details. You may 17need configuration options. 18 19Provided configuration options: 20 --with-opt-dir 21 --without-opt-dir 22 --with-opt-include 23 --without-opt-include=${opt-dir}/include 24 --with-opt-lib 25 --without-opt-lib=${opt-dir}/lib 26 --with-make-prog 27 --without-make-prog 28 --srcdir=. 29 --curdir 30 --ruby=C:/Ruby25-x64/bin/$(RUBY_BASE_NAME) 31 --with-curl-dir 32 --without-curl-dir 33 --with-curl-include=${curl-dir}/include 34 --with-curl-lib=${curl-dir}/lib 35 --with-curllib 36 --without-curllib 37extconf.rb:18:in `<main>': Can't find libcurl or curl/curl.h (RuntimeError) 38 39 Try passing --with-curl-dir or --with-curl-lib and --with-curl-include 40 options to extconf. 41 42To see why this extension failed to compile, please check the mkmf.log which can be found here: 43To see why this extension failed to compile, please check the mkmf.log which 44extconf.rb:18:in `<main>': Can't find libcurl or curl/curl.h (Runtim 45eEr 46ror) 47 48 Try passing --with-curl-dir or --with-curl-lib and --with-curl-inclu 49de 50extconf.rb:18:in `<main>': Can't find libcurl or curl/curl.h (Runt 51im 52eError) 53 54 Try passing --with-curl-dir or --with-curl-lib and --with-curl-inc 55lu 56extconf.rb:18:in `<main>': Can't find libcurl or curl/curl.h (RuntimeError) 57 58 Try passing --with-curl-dir or --with-curl-lib and --with-curl-include 59 options to extconf. 60 61To see why this extension failed to compile, please check the mkmf.log which can be found here: 62 63 C:/Ruby25-x64/lib/ruby/gems/2.5.0/extensions/x64-mingw32/2.5.0/curb-0.7.18/mkmf.log 64 65extconf failed, exit code 1 66 67Gem files will remain installed in C:/Ruby25-x64/lib/ruby/gems/2.5.0/gems/curb-0.7.18 for inspection. 68Results logged to C:/Ruby25-x64/lib/ruby/gems/2.5.0/extensions/x64-mingw32/2.5.0/curb-0.7.18/gem_make.out 69
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。