11.11.07

Merb on Windows: Need to have gcc installed. Forget it … I’m done.

Posted in Programming, Ruby, merb at 2:12 pm by Robert Horvick

[Update: Merb is now working on Windows

Previously I ran into this error when trying to get merb running on Windows:

C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/RubyInline-3.6.5/lib/inline.rb:397:in ``': No such file or directory - cl -nologo -LD -Werror  -MD -Zi -O2b2xg- -G6 -I C:/InstantRails/ruby/lib/ruby/1.8/i386-mswin32 -I C:/InstantRails/ruby/include -o "C:/Users/Robert/AppData/Local/Temp/.ruby_inline/Inline_ParseTree_fa12.so" "C:/Users/Robert/AppData/Local/Temp/.ruby_inline/Inline_ParseTree_fa12.c"  -link /LIBPATH:"C:/InstantRails/ruby/lib" /DEFAULTLIB:"msvcrt-ruby18.lib" /INCREMENTAL:no /EXPORT:Init_Inline_ParseTree_fa12 (Errno::ENOENT)
 from C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/RubyInline-3.6.5/lib/inline.rb:397:in `build'
 from C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/RubyInline-3.6.5/lib/inline.rb:679:in `inline'
 from C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/ParseTree-2.0.2/lib/parse_tree.rb:243
 from C:/InstantRails/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `gem_original_require'
 from C:/InstantRails/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in `require'
 from C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/ruby2ruby-1.1.7/lib/ruby2ruby.rb:4
 from C:/InstantRails/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:32:in `gem_original_require'
 from C:/InstantRails/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:32:in `require'
  ... 13 levels...
 from C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/merb-0.4.1/lib/merb/server.rb:500:in `run'
 from C:/InstantRails/ruby/lib/ruby/gems/1.8/gems/merb-0.4.1/bin/merb:6
 from C:/InstantRails/ruby/bin/merb:16:in `load'
 from C:/InstantRails/ruby/bin/merb:16

It turns out that merb depends on RubyInline which is the Ruby way to generate C code via Ruby.  Why does it require C code generation?  Honestly I’m not interested enough to continue digging.  I’m not installing gcc on this box.  A quick glance into inline.rb shows that this is a gcc-specific generator and I’m not inclined to spend a day writing the VC interface just to get another step further with merb.

Perhaps I’ll try merb out on my desktop sometime - I dual boot it to Ubuntu - but the point of having it on the laptop was so that I could veg out in bed after the kids were asleep and the wife and I are winding down (and I’m not putting Ubuntu on this machine - Vista is very stable and everything is working how I want it - I’m not going to tempt fate by changing partitions and adding grub).  I know I could remote in to the desktop via any number of protocols but this was just to see what I thought of merb.  I think at this point I’ve figure that out.

Merb looks interesting but has taken, so far, a very unix-centric development turn.  Rails is far more platform neutral and is therefore more compelling to me.

I’ll continue to keep an eye on merb, though.  It looks promising.

[Slashdot] [Digg] [Reddit] [del.icio.us] [Facebook] [Technorati] [Google] [StumbleUpon]

5 Comments »

  1. kahfei said,

    November 11, 2007 at 8:05 pm

    Nice write up of your merb experience.

    I have my desktop running Ubuntu Feisty stablely, and later upgraded to Gutsy via upgrade. Not much problem as well.

    But then when I got the Gutsy Live CD, and decided to go ahead and do a fresh installation, almost everythin went wrong. It hang for no obvious reason, or it restarted itself all of a sudden, all kinda funny things happen.

    I have tried to re-install it (in fact, more than 4 times re-installation), install Feisty, etc. But the same problem remain.

    I find that I end up spending too much of my time try to get the OS running than actually using it. Although I still like Ubuntu a lot, but just have to revert back to Windows for the time being for playing with Rails at the moment, at least until I have capacities to digg deeper into the problem.

  2. Ezra said,

    November 13, 2007 at 4:18 pm

    Hey there- sorry you ran into problems getting up and running with merb on windows. I will admit that I don’t use windows myself but I will say that merb will remain compatible with windows. I will post this on the new website later today for other windows users but here is how you can get merb up and running on windows with no c compiler.

    First you will need to grab the ParseTree and Rubyinline gems that have been precompiled for the win32 one cick installer. Grab them from here:

    http://web.mit.edu/~agp/www/parsetree-win32/ParseTree-2.0.2-mswin32.gem

    http://web.mit.edu/~agp/www/parsetree-win32/RubyInline-3.6.4.gem

    Download those and install them with gem install .gem. Then you will need to install Ruby2Ruby from the regular rubygems repo:

    gem install ruby2ruby.

    Then you can install the merb gem with gem install merb -y

    This is verified to work on windows with the one click installer and these gems.

    We will be putting together a simple merb installer script for win32 and other platforms that will take care of setting this all up.

    But have faith! We will be working to make sure merb stays win32 compatible.

  3. admin said,

    November 13, 2007 at 8:23 pm

    Ezra - thanks for following up and providing some concrete suggestions on how to move forward. I’ll try this out again ASAP.

    robert.

  4. Merb on Windows - the steps you need to make it happen. | Ghost On Third said,

    November 17, 2007 at 12:09 am

    [...] a big thanks to Ezra for providing the pointers I [...]

  5. Lionel said,

    June 20, 2008 at 8:57 am

    Hi there,
    A zip of all necessary gems would be very appreciated for windows workstation users. Because firewalls and workstation at work are so boring, I can’t build the zip file myself.
    Does someone know where it is possible to download all these gems ?
    Lionel

Leave a Comment