Nobuyoshi Nakada wrote:

>> We use:
>> SWIG Version 1.3.29 Compiled with g++ [i686-pc-cygwin]
>> ruby 1.8.1 (2003-12-25) [i386-mswin32]
> 
> Cygwin runtime and msvcrt don't share file descriptors.
> 
> You need to SWIG compiled with MSVC or mingw.

Ok, I build ruby myself, and I installed the windows version of SWIG.
Both my app and ruby are build with VS8

ruby 1.8.6 (2007-03-13 patchlevel 0) [i386-mswin32_80]
SWIG Version 1.3.31 Compiled with g++ [i686-pc-mingw32]

My script does not use file handles, actually it does not matter what is 
inside the script, if it calls any of my functions wrapped with swig 
then I get errors such as

#<Errno::EBADF: (eval):896:in `write': Bad file descriptor>

What to do next?
How can I build a debug version of the ruby dll?

Luc
-- 
Posted via http://www.ruby-forum.com/.