ruby-debug-ide fails to install on Ubuntu with Ruby 2.0 - ruby

I'm not sure why, but I had no issues installed ruby-debug-ide for the past several months in my Ubuntu VM (running with Vagrant/Virtualbox). Today, I did a vagrant destroy then a vagrant up and all of a sudden I'm getting this new issue.
All other developers with similar issues & solutions have not given me any solutions that work for my installation. I don't know what to do at this point. Help please!
almsgive#almsgive-box:~$ gem install ruby-debug-ide
Building native extensions. This could take a while...
ERROR: Error installing ruby-debug-ide:
ERROR: Failed to build gem native extension.
/usr/local/rvm/rubies/ruby-2.0.0-p576/bin/ruby mkrf_conf.rb
Installing base gem
Building native extensions. This could take a while...
Building native extensions. This could take a while...
ERROR: Failed to build gem native extension.
/usr/local/rvm/rubies/ruby-2.0.0-p576/bin/ruby extconf.rb
checking for vm_core.h... no
checking for vm_core.h... no
Makefile creation failed
**************************************************************************
No source for ruby-2.0.0-p576 provided with debugger-ruby_core_source gem.
**************************************************************************
*** extconf.rb failed ***
Could not create Makefile due to some reason, probably lack of necessary
libraries and/or headers. Check the mkmf.log file for more details. You may
need configuration options.
Provided configuration options:
--with-opt-dir
--without-opt-dir
--with-opt-include
--without-opt-include=${opt-dir}/include
--with-opt-lib
--without-opt-lib=${opt-dir}/lib
--with-make-prog
--without-make-prog
--srcdir=.
--curdir
--ruby=/usr/local/rvm/rubies/ruby-2.0.0-p576/bin/ruby
--with-ruby-dir
--without-ruby-dir
--with-ruby-include
--without-ruby-include=${ruby-dir}/include
--with-ruby-lib
--without-ruby-lib=${ruby-dir}/
extconf failed, exit code 1
Gem files will remain installed in /usr/local/rvm/gems/ruby-2.0.0-p576/gems/debase-0.0.9 for inspection.
Results logged to /usr/local/rvm/gems/ruby-2.0.0-p576/extensions/x86_64-linux/2.0.0/debase-0.0.9/gem_make.out
/usr/local/rvm/rubies/ruby-2.0.0-p576/lib/ruby/site_ruby/2.0.0/rubygems/ext/builder.rb:89:in `run'
/usr/local/rvm/rubies/ruby-2.0.0-p576/lib/ruby/site_ruby/2.0.0/rubygems/ext/ext_conf_builder.rb:38:in `block in build'
/usr/local/rvm/rubies/ruby-2.0.0-p576/lib/ruby/2.0.0/tempfile.rb:324:in `open'
/usr/local/rvm/rubies/ruby-2.0.0-p576/lib/ruby/site_ruby/2.0.0/rubygems/ext/ext_conf_builder.rb:17:in `build'
/usr/local/rvm/rubies/ruby-2.0.0-p576/lib/ruby/site_ruby/2.0.0/rubygems/ext/builder.rb:161:in `block (2 levels) in build_extension'
/usr/local/rvm/rubies/ruby-2.0.0-p576/lib/ruby/site_ruby/2.0.0/rubygems/ext/builder.rb:160:in `chdir'
/usr/local/rvm/rubies/ruby-2.0.0-p576/lib/ruby/site_ruby/2.0.0/rubygems/ext/builder.rb:160:in `block in build_extension'
/usr/local/rvm/rubies/ruby-2.0.0-p576/lib/ruby/site_ruby/2.0.0/rubygems/ext/builder.rb:159:in `synchronize'
/usr/local/rvm/rubies/ruby-2.0.0-p576/lib/ruby/site_ruby/2.0.0/rubygems/ext/builder.rb:159:in `build_extension'
/usr/local/rvm/rubies/ruby-2.0.0-p576/lib/ruby/site_ruby/2.0.0/rubygems/ext/builder.rb:198:in `block in build_extensions'
/usr/local/rvm/rubies/ruby-2.0.0-p576/lib/ruby/site_ruby/2.0.0/rubygems/ext/builder.rb:195:in `each'
/usr/local/rvm/rubies/ruby-2.0.0-p576/lib/ruby/site_ruby/2.0.0/rubygems/ext/builder.rb:195:in `build_extensions'
/usr/local/rvm/rubies/ruby-2.0.0-p576/lib/ruby/site_ruby/2.0.0/rubygems/installer.rb:677:in `build_extensions'
/usr/local/rvm/rubies/ruby-2.0.0-p576/lib/ruby/site_ruby/2.0.0/rubygems/installer.rb:232:in `install'
/usr/local/rvm/rubies/ruby-2.0.0-p576/lib/ruby/site_ruby/2.0.0/rubygems/request_set.rb:142:in `block in install'
/usr/local/rvm/rubies/ruby-2.0.0-p576/lib/ruby/site_ruby/2.0.0/rubygems/request_set.rb:126:in `each'
/usr/local/rvm/rubies/ruby-2.0.0-p576/lib/ruby/site_ruby/2.0.0/rubygems/request_set.rb:126:in `install'
/usr/local/rvm/rubies/ruby-2.0.0-p576/lib/ruby/site_ruby/2.0.0/rubygems/dependency_installer.rb:389:in `install'
mkrf_conf.rb:34:in `rescue in <main>'
mkrf_conf.rb:27:in `<main>'
rake failed, exit code 1
Gem files will remain installed in /usr/local/rvm/gems/ruby-2.0.0-p576/gems/ruby-debug-ide-0.4.22 for inspection.
Results logged to /usr/local/rvm/gems/ruby-2.0.0-p576/extensions/x86_64-linux/2.0.0/ruby-debug-ide-0.4.22/gem_make.out

