[Rubygems-developers] Still issues with mswin32 as platform

Eric Hodel drbrain at segment7.net
Mon Dec 17 22:23:39 EST 2007


On Dec 17, 2007, at 18:20 PM, Luis Lavena wrote:
> On Dec 17, 2007 10:25 PM, Eric Hodel <drbrain at segment7.net> wrote:
>>>
>>> The higher resolution videos:
>>>
>>> http://mmediasys.com/rubygems/rubygems_behavior-2.mp4 (12MB)
>>> http://mmediasys.com/rubygems/rubygems_behavior-2.mov (112MB)
>>>
>>> Still need to check what codecs works cross platform, and also it
>>> seems QT7 Animation codec don't work so well on windows :-P
>>
>> At 04:11, where `gem install pkg\...` doesn't work, but `cd pkg; gem
>> install ...` works may be due to Dir glob usage in lib/rubygems/
>> dependency_installer.rb:54
>>
>> Does Dir['pkg\*'] work properly in Windows from irb?
>>
>> Does `gem install pkg/...` work?
>>
>
> Yes, also:
>
> D:\Users\Luis\projects\_sandbox\test_gem>irb
> irb(main):001:0> Dir['pkg\*']
> => []
> irb(main):002:0> Dir['pkg/*']
> => ["pkg/test_gem-0.1.0-x86-mswin32-60.gem"]
> irb(main):003:0> File.expand_path('pkg\*')
> => "D:/Users/Luis/projects/_sandbox/test_gem/pkg/*"
> irb(main):004:0> Dir[File.expand_path('pkg/*')]
> => ["D:/Users/Luis/projects/_sandbox/test_gem/pkg/test_gem-0.1.0-x86- 
> mswin32-60.gem"]
>
> Maybe a combination of File.expand_path and Dir.glob could do the
> trick? Compared to 0.9.4 one change that can break some 'rake
> gem_install' tasks.

Do you think gem_name.gsub(File::ALT_SEPARATOR, File::SEPARATOR) be  
sufficient?

>> 07:13:
>>
>>> Gem::Platform::WIN32 is badly broken.  (for peace of mind, why don't
>>> we remove it?)
>>
>> Agreed.  If I recall correctly, the WIN32 constant is only needed by
>> gem authors, so having a missing constant will force them to switch  
>> to
>> CURRENT.
>>
>> I will do the same with the remaining constants, and add a
>> const_missing that tells gem authors how to upgrade.
>
> :-D

Ok, committed.


More information about the Rubygems-developers mailing list