So to run the program which needs lots of dependency on other libraries, I would prefer Cigwin over minGW. You will need special modification on LIBRARY_PATH environment variable which is very tedious and cumbersome. So the client program cannot configure with ”./configure”. Usually in linux /usr/local/lib is the default library search path. The problem arises while a program depends on third party library – there is no place to put this third party library so that the default search path can find the library file. The root (/) is considered as usr (/usr) path – so you cannot create one either. The problem is there’s no /usr directory psychically.
In MinGW, the MSYS is a collection of GNU utilities such as bash, make, gawk and grep to allow building of applications. While porting applications under MinGW, functions not native to Win32 such as fork(), mmap(), or ioctl() will need to be reimplemented into Win32 equivalents for the application to function properly. MinGW on the other hand, provides functions supplied by the Win32 API.
MinGW includes some basic standard libraries for interacting with the Windows operating system, but as with the normal standard libraries included in the GNU compiler collection these don’t impose licensing restrictions on software you have created.īest option to port Linux codes to Windows native. It may be possible in some cases to use MinGW to compile something that was intended for compiling with Microsoft Visual C++, with the right libraries and in some cases with other modifications. MinGW is essentially an alternative to the Microsoft Visual C++ compiler and its associated linking/make tools.
dll files, though you could also cross-compile with the right settings, since you are basically using the GNU compiler tools suite.
By default, code compiled in MinGW’s GCC will compile to a native Windows X86 target, including.
MinGW does not have a Unix emulation layer like Cygwin. It does not attempt to emulate or provide comprehensive compatibility with Unix, but instead it provides the minimum necessary environment to use GCC (the GNU compiler) and a small number of other tools on Windows. MinGW is simply a Windows port of the GNU compiler tools, such as GCC, Make, Bash, and so on.
It consists of two parts: A DLL (cygwin1.dll) which acts as a Linux API emulation layer providing substantial Linux API functionality and a collection of tools which provide Linux look and feel. If you distribute it along with the Cygwin runtime library (cygwin1.dll), you have to compile with its open source license.Ĭygwin applications by principle are not considered a “Native Win32 application” because it relies on the Cygwin POSIX Emulation DLL or cygwin1.dll for Posix functions and does not use win32 functions directly.įrom Cygwin’s website: Cygwin is a Linux-like environment for Windows. You can compile codes in Cygwin, and it will run on Cygwin. Your application can use Unix feature such as pipes, Unix-style file and directory access, and so forth, and it can be compiled with Cygwin which will act as a compatibility layer around your application, so that many of those Unix-specific paradigms can continue to be used. CygwinĬygwin makes porting Unix-based applications to Windows much easier, by emulating many of the small details that Unix-based operating systems provide, and are documented by the POSIX standards. This blog shows some differences among three alteratives to compile open source codes in Windows.