I am doing some ruby scripting in windows, which involves opening and closing a browser. To that end I needed some special gems to interface to the native windows system calls. But when I tried
> gem install sys-proctable
, it yielded
ERROR: Could not find a valid gem ´sys-proctable´ (>= 0), here is why:
Found sys-proctable (0.9.0), but was for platforms x86-darwin-8
,x86-freebsd-7 ,x86-solaris-2.10 ,x86-linux ,x86-mswin32-60
The problem is that my gem installation does not have the x86-mswin32-60 rubygems platform
> gem environment
RubyGems Environment:
- RUBYGEMS VERSION: 1.3.7
- RUBY VERSION: 1.8.7 (2010-01-10 patchlevel 249) [i386-mingw32]
...
- RUBYGEMS PLATFORMS:
- ruby
- x86-mingw32
...
It seems that the problem comes from my version of ruby being compiled with mingw libraries. So my question is: how can I get a version of ruby, where rubygems platforms include x86-mswin32-60? I cannot find any installers from rubyinstaller.org which are not mingw.
--- edit ---
That last part was a bit hasty. Actually, rubyinstaller.org has the legacy one-click installers, which were built for mswin32. But that install had some other problems for me, so I guess I will try the solution from Luis below.
You can force the gem installation specifying --platform
option:
gem install sys-proctable --platform=x86-mswin32-60
However, I advise against it for several reasons, some I've mentioned in my blog here
Please test first and see if it will work before pushing a code that is based on this into a production environment.
Hope that helps.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With