Running non-cygwin executables in cygwin bash terminal or script

Kal Sze
Wed Nov 5 08:19:00 GMT 2014


In general, is there anything that can go wrong or not work if I
invoke regular Windows/.NET executables (not compiled with any cygwin
header or linked with any cygwin dll) from a cygwin bash terminal or

I am planning to write a bash script to call rsync and then a command
line program written in C# (.NET framework 4.5 in Visual Studio 2013).

I'm not a huge cygwin/posix/unix hacker, so there are a few things
that seem murky. I suppose that are other people in similar

I can think of a few things that don't seem entirely clear in the
documentation and FAQ.

I'm guessing that invoking regular Windows/.NET executables would
mostly just work, with the following caveat:
- stdin/stdout/stderr redirection and piping would still work, even
when piping with cygwin-linked programs (care with charset and
end-of-line conventions needs to be taken, however);
- UNIX-style sockets are out of the question;
- the usual Window permission model would still be used;
- if the regular Windows/.NET executable accepts a file or directory
path as argument, it still needs to be written in the Windows style
(i.e. "C:\\foobar\\" instead of "/cygdrive/c/foobar");
- the locale of the cygwin bash process may cause problems when
passing arguments to the regular Windows program.

Am I mostly correct? So far it seems to work. Am I missing other caveat?

Would it make sense to have all this summarized in the FAQ?

Best Regards,

Problem reports:
Unsubscribe info:

More information about the Cygwin mailing list