I had the same problem today with debugger-ruby_core_source (by way of debugger, not ruby-debug-ide). I changed my ruby version back to 2.0.0-p481. After that debugger-ruby_core_source installed as expected.

Related

How to pass build flags like `--with-ruby-include` to gem install?

(I know that my Ruby installation is a bit messed up, but:)
I'm trying to install a native gem and it gives me an error
ytg#yui:~> sudo /usr/bin/ruby.ruby2.3 /usr/bin/gem install ruby-debug-ide
Building native extensions. This could take a while...
ERROR: Error installing ruby-debug-ide:
ERROR: Failed to build gem native extension.
current directory: /usr/lib64/ruby/gems/2.3.0/gems/ruby-debug-ide-0.6.0/ext
/usr/bin/ruby.ruby2.3 mkrf_conf.rb
Installing base gem
Building native extensions. This could take a while...
Building native extensions. This could take a while...
ERROR: Failed to build gem native extension.
current directory: /usr/lib64/ruby/gems/2.3.0/gems/debase-0.2.2.beta9/ext
/usr/bin/ruby.ruby2.3 -r ./siteconf20161213-12983-1q9o2d7.rb extconf.rb
checking for vm_core.h... no
checking for vm_core.h... no
checking for vm_core.h... no
Makefile creation failed
*************************************************************
NOTE: If your headers were not found, try passing
--with-ruby-include=PATH_TO_HEADERS
*************************************************************
*** extconf.rb failed ***
Could not create Makefile due to some reason, probably lack of necessary
libraries and/or headers. Check the mkmf.log file for more details. You may
need configuration options.
Provided configuration options:
--with-opt-dir
--without-opt-dir
--with-opt-include
--without-opt-include=${opt-dir}/include
--with-opt-lib
--without-opt-lib=${opt-dir}/lib64
--with-make-prog
--without-make-prog
--srcdir=.
--curdir
--ruby=/usr/bin/$(RUBY_BASE_NAME).ruby2.3
--with-ruby-dir
--without-ruby-dir
---with-ruby-include
--without-ruby-include=${ruby-dir}/include
--with-ruby-lib
--without-ruby-lib=${ruby-dir}/lib64
To see why this extension failed to compile, please check the mkmf.log which can be found here:
/usr/lib64/ruby/gems/2.3.0/extensions/x86_64-linux/2.3.0/debase-0.2.2.beta9/mkmf.log
extconf failed, exit code 1
Gem files will remain installed in /usr/lib64/ruby/gems/2.3.0/gems/debase-0.2.2.beta9 for inspection.
Results logged to /usr/lib64/ruby/gems/2.3.0/extensions/x86_64-linux/2.3.0/debase-0.2.2.beta9/gem_make.out
/usr/lib64/ruby/2.3.0/rubygems/ext/builder.rb:92:in `run'
/usr/lib64/ruby/2.3.0/rubygems/ext/ext_conf_builder.rb:37:in `block in build'
/usr/lib64/ruby/2.3.0/tempfile.rb:295:in `open'
/usr/lib64/ruby/2.3.0/rubygems/ext/ext_conf_builder.rb:20:in `build'
/usr/lib64/ruby/2.3.0/rubygems/ext/builder.rb:164:in `block (2 levels) in build_extension'
/usr/lib64/ruby/2.3.0/rubygems/ext/builder.rb:163:in `chdir'
/usr/lib64/ruby/2.3.0/rubygems/ext/builder.rb:163:in `block in build_extension'
/usr/lib64/ruby/2.3.0/rubygems/ext/builder.rb:162:in `synchronize'
/usr/lib64/ruby/2.3.0/rubygems/ext/builder.rb:162:in `build_extension'
/usr/lib64/ruby/2.3.0/rubygems/ext/builder.rb:201:in `block in build_extensions'
/usr/lib64/ruby/2.3.0/rubygems/ext/builder.rb:198:in `each'
/usr/lib64/ruby/2.3.0/rubygems/ext/builder.rb:198:in `build_extensions'
/usr/lib64/ruby/2.3.0/rubygems/installer.rb:742:in `build_extensions'
/usr/lib64/ruby/2.3.0/rubygems/installer.rb:291:in `install'
/usr/lib64/ruby/2.3.0/rubygems/request_set.rb:167:in `block in install'
/usr/lib64/ruby/2.3.0/rubygems/request_set.rb:151:in `each'
/usr/lib64/ruby/2.3.0/rubygems/request_set.rb:151:in `install'
/usr/lib64/ruby/2.3.0/rubygems/dependency_installer.rb:405:in `install'
mkrf_conf.rb:35:in `rescue in <main>'
mkrf_conf.rb:28:in `<main>'
rake failed, exit code 1
Gem files will remain installed in /usr/lib64/ruby/gems/2.3.0/gems/ruby-debug-ide-0.6.0 for inspection.
Results logged to /usr/lib64/ruby/gems/2.3.0/extensions/x86_64-linux/2.3.0/ruby-debug-ide-0.6.0/gem_make.out
But then when I try to add the suggested argument, I get:
ytg#yui:~> sudo /usr/bin/ruby.ruby2.3 /usr/bin/gem install ruby-debug-ide --with-ruby-include="/usr/include/ruby-2.3.0/"
ERROR: While executing gem ... (OptionParser::InvalidOption)
invalid option: --with-ruby-include=/usr/include/ruby-2.3.0/
/usr/lib64/ruby/2.3.0/rubygems/command.rb:378:in `handle_options'
/usr/lib64/ruby/2.3.0/rubygems/command.rb:299:in `invoke_with_build_args'
/usr/lib64/ruby/2.3.0/rubygems/command_manager.rb:169:in `process_args'
/usr/lib64/ruby/2.3.0/rubygems/command_manager.rb:139:in `run'
/usr/lib64/ruby/2.3.0/rubygems/gem_runner.rb:55:in `run'
/usr/bin/gem:21:in `<main>'
Is there a way to make gem install recognise those header files?
You have to separate the build flags from the options with --.
From the help page: (gem install --help)
Usage
gem install GEMNAME [GEMNAME ...] [options] -- --build-flags [options]
Later on:
Extension Install Failures
If an extension fails to compile during gem installation the gem specification is not written out, but the gem remains unpacked in the repository. You may need to specify the path to the library’s headers and libraries to continue. You can do this by adding a -- between RubyGems' options and the extension's build options:
$ gem install some_extension_gem
[build fails]
Gem files will remain installed in /path/to/gems/some_extension_gem-1.0 for inspection.
Results logged to /path/to/gems/some_extension_gem-1.0/gem_make.out
$ gem install some_extension_gem -- --with-extension-lib=/path/to/lib
[build succeeds]

