Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Does cygwin work line wine, providing a compatibility layer inside a foreign os?

share|improve this question

Does Cygwin work like wine? No.

Does it provide a compatibility layer inside a foreign OS? Yes.

Wine can run Windows executables on Linux, but Cygwin cannot run Linux executables on Windows. Instead, Linux programs have to be compiled specifically for Cygwin, whereby the aim of the Cygwin project is to make that as straightforward as possible, i.e. it's aiming for source compatibility rather than binary compatibility.

However, Winelib, which is part of the Wine project, essentially is Cygwin in reverse: it provides a source compatibility layer that allows Windows programs to be compiled into Linux executables.

share|improve this answer
so Cygwin is a library as well? A layer of general functions which work on windows that linux commands can map to? thanks – Vass Sep 30 '11 at 16:59
Yes, at the core of Cygwin is the Cygwin DLL (dynamic-link library), which plays a similar role in Cygwin as glibc does in Linux. However, instead of implementing the POSIX API in terms of Linux kernel calls, it implements it using the Windows API and the underlying NT API. For some things the mapping is straightforward, but for others, e.g. fork(), it is complex and slow. – ak2 Sep 30 '11 at 18:55
Is there a closer equivalent to Wine for running linux programs on windows? – Alex Flint Apr 4 at 16:40

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.