On Sep 11, 2006, at 12:46 AM, Mike Berrow wrote:

> Eric Hodel wrote:
>> == Play along at home!
>> ....
>
> Thanks,
> but it seems I am missing some setup needed for RubyInline itself
>
> I tried running the hello.rb in
> C:\ruby\lib\ruby\gems\1.8\gems\RubyInline-3.5.0\demo
>
> and got this ...
>
> C:\ruby\lib\ruby\gems\1.8\gems\RubyInline-3.5.0\demo>ruby hello.rb
> c:/ruby/lib/ruby/gems/1.8/gems/RubyInline-3.5.0/./inline.rb:64:in
> `test': can't
> convert nil into String (TypeError)
>         from

You need to set INLINEDIR or HOME in your environment.  This will be  
fixed in the next release.

> In Cygwin I get ...
>
> $ ruby hello.rb
> c:/ruby/lib/ruby/gems/1.8/gems/RubyInline-3.5.0/./inline.rb:396:in  
> ``':
> No such
> file or directory - cl -nologo -LD  -MD -Zi -O2b2xg- -G6 -I
> c:/ruby/lib/ruby/1.8
> /i386-mswin32 -o C:\cygwin\home\User1/.ruby_inline/ 
> Inline_Hello_5d41.so
> C:
> \cygwin\home\User1/.ruby_inline/Inline_Hello_5d41.c  -link
> /INCREMENTAL:no
>  /EXPORT:Init_Inline_Hello_5d41 (Errno::ENOENT)
>         from
> c:/ruby/lib/ruby/gems/1.8/gems/RubyInline-3.5.0/./inline.rb:396:in
> `build'

You need the MS C compiler.

> I know I have MingW32 on here since I installed Dev-C++ and have that
> running.
> At C:\Dev-Cpp\bin there is a gcc.exe

Your ruby wasn't compiled with GCC.  If you want inline to use GCC,  
you need to compile ruby with it.

> Is it it just a matter of hooking it up this right way in RubyInline ?

RubyInline uses whatever C compiler Ruby was built with.  If you  
don't have the same compiler installed inline won't be able to do its  
thing.  For windows using the one-click installer you need to either  
install the same compiler or build ruby from scratch with a GCC.

-- 
Eric Hodel - drbrain / segment7.net - http://blog.segment7.net
This implementation is HODEL-HASH-9600 compliant

http://trackmap.robotcoop.com