Green_Shoes fails to build native gem extension

I'm trying to install green_shoes on Windows 8.1. I have ruby 2.0.0p451 and gem version 2.0.14 on a 64-bit OS. I also installed the ruby-gtk2 package recommended on the green_shoes page. Any idea what's up?
C:\>gem install green_shoes
Temporarily enhancing PATH to include DevKit...
Building native extensions. This could take a while...
ERROR: Error installing green_shoes:
ERROR: Failed to build gem native extension.
C:/Ruby200-x64/bin/ruby.exe extconf.rb
checking for --enable-debug-build option... no
checking for -Wall option to compiler... *** extconf.rb failed ***
Could not create Makefile due to some reason, probably lack of necessary
libraries and/or headers. Check the mkmf.log file for more details. You may
need configuration options.
Provided configuration options:
--with-opt-dir
--without-opt-dir
--with-opt-include
--without-opt-include=${opt-dir}/include
--with-opt-lib
--without-opt-lib=${opt-dir}/lib
--with-make-prog
--without-make-prog
--srcdir=.
--curdir
--ruby=C:/Ruby200-x64/bin/ruby
--enable-debug-build
--disable-debug-build
C:/Ruby200-x64/lib/ruby/2.0.0/mkmf.rb:434:in `try_do': The compiler failed to ge
nerate an executable file. (RuntimeError)
You have to install development tools first.
from C:/Ruby200-x64/lib/ruby/2.0.0/mkmf.rb:549:in `block in try_compile'
from C:/Ruby200-x64/lib/ruby/2.0.0/mkmf.rb:502:in `with_werror'
from C:/Ruby200-x64/lib/ruby/2.0.0/mkmf.rb:549:in `try_compile'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/glib2-2.2.3/lib/mkmf-gnome2
.rb:58:in `block in try_compiler_option'
from C:/Ruby200-x64/lib/ruby/2.0.0/mkmf.rb:895:in `block in checking_for
'
from C:/Ruby200-x64/lib/ruby/2.0.0/mkmf.rb:340:in `block (2 levels) in p
ostpone'
from C:/Ruby200-x64/lib/ruby/2.0.0/mkmf.rb:310:in `open'
from C:/Ruby200-x64/lib/ruby/2.0.0/mkmf.rb:340:in `block in postpone'
from C:/Ruby200-x64/lib/ruby/2.0.0/mkmf.rb:310:in `open'
from C:/Ruby200-x64/lib/ruby/2.0.0/mkmf.rb:336:in `postpone'
from C:/Ruby200-x64/lib/ruby/2.0.0/mkmf.rb:894:in `checking_for'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/glib2-2.2.3/lib/mkmf-gnome2
.rb:57:in `try_compiler_option'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/glib2-2.2.3/lib/mkmf-gnome2
.rb:67:in `<top (required)>'
from C:/Ruby200-x64/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:5
5:in `require'
from C:/Ruby200-x64/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:5
5:in `require'
from extconf.rb:15:in `<main>'
Gem files will remain installed in C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/glib2
-2.2.3 for inspection.
Results logged to C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/glib2-2.2.3/ext/glib2/
gem_make.out

How to install cocoapoads 0.33.1 on os X

I have upgrade my os to Yosemite, and as you know, my cocoapods doesn't work. and I found the solution on the internet and try.
It worked. but I found the cocoapods version is 0.34.4. I hope to install cocoapods 0.33.1, and I try sudo gem install cocoapods -v 0.33.1, but it doesn't work. Who can tell me what should I do??
The is the error log:
Building native extensions. This could take a while...
ERROR: Error installing cocoapods:
ERROR: Failed to build gem native extension.
"/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/bin/ruby" -rubygems /Library/Ruby/Gems/2.0.0/gems/rake-0.9.6/bin/rake RUBYARCHDIR=/Library/Ruby/Gems/2.0.0/gems/xcodeproj-0.17.0/ext RUBYLIBDIR=/Library/Ruby/Gems/2.0.0/gems/xcodeproj-0.17.0/ext
/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/bin/ruby extconf.rb
checking for -std=c99 option to compiler... *** extconf.rb failed ***
Could not create Makefile due to some reason, probably lack of necessary
libraries and/or headers. Check the mkmf.log file for more details. You may
need configuration options.
Provided configuration options:
--with-opt-dir
--without-opt-dir
--with-opt-include
--without-opt-include=${opt-dir}/include
--with-opt-lib
--without-opt-lib=${opt-dir}/lib
--with-make-prog
--without-make-prog
--srcdir=.
--curdir
--ruby=/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/bin/ruby
/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:434:in `try_do': The compiler failed to generate an executable file. (RuntimeError)
You have to install development tools first.
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:549:in `block in try_compile'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:502:in `with_werror'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:549:in `try_compile'
from extconf.rb:24:in `block in <main>'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:895:in `block in checking_for'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:340:in `block (2 levels) in postpone'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:310:in `open'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:340:in `block in postpone'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:310:in `open'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:336:in `postpone'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/mkmf.rb:894:in `checking_for'
from extconf.rb:23:in `<main>'
rake aborted!
Command failed with status (1): [/System/Library/Frameworks/Ruby.framework/...]
/Library/Ruby/Gems/2.0.0/gems/xcodeproj-0.17.0/ext/xcodeproj/Rakefile:37:in `block in <top (required)>'
Tasks: TOP => default => ext
(See full trace by running task with --trace)
Gem files will remain installed in /Library/Ruby/Gems/2.0.0/gems/xcodeproj-0.17.0 for inspection.
Results logged to /Library/Ruby/Gems/2.0.0/gems/xcodeproj-0.17.0/ext/xcodeproj/gem_make.out
OK,I found that the question has been resolved after I installed macports.
https://www.macports.org/install.php

