Cygwin or mingw code#
Thus, by linking the source code of these tools to this shared library, a cross-compiler on the unix host can be used to generate a toolset that can run on the windows platform.
Therefore, they took a different approach and wrote a shared library (the cygwin dll) that encapsulates unix-style calls (such as fork, spawn, signals, select, sockets, etc.) that are not available in the win32 api, i.e., they wrote a unix system library emulation layer based on the win32 api. One option was to make significant changes to the source code of these tools based on the win32 api, which obviously required a lot of work. Then, they wanted to port these tools to the windows platform. BSD, and other Unix systems) to Windows by recompiling them.Ĭygnus first took development tools such as gcc, gdb, and gas and improved them so that they could generate and interpret win32 target files. In addition, as Linux systems have grown, Cygwin now offers more than just POSIX compatibility, and therefore has more emulation layer dependencies along with it. The most typical and basic emulation layer is cygwin1.dll. To achieve this, Cygwin provides a set of abstraction layer dlls that convert some of the Posix calls into Windows API calls and implement the relevant functionality. The purpose of the project is to provide a Unix-like environment (represented by GNU tools) running on a Windows platform. Cygwin, formerly from Cygnus (acquired by Red Hat), is currently a project under the RedHat name.