From: ptkwt@...1.aracnet.com (Phil Tomson) Date: 2002-01-10T12:42:15+09:00 Subject: Re: Need help understanding system() call In article <3C3CB2A8.5630.1203CA1@localhost>, wrote: >Hi, > [snip] > >Among the missing entries, the important on is the one that allows the >cygwin1.dll find it's /usr/bin (c:/cygwin/bin Windows) directory. It >is important because cygwin1.dll is using the env.exe program in >C:/cygwin/bin. Apparently, env.exe is used to locate the system >command that the system() call is asked to execute. > Hmmmm... but if you override system like: ######redefine 'system' if running on Windows: if RUBY_PLATFORM =~ /win/i require 'Win32API' def system(command) Win32API.new("crtdll","system",['P'],'L').Call(command) end end ############################################# ....it should work even without having cygwin installed, right? I did this on a win98 system that didn't have cygwin installed this last weekend and it seemed to work. >The moral? We, er, uh, non-Linux folks can all look forward to the >day the native Windows Ruby installation package becomes available. >Maybe we can all try to help that day along. So what needs to be done to get there? Phil