首页 > 解决方案 > 使用 RubyGems 安装 Jekyll 时出现问题(Make 中的错误)

问题描述

我正在尝试安装 Jekyll。我有 Ruby 3.0.1p64(2021-04-05 修订版 0fb782ee38)[x64-mingw32] 和 RubyGems 3.2.15。我尝试使用 gem 和 choco 安装 make,并使用 GNU .exe 文件,它总是看起来没问题。

当我执行命令时gem install jekyll,会出现以下错误:

      ERROR: Failed to build gem native extension.

  current directory: C:/tools/ruby30/lib/ruby/gems/3.0.0/gems/http_parser.rb-0.6.0/ext/ruby_http_parser
C:/tools/ruby30/bin/ruby.exe -I C:/tools/ruby30/lib/ruby/3.0.0 -r ./siteconf20210520-2132-gijlna.rb extconf.rb
creating Makefile

current directory: C:/tools/ruby30/lib/ruby/gems/3.0.0/gems/http_parser.rb-0.6.0/ext/ruby_http_parser
make DESTDIR\= clean
C:/tools/ruby30/lib/ruby/gems/3.0.0/gems/make-0.3.1/bin/make:4:in `<top (required)>': undefined local variable or method `make' for main:Object (NameError)
      from C:/tools/ruby30/bin/make:23:in `load'
      from C:/tools/ruby30/bin/make:23:in `<main>'

current directory: C:/tools/ruby30/lib/ruby/gems/3.0.0/gems/http_parser.rb-0.6.0/ext/ruby_http_parser
make DESTDIR\=
C:/tools/ruby30/lib/ruby/gems/3.0.0/gems/make-0.3.1/bin/make:4:in `<top (required)>': undefined local variable or method `make' for main:Object (NameError)
      from C:/tools/ruby30/bin/make:23:in `load'
      from C:/tools/ruby30/bin/make:23:in `<main>'

make failed, exit code 1

Gem files will remain installed in C:/tools/ruby30/lib/ruby/gems/3.0.0/gems/http_parser.rb-0.6.0 for inspection.
Results logged to C:/tools/ruby30/lib/ruby/gems/3.0.0/extensions/x64-mingw32/3.0.0/http_parser.rb-0.6.0/gem_make.out

标签: rubymakefilerubygemsjekyll

解决方案


推荐阅读