简体   繁体   English

Windows 10中的gem安装导轨时出错

[英]Error while gem install rails in Windows 10

Can you explain me what I should do? 您能解释一下我该怎么做吗? I've already done adding source of rubygems.org and gem update --system 我已经完成添加rubygems.org和gem update --system的源代码了

C:\Ruby22>gem install rails
Temporarily enhancing PATH to include DevKit...
Building native extensions.  This could take a while...
C:\Ruby22\devkit\bin\make.exe: *** Couldn't reserve space for cygwin's heap, 
Win32 error 0
C:\Ruby22\devkit\bin\make.exe: *** Couldn't reserve space for cygwin's heap, 
Win32 error 0
ERROR:  Error installing rails:
    ERROR: Failed to build gem native extension.

C:/Ruby22/bin/ruby.exe extconf.rb
creating Makefile

make "DESTDIR=" clean
  0 [main] us 0 init_cheap: VirtualAlloc pointer is null, Win32 error 487
AllocationBase 0x0, BaseAddress 0x60E90000, RegionSize 0x390000, State 0x10000
C:\Ruby22\devkit\bin\make.exe: *** Couldn't reserve space for cygwin's heap, Win32 error 0

make "DESTDIR="
  0 [main] us 0 init_cheap: VirtualAlloc pointer is null, Win32 error 487
AllocationBase 0x0, BaseAddress 0x60E90000, RegionSize 0x390000, State 0x10000
C:\Ruby22\devkit\bin\make.exe: *** Couldn't reserve space for cygwin's heap, Win32 error 0

make failed, exit code 1

Gem files will remain installed in 
C:/Ruby22/lib/ruby/gems/2.2.0/gems/websocket-driver-0.6.5 for inspection.
Results logged to C:/Ruby22/lib/ruby/gems/2.2.0/extensions/x86-mingw32/2.2.0/websocket-driver-0.6.5/gem_make.out

I really want to be free from c9. 我真的很想摆脱c9的束缚。 Locaaall!! Locaaall!

This is not issue with rails or rubygems.org . 这与rails或rubygems.org无关。 It is related to github. 它与github有关。 You are using old version of git. 您正在使用旧版本的git。

Here is solution for this. 这是解决方案。

Also you can look into explanation here . 您也可以在这里进行解释。

Copied solution from link above: 从上面的链接复制的解决方案:

Both current Cygwin and the new version of MSYS - MSYS2 - already have different logic in place, which is hopefully more robust. 当前的Cygwin新版本的MSYS -MSYS2-都已具有不同的逻辑,希望它更健壮。 It's only old versions of Git for Windows which have been still built using the old broken MSYS system. 这只是Git for Windows的旧版本,仍然使用旧的损坏的MSYS系统构建。

Resolution: 解析度:

Install Git for Windows 2 - it is built with the new, properly maintained MSYS2 and also has many new features, plenty of bug fixes and so on. 安装适用于Windows 2的 Git-它是用正确维护的新MSYS2构建的 ,还具有许多新功能,大量错误修复等。 There is also a 64-bit version available which would lower the chance of address space clashes considerably even if this problem was not fixed. 还有一个64位版本,即使此问题未解决,它也可以大大降低地址空间冲突的可能性。 (info) If you're using Embedded Git, you would need to change SourceTree's Git Setting to Use System Git by navigating to Tools>Options>Git(Tab)>Git Version>Use System Git (信息)如果您使用的是嵌入式Git,则需要通过导航到工具>选项> Git(Tab)> Git版本>使用系统Git来更改SourceTree的Git设置以使用系统Git

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

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