2011-06-20 9 views
0

私は呼び出すことはできません。Rubyのインストールに問題がありますか?

bundle installまたはWindows 7 SP1上

bundle update。私はDevKitがインストールされ、働いていても次のエラーが出ます!

bundle update Fetching source index for http://rubygems.org/ Using addressable (2.2.6) Using daemons (1.1.4) Installing hiredis (0.3.2) with native extensions C:/Ruby192/lib/ruby/site_ruby/ 1.9.1/rubygems/installer.rb:551:in `rescue in block in build_extensions': ERROR: Failed to build gem native extension. (Gem::Installer::ExtensionBuildError)

C:/Ruby192/bin/ruby.exe extconf.rb gcc -std=c99 -pedantic -c 

-O3 -fPIC -Wall -W -Wstrict-prototypes -Wwrite-strings -g -ggdb net.c net.c:1:0: warning: -fPIC ignored for target (all code is position independent) net.c:35:24: fatal error: sys/socket.h: No such file or directory compilation terminated. make: * [net.o] Error 1 creating Makefile

make C:/Ruby192/bin/ruby -e "puts 'EXPORTS', 'Init_hiredis_ext'" > hiredis_ext-i386- mingw32.def gcc -I. -IC:/Ruby192/include/ruby-1.9.1/i386-mingw32 -I/C/Ruby192/include/ruby-1 .9.1/ruby/backward -I/C/Ruby192/include/ruby-1.9.1 -I. -O3 -g -Wextra -Wno-unu sed-parameter -Wno-parentheses -Wpointer-arith -Wwrite-strings -Wno-missing-fiel d-initializers -Wno-long-long -IC:/Ruby192/lib/ruby/gems/1.9.1/gems/hiredis-0.3. 2/vendor/hiredis -o connection.o -c connection.c connection.c:1:24: fatal error: sys/socket.h: No such file or directory compilation terminated. make: * [connection.o] Error 1

Gem files will remain installed in C:/Ruby192/lib/ruby/gems/1.9.1/gems/hiredis-0 .3.2 for inspection. Results logged to C:/Ruby192/lib/ruby/gems/1.9.1/gems/hiredis-0.3.2/ext/hiredis_ ext/gem_make.out from C:/Ruby192/lib/ruby/site_ruby/1.9.1/rubygems/installer.rb:529:in b lock in build_extensions' from C:/Ruby192/lib/ruby/site_ruby/1.9.1/rubygems/installer.rb:504:in e ach' from C:/Ruby192/lib/ruby/site_ruby/1.9.1/rubygems/installer.rb:504:in b uild_extensions' from C:/Ruby192/lib/ruby/site_ruby/1.9.1/rubygems/installer.rb:180:in i nstall' from C:/Ruby192/lib/ruby/gems/1.9.1/gems/bundler-1.0.15/lib/bundler/sour ce.rb:101:in block in install' from C:/Ruby192/lib/ruby/gems/1.9.1/gems/bundler-1.0.15/lib/bundler/ruby gems_integration.rb:78:in preserve_paths' from C:/Ruby192/lib/ruby/gems/1.9.1/gems/bundler-1.0.15/lib/bundler/sour ce.rb:91:in install' from C:/Ruby192/lib/ruby/gems/1.9.1/gems/bundler-1.0.15/lib/bundler/inst aller.rb:58:in block (2 levels) in run' from C:/Ruby192/lib/ruby/gems/1.9.1/gems/bundler-1.0.15/lib/bundler/ruby gems_integration.rb:93:in with_build_args' from C:/Ruby192/lib/ruby/gems/1.9.1/gems/bundler-1.0.15/lib/bundler/inst aller.rb:57:in block in run' from C:/Ruby192/lib/ruby/gems/1.9.1/gems/bundler-1.0.15/lib/bundler/spec _set.rb:12:in block in each' from C:/Ruby192/lib/ruby/gems/1.9.1/gems/bundler-1.0.15/lib/bundler/spec _set.rb:12:in each' from C:/Ruby192/lib/ruby/gems/1.9.1/gems/bundler-1.0.15/lib/bundler/spec _set.rb:12:in each' from C:/Ruby192/lib/ruby/gems/1.9.1/gems/bundler-1.0.15/lib/bundler/inst aller.rb:49:in run' from C:/Ruby192/lib/ruby/gems/1.9.1/gems/bundler-1.0.15/lib/bundler/inst aller.rb:8:in install' from C:/Ruby192/lib/ruby/gems/1.9.1/gems/bundler-1.0.15/lib/bundler/cli. rb:270:in update' from C:/Ruby192/lib/ruby/gems/1.9.1/gems/bundler-1.0.15/lib/bundler/vend or/thor/task.rb:22:in run' from C:/Ruby192/lib/ruby/gems/1.9.1/gems/bundler-1.0.15/lib/bundler/vend or/thor/invocation.rb:118:in invoke_task' from C:/Ruby192/lib/ruby/gems/1.9.1/gems/bundler-1.0.15/lib/bundler/vend or/thor.rb:246:in dispatch' from C:/Ruby192/lib/ruby/gems/1.9.1/gems/bundler-1.0.15/lib/bundler/vend or/thor/base.rb:389:in start' from C:/Ruby192/lib/ruby/gems/1.9.1/gems/bundler-1.0.15/bin/bundle:13:in <top (required)>' from C:/Ruby192/bin/bundle:19:in load' from C:/Ruby192/bin/bundle:19:in `'

+0

Github(https://github.com/pietern/hiredis-rb/issues/1)に関する同様のレポートがありますが、これはおそらく少し役に立ちます。 – mliebelt

答えて

1

あなたがインストールしようとしている宝石ではなく、これはバンドラーの問題ですか?

このような条件に対する非常に簡単なセット、とのGemfileを作成します。

source: rubygems 
gem 'rake' 

と何が起こるかを見るために、この上bundle installを実行します。

また、レール環境を稼働させようとしている場合は、http://railsinstaller.orgを使用する必要があります。これはあなたの人生をはるかに簡単にします。

+0

ええ、問題は宝石です。私はUbuntuに戻る予定です。ありがとう – glarkou

+0

ubuntuに戻って良いコール。 :) –

関連する問題