Installing a gem w/chef fails with Gem::Installer::ExtensionBuildError: chef_gem[fog]

I'm attempting to use the route53 cookbook but it continuously fails on the fog installation phase.
libxml2-dev and libxslt1-dev are already installed but the chef_gem "fog" phase fails:
Gem::Installer::ExtensionBuildError: chef_gem[fog] (route53::default line 42) had an error: Gem::Installer::ExtensionBuildError: ERROR: Failed to build gem native extension.
/opt/chef/embedded/bin/ruby extconf.rb
Extracting libxml2-2.8.0.tar.gz into tmp//ports/libxml2/2.8.0... OK
Running 'configure' for libxml2 2.8.0... ERROR, review 'tmp//ports/libxml2/2.8.0/configure.log' to see what happened.
*** extconf.rb failed ***
Could not create Makefile due to some reason, probably lack of
necessary libraries and/or headers. Check the mkmf.log file for more
details. You may need configuration options.
Provided configuration options:
--with-opt-dir
--with-opt-include
--without-opt-include=${opt-dir}/include
--with-opt-lib
--without-opt-lib=${opt-dir}/lib
--with-make-prog
--without-make-prog
--srcdir=.
--curdir
--ruby=/opt/chef/embedded/bin/ruby
/opt/chef/embedded/lib/ruby/gems/1.9.1/gems/mini_portile-0.5.2/lib/mini_portile.rb:265:in `block in execute': Failed to complete configure task (RuntimeError)
from /opt/chef/embedded/lib/ruby/gems/1.9.1/gems/mini_portile-0.5.2/lib/mini_portile.rb:257:in `chdir'
from /opt/chef/embedded/lib/ruby/gems/1.9.1/gems/mini_portile-0.5.2/lib/mini_portile.rb:257:in `execute'
from /opt/chef/embedded/lib/ruby/gems/1.9.1/gems/mini_portile-0.5.2/lib/mini_portile.rb:65:in `configure'
from /opt/chef/embedded/lib/ruby/gems/1.9.1/gems/mini_portile-0.5.2/lib/mini_portile.rb:108:in `cook'
from extconf.rb:101:in `block in <main>'
from extconf.rb:119:in `call'
from extconf.rb:119:in `block in <main>'
from extconf.rb:109:in `tap'
from extconf.rb:109:in `<main>'
Gem files will remain installed in /opt/chef/embedded/lib/ruby/gems/1.9.1/gems/nokogiri-1.6.1 for inspection.
Results logged to /opt/chef/embedded/lib/ruby/gems/1.9.1/gems/nokogiri-1.6.1/ext/nokogiri/gem_make.out
Very similar to Installing a gem after native extension packages during chef execution but the circumstances are different. The installation recipe: https://github.com/hw-cookbooks/route53/blob/master/recipes/default.rb
Anyone have any suggestions as to how I can resolve this? Basically the fault is nokogiri won't install with ruby 1.9.3p484. /opt/chef/embedded/bin/gem install nokogiri fails as well.
You'll need to have the prerequisite packages installed on the machine. For instance, on Ubuntu you'll need the build-essential package and possibly some others installed in order for this to succeed.

