简体   繁体   English

在Windows 7上安装Ruby on Rails时出错

[英]Error to install Ruby on Rails on Windows 7

OS: Windows 7 Ultimate 32-bit (6.1, Build 7600) 操作系统:Windows 7 Ultimate 32-bit(6.1,Build 7600)

Installing Ruby: I have installed Ruby version 1.8.7 successfully Installing Rails: I tried to install Rails and all dependencies by typing the following command in command prompt: gem install rails --include-dependencies 安装Ruby:我已经成功安装了Ruby 1.8.7版。安装Rails:我试图通过在命令提示符下键入以下命令来安装Rails和所有依赖项:gem install rails --include-dependencies

But unfortunately, error was occurred as below: 但不幸的是,发生了如下错误:

INFO: gem install -y is now default and will be removed INFO: use --ignore-dependencies to install only the gems you list ERROR: Error installing rails: The 'json' native gem requires installed build tools. 信息: gem install -y现在是默认设置,将被删除信息:使用--ignore-dependencies仅安装您列出的宝石错误:安装rails时出错:'json'本机gem需要安装的构建工具。

Please update your PATH to include build tools or download the DevKit from 'http://rubyinstaller.org/downloads' and follow the instructions at 'http://github.com/oneclick/rubyinstaller/wiki/Development-Kit' 请更新您的PATH以包括构建工具,或从“ http://rubyinstaller.org/downloads”下载DevKit,并按照“ http://github.com/oneclick/rubyinstaller/wiki/Development-Kit”中的说明进行操作

What is the step to fix it? 解决该问题的步骤是什么?

The 'json' native gem requires installed build tools. “ json”原生gem需要安装的构建工具。

Please update your PATH to include build tools or download the DevKit from 'http://rubyinstaller.org/downloads'
and follow the instructions at 'http://github.com/oneclick/rubyinstaller/wiki/Development-Kit'

Seems to indicate what is missing on your environment: build tools, also known as a compiler toolchain. 似乎表明您的环境中缺少什么:构建工具,也称为编译器工具链。

RubyInstaller provides a ready-to-use package called Development Kit (DevKit) which seems to be indicated in the above links. RubyInstaller提供了一个名为Development Kit(DevKit)的即用型软件包,该软件包似乎在上述链接中指出。

Also, the wiki page contains all the instructions to download and install it. 同样,Wiki页面包含所有下载和安装它的说明。

If you want to use Rails, instead of using RubyInstaller, why not install directly RailsInstaller which already integrates the DevKit and there is no extra installation step. 如果你想使用Rails的,而不是使用RubyInstaller,为什么不直接安装RailsInstaller它已经集成了的devkit并没有额外的安装步骤。

Hope that helps. 希望能有所帮助。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM