From: Luis Lavena Date: 2010-01-23T03:05:05+09:00 Subject: Re: Ruby c extensions on windows On Jan 22, 11:59 am, Nilbert Nullingsworth wrote: > I cannot follow this tutorial for some reason. I have no idea what to > do after I've got the files set up, make is not a recognized command, > and trying to do the rake leads to about three errors like this: > > error loading "C:/Ruby/lib/ruby/gems/1.9.1/gems/hoe-2.5.0/lib/hoe/ > rubyforge.rb": >  182: The operating system cannot run %1.   - C:/Ruby/lib/ruby/1.9.1/ > i386-mswin3 > 2/openssl.so. skipping... > > and then fails with 'rake aborted!'. > > I also cannot find the mt.exe that other tutorials say to use, even > though I have Visual Studio Express 2008 installed, along with the > windows sdk and all it's components. > > Why is writing a ruby extension so hard? Because you're using the wrong tools, and because when you get "RTFM" there should be a better manual in the first place, which something Ruby lacks. First: unless you compiled Ruby 1.9.1 with the version of Visual Studio you're using, it will not compile the extensions. Compilers are not exchangeable in Ruby. Second: The version and setup should be pretty much exactly the same, if not, it will fail. Third: A recommendation: Download and install RubyInstaller 1.9.1 or 1.8.6: http://rubyinstaller.org/ Then download and install the Development Kit, which includes MinGW +MSYS to make extension compilation simple. Follow this tutorial to get those installed: http://geeksharp.com/2010/01/18/windows-ruby-native-gems-1-9-1/ Then make and everything will work. Fourth: be polite. We all do our best to help you, please breathe first before insulting or use improper words to people is trying to help you. Fifth: Python has the same sort of issues mixing and matching compilers. Good luck. -- Luis Lavena