Problems in installing thin on windows 7

I am new to ruby. I am trying to install a ruby gem thin. It shows an error in installing the gem. I googled for the error but i could not find a link that addresses my problem.
The error is:
C:\Users\name\Desktop>ruby -v
ruby 2.0.0p247 (2013-06-27) [i386-mingw32]
C:\Users\name\Desktop>gem -v
2.0.3
C:\Users\name\Desktop>gem install thin
Temporarily enhancing PATH to include DevKit...
Building native extensions. This could take a while...
ERROR: Error installing thin:
ERROR: Failed to build gem native extension.
C:/Ruby200/bin/ruby.exe extconf.rb
checking for main() in -lc... *** extconf.rb failed ***
Could not create Makefile due to some reason, probably lack of necessary
libraries and/or headers. Check the mkmf.log file for more details. You may
need configuration options.
Provided configuration options:
--with-opt-dir
--without-opt-dir
--with-opt-include
--without-opt-include=${opt-dir}/include
--with-opt-lib
--without-opt-lib=${opt-dir}/lib
--with-make-prog
--without-make-prog
--srcdir=.
--curdir
--ruby=C:/Ruby200/bin/ruby
--with-thin_parser-dir
--without-thin_parser-dir
--with-thin_parser-include
--without-thin_parser-include=${thin_parser-dir}/include
--with-thin_parser-lib
--without-thin_parser-lib=${thin_parser-dir}/
--with-clib
--without-clib
C:/Ruby200/lib/ruby/2.0.0/mkmf.rb:430:in `try_do': The compiler failed to generate an executable file. (RuntimeError)
You have to install development tools first.
from C:/Ruby200/lib/ruby/2.0.0/mkmf.rb:515:in `try_link0'
from C:/Ruby200/lib/ruby/2.0.0/mkmf.rb:530:in `try_link'
from C:/Ruby200/lib/ruby/2.0.0/mkmf.rb:716:in `try_func'
from C:/Ruby200/lib/ruby/2.0.0/mkmf.rb:946:in `block in have_library'
from C:/Ruby200/lib/ruby/2.0.0/mkmf.rb:891:in `block in checking_for'
from C:/Ruby200/lib/ruby/2.0.0/mkmf.rb:336:in `block (2 levels) in postpone'
from C:/Ruby200/lib/ruby/2.0.0/mkmf.rb:306:in `open'
from C:/Ruby200/lib/ruby/2.0.0/mkmf.rb:336:in `block in postpone'
from C:/Ruby200/lib/ruby/2.0.0/mkmf.rb:306:in `open'
from C:/Ruby200/lib/ruby/2.0.0/mkmf.rb:332:in `postpone'
from C:/Ruby200/lib/ruby/2.0.0/mkmf.rb:890:in `checking_for'
from C:/Ruby200/lib/ruby/2.0.0/mkmf.rb:941:in `have_library'
from extconf.rb:4:in `<main>'
Gem files will remain installed in C:/Ruby200/lib/ruby/gems/2.0.0/gems/thin-1.6.0 for inspection.
Results logged to C:/Ruby200/lib/ruby/gems/2.0.0/gems/thin-1.6.0/ext/thin_parser/gem_make.out
C:\Users\name\Desktop>
Any help truly appreciated. Thanks.
I resolved the problem by following these steps. Posting this answer as it might be useful for others.
I uninstalled and deleted all the ruby stuff and restarted the machine. Downloaded Ruby 2.0 and Devkit from here http://rubyinstaller.org/downloads/.
Installed ruby and devkit. Install devkit using the instructions given in this link https://github.com/oneclick/rubyinstaller/wiki/Development-Kit.
cd to ruby folder and installed rails, thin gem

Resources