配置Ruby安装时出错



我一直在StackOverflow中寻找答案,但是在三天的失败之后,我放弃了安装Ruby。

当前已安装:

  1. Ruby(股票)
  2. RVM
  3. Ruby安装程序从http://railsinstaller.org/

在配置过程中出现错误。我已经尝试过从SMF切换到Homebrew,但这并不好。

下面是我得到的错误:

Error running 'env LDFLAGS=-L/opt/sm/pkg/active/lib CFLAGS=-I/opt/sm/pkg/active/include CPATH=/opt/sm/pkg/active/include ./configure --prefix=/Users/Unwired/.rvm/rubies/ruby-1.9.3-p392 --with-opt-dir=/usr/local/opt/libyaml:/usr/local/opt/readline:/usr/local/opt/libxml2:/usr/local/opt/libxslt:/usr/local/opt/libksba:/usr/local/opt/openssl:/usr/local/opt/sqlite --disable-install-doc --without-tcl --without-tk --enable-shared',
please read /Users/Unwired/.rvm/log/ruby-1.9.3-p392/1366883126_configure.log
There has been an error while running configure. Halting the installation.

我真的很高兴开始学习RoR,但是安装它是一个痛苦的过程。

按以下步骤操作:

  1. 从http://rubyinstaller.org/downloads/下载Rails安装程序和DevKit。
  2. 安装Ruby。
  3. 创建目录并在C:上提取DevKit,即C:DevKit
  4. 将Devkit的路径复制到Environment Variables > PathC:DevKitbin;
  5. 打开cmd并输入以下内容:
ruby dk.rb <>之前ruby dk。rb initruby dk。rb安装之前
  1. 打开另一个cmd,输入gem install rails
  2. 安装MySQL: gem install mysql .

注意:确保将Ruby的路径复制到Environment Variables > Path。这里有一个关于在rails上安装Ruby的选择

您使用Linux环境吗?如果是,请按照"here"中的说明操作。

最新更新