Project

General

Profile

Actions

Bug #12071

closed

Gem installation fails with 2.3.0 on Cygwin

Added by Panyamin (Benjamin Gueroult) almost 9 years ago. Updated over 5 years ago.

Status:
Closed
Assignee:
-
Target version:
-
ruby -v:
ruby 2.3.0p0 (2015-12-25 revision 53290) [x86_64-cygwin]
[ruby-core:73806]

Description

Hello,

I would like report an issue when installing gem on Cygwin with ruby 2.3.0.

Backtrace is:

/home/USER/.rbenv/versions/2.3.0/lib/ruby/site_ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require': cannot load such file -- win32/resolv (LoadError)
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/site_ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/2.3.0/resolv.rb:971:in `default_config_hash'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/2.3.0/resolv.rb:989:in `block in lazy_initialize'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/2.3.0/resolv.rb:982:in `synchronize'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/2.3.0/resolv.rb:982:in `lazy_initialize'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/2.3.0/resolv.rb:360:in `block in lazy_initialize'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/2.3.0/resolv.rb:358:in `synchronize'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/2.3.0/resolv.rb:358:in `lazy_initialize'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/2.3.0/resolv.rb:518:in `fetch_resource'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/2.3.0/resolv.rb:512:in `each_resource'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/2.3.0/resolv.rb:493:in `getresource'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/site_ruby/2.3.0/rubygems/remote_fetcher.rb:99:in `api_endpoint'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/site_ruby/2.3.0/rubygems/source.rb:47:in `api_uri'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/site_ruby/2.3.0/rubygems/source.rb:183:in `load_specs'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/site_ruby/2.3.0/rubygems/spec_fetcher.rb:263:in `tuples_for'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/site_ruby/2.3.0/rubygems/spec_fetcher.rb:238:in `block in available_specs'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/site_ruby/2.3.0/rubygems/source_list.rb:98:in `each'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/site_ruby/2.3.0/rubygems/source_list.rb:98:in `each_source'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/site_ruby/2.3.0/rubygems/spec_fetcher.rb:223:in `available_specs'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/site_ruby/2.3.0/rubygems/spec_fetcher.rb:103:in `search_for_dependency'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/site_ruby/2.3.0/rubygems/commands/update_command.rb:118:in `fetch_remote_gems'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/site_ruby/2.3.0/rubygems/commands/update_command.rb:140:in `highest_remote_version'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/site_ruby/2.3.0/rubygems/commands/update_command.rb:268:in `block in which_to_update'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/site_ruby/2.3.0/rubygems/commands/update_command.rb:264:in `each'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/site_ruby/2.3.0/rubygems/commands/update_command.rb:264:in `which_to_update'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/site_ruby/2.3.0/rubygems/commands/update_command.rb:97:in `execute'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/site_ruby/2.3.0/rubygems/command.rb:308:in `invoke_with_build_args'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/site_ruby/2.3.0/rubygems/command_manager.rb:169:in `process_args'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/site_ruby/2.3.0/rubygems/command_manager.rb:139:in `run'
        from /home/USER/.rbenv/versions/2.3.0/lib/ruby/site_ruby/2.3.0/rubygems/gem_runner.rb:55:in `run'
        from /home/USER/.rbenv/versions/2.3.0/bin/gem:21:in `<main>'

I fixed the issue with the attached patch, but I'm not sure if this is the correct way...


Files

cygwin.patch (789 Bytes) cygwin.patch Fix issue with w32/resolv on cygwin Panyamin (Benjamin Gueroult), 02/14/2016 01:29 PM
fiddle.mkmf.log (15.3 KB) fiddle.mkmf.log Panyamin (Benjamin Gueroult), 02/15/2016 09:15 PM
config.log (990 KB) config.log Panyamin (Benjamin Gueroult), 02/18/2016 10:43 PM
ruby-build.20160218233708.3584.log (108 KB) ruby-build.20160218233708.3584.log Panyamin (Benjamin Gueroult), 02/18/2016 10:54 PM

Updated by nobu (Nobuyoshi Nakada) almost 9 years ago

  • Status changed from Open to Feedback

Since Cygwin does not have its own resolv.conf file, it is not correct.
How did you install ruby, and did fiddle get installed successfully?
Please show mkmf.log files under ext/fiddle and ext/win32.

Updated by Panyamin (Benjamin Gueroult) almost 9 years ago

Nobuyoshi Nakada wrote:

How did you install ruby, and did fiddle get installed successfully?

I installed with rbenv, and I'm pretty sure that it doesn't work with the "common way". I can test if you want?

Please show mkmf.log files under ext/fiddle and ext/win32.

You'll find fiddle mkmf.log attached.
I found nothing in win32. Which meaning compilator didn't even entered in it..?

Thanks !

Updated by nobu (Nobuyoshi Nakada) almost 9 years ago

Does fiddle get installed and work?
win32 requires it.

Updated by Panyamin (Benjamin Gueroult) almost 9 years ago

Nobuyoshi Nakada wrote:

Does fiddle get installed and work?
win32 requires it.

Well, I've found some snippets on using fiddle, and it's working.

I guess during compilation ext/win32 dir isn't even entered.

Updated by Panyamin (Benjamin Gueroult) almost 9 years ago

Note that when compiling 2.2.4, win32 is entered because there is mkmf.log.

Updated by Panyamin (Benjamin Gueroult) almost 9 years ago

If this can help you, here is the config.log and build.log from compilation.

Updated by nobu (Nobuyoshi Nakada) almost 9 years ago

  • Backport changed from 2.3: UNKNOWN to 2.3: REQUIRED

Updated by nobu (Nobuyoshi Nakada) almost 9 years ago

  • Status changed from Feedback to Closed

Updated by Panyamin (Benjamin Gueroult) almost 9 years ago

Awesome, thank you!

Updated by naruse (Yui NARUSE) over 8 years ago

  • Backport changed from 2.3: REQUIRED to 2.1: DONTNEED, 2.2: DONTNEED, 2.3: REQUIRED

Updated by naruse (Yui NARUSE) over 8 years ago

  • Backport changed from 2.1: DONTNEED, 2.2: DONTNEED, 2.3: REQUIRED to 2.1: DONTNEED, 2.2: DONTNEED, 2.3: DONE

ruby_2_3 r54406 merged revision(s) 53868.

Updated by hedgehog (Hedge Hog) about 8 years ago

This issue is also present in ruby 2.2.6. Should I open a new issue or does it suffice to note this here?

Updated by nobu (Nobuyoshi Nakada) about 8 years ago

  • Backport changed from 2.1: DONTNEED, 2.2: DONTNEED, 2.3: DONE to 2.1: DONTNEED, 2.2: REQUIRED, 2.3: DONE

No, you don't have to open a new issue.
Changed Backport now.

Updated by usa (Usaku NAKAMURA) almost 8 years ago

  • Status changed from Closed to Feedback

Is this problem really present in ruby 2.2 ?
I've never backported default_exclude_exts feature.

Updated by hedgehog (Hedge Hog) almost 8 years ago

Yes this issue is present in 2.2.6.
When I checked the logs I saw the same symptoms reported here.
When I checked the 2.2.6 source code on my local machine it appeared that change in revision 53868 was also required there in the 2.2.6 source:

https://svn.ruby-lang.org/cgi-bin/viewvc.cgi/trunk/ext/extmk.rb?r1=53448&r2=53868&pathrev=53868

Unfortunately I am on leave and don't have access to my windows machine.

Actions #16

Updated by jeremyevans0 (Jeremy Evans) over 5 years ago

  • Status changed from Feedback to Closed
Actions

Also available in: Atom PDF

Like0
Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0Like0