Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Ruby > Problems compiling Ruby extension in MSVC

Reply
Thread Tools

Problems compiling Ruby extension in MSVC

 
 
Sriyansa
Guest
Posts: n/a
 
      01-25-2006
I am trying to compile my ruby extension under Windows with the MSVC
compiler shipped with Visual Studio 2003. I have followed the steps
outlined here:

http://www.koontzfamily.org/david/blog/?p=230

However on doing nmake I get the following errors:

cl : Command line warning D4024 : unrecognized source file type
'files/ruby/lib/ruby/1.8/i386-mswin3
2', object file assumed
cl : Command line warning D4027 : source file
'files/ruby/lib/ruby/1.8/i386-mswin32' ignored
cl : Command line warning D4024 : unrecognized source file type
'files/ruby/lib/ruby/1.8/i386-mswin3
2', object file assumed
cl : Command line warning D4027 : source file
'files/ruby/lib/ruby/1.8/i386-mswin32' ignored
Test.c
Test.c(1) : fatal error C1083: Cannot open include file: 'ruby.h': No
such file or directory
NMAKE : fatal error U1077: 'cl' : return code '0x2'
Stop.

It seems that the compiler does not like spaces in the include path (My
ruby install directory is D:\Program files\ruby). Is there any better
way of getting extensions to work under windows?

The ruby.h file is present at D:/Program
files/ruby/lib/ruby/1.8/i386-mswin32.

thanks,
Sriyansa

 
Reply With Quote
 
 
 
 
jussij@zeusedit.com
Guest
Posts: n/a
 
      01-25-2006
> It seems that the compiler does not like spaces in
> the include path (My ruby install directory is
> D:\Program files\ruby).


Try wrapping the path in quotes for example:

"D:\Program files\ruby"

Jussi Jumppanen
Author: Zeus for Windows Ruby IDE
http://www.zeusedit.com

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Compiling Ruby with MSVC Sergey Haritonov Ruby 0 01-17-2009 06:43 AM
Problem in compiling a C code with MSVC++6.00 Babak C Programming 23 06-27-2006 07:22 AM
Compiling C extensions with MSVC Eric Hofreiter Ruby 5 11-05-2005 12:14 AM
Compiling when libedit is in path Is there a trick to compiling Ruby when libedit must exist in the search path? Can you statically link to readline 5.0 in some manner? -- Lon Baker Lon Baker Ruby 1 03-21-2005 08:57 AM
Problem Compiling Xerces-C 2.3 with MSVC.Net 7.1 Dan XML 0 07-01-2003 11:57 AM



Advertisments