The MinGW from http://www.mingw.org/ does only support gcc 32 bit (host and target). The independent minGW-w64 project provides support for 64 bit, and also supports a much larger part of the Windows API. The MinGW-w64 project however does not provide official binary builds: These can be grabbed either from the personal build directories of the developers (the most popular being rubenvb), or from associated but independent projects like tdm-gcc or mingw-builds or msys2.

Source: http://wiki.qt.io/MinGW-64-bit

Answer from KindDragon on Stack Overflow
🌐
Reddit
reddit.com › r/cpp_questions › q: can some one explain the difference between mingw and mingw-w64 and the difference between mingw and cygwin?
r/cpp_questions on Reddit: Q: Can some one explain the difference between MinGW and MinGW-w64 and the difference between MinGW and Cygwin?
June 13, 2015 -

Can some one explain the difference between MinGW and MinGW-w64 and the difference between MinGW and Cygwin?

I think mingw_w64 is 64 bit but it also fixes some issues in mingw if i rember correctly.

I have no idea what the difference is between mingw and cygwin because all the explenations are to hard for me to follow.

Top answer
1 of 1
12
MinGW stands for minimalist GNU for Windows. It's a direct port of gcc and binutils to Windows, using the operating system's version of the Microsoft C runtime (msvcrt.dll). There are some enhancements for added C99 compatibility (as the MS runtime is downright awful in that regard) but more or less it's meant to be minimal — no additional compatibility layers. It's typical to refer to things built with MinGW as 'native', in that the runtime they require is part of the OS, so they are standalone. MinGW-w64 is a fork of the MinGW project that was created because someone felt the progress toward supporting 64 bit Windows was going too slow. They have different policies regarding the reimplementation of headers. One of the problems both projects face is that they have to reinvent the entire Win32 API header set, which is a daunting task. The headers available from MS use MSVC-specific features and won't work with gcc. That means that all Win32 API functions, types, enums, structs, macros, import libraries, GUIDs, etc. have to be meticulously recreated from the public documentation available at MSDN. I'm not sure of the exact policy differences between the two projects, but I think the MinGW-w64 project is a lot more proactive about it, whereas the MinGW project is more reactionary. The MinGW-w64 project offers more optional C99 compatibility libraries as well, to help with porting. MinGW-w64 supports both 32 bit and 64 bit hosts and targets. There are also various third parties who package their own customized MinGW and/or MinGW-w64 bundles, such as mingw-builds, TDM, and nuwen.net. It's important to pay attention to the details of these things, because there are a lot of degrees of freedom of customization. For example, if you want C++ threads to work, then your distro must bundle pthreads-win32, a compatibility layer between POSIX threads (the only kind supported by libstdc++) and Win32 threads. And which form of exception handling do you want? SEH, DWARF, or SJLJ? And do you want the gcc runtime library (libgcc) and/or libstdc++ to be shared or static by default? And do you want any of those optional C99 compatibility layers of MinGW-w64 enabled or not? Cygwin is a completely different project, which implements its own C runtime, based on Newlib but with significant additions. It aims to provide full POSIX compatibility at the source level, which means many Unix programs can be compiled directly without any porting required, but of course the resulting programs require the Cygwin runtime (cygwin1.dll). It's also a distribution of packages compiled in this way. Cygwin supports both 32 bit and 64 bit hosts and targets, and includes a MinGW cross-toolchain so that it can be used as a host system to cross-compile native binaries as well. MSYS is a fork of an ancient and buggy version of Cygwin. It adds some changes to how argument processing in the runtime works. Basically, when invoking native programs (i.e. those that don't use the MSYS runtime), path translation from POSIX to Win32 is performed. MSYS is also a distribution of common Unix utilities built against the MSYS runtime. Because of the path translation change, these utilities can be used with native toolchains and other native win32 tools seamlessly. Some people prefer that to Cygwin, which prefers that all paths remain as POSIX paths an invoking a non-Cygwin binary requires manual translation. In other words, Cygwin binaries/packages tend to work together as a whole, but don't play well with outsiders. I personally find Cygwin to be indispensable for any Windows computer. It provides a fully integrated Unix environment, and unlike MSYS, the programs are all up to date, not ancient versions. Some people call Cygwin bloated, but I have no earthly idea where they're getting that from; a typical Cygwin install uses less disk space than a typical MinGW install due to the fact that everything in Cygwin is split out into individual packages and you don't have to install stuff you don't want, and the fact that everything in Cygwin uses shared libraries.
Discussions

Why do MinGW binaries have such complicated names? (e.g. i686-w64-mingw32-...) - Stack Overflow
What, then, do w64 and mingw32 signify in the names of these binaries? Would there be any meaning to a w32 binary, e.g. i686-w32-mingw32-gcc? More on stackoverflow.com
🌐 stackoverflow.com
c++ - What is the difference between MinGW, MinGW-w64 and MinGW-builds? - Stack Overflow
What are the differences between MinGW, MinGW-w64 and MinGW-builds? And which one should I use to compile c++ 11 source code with the Eclipse IDE on a Windows 8 machine? More on stackoverflow.com
🌐 stackoverflow.com
Setting up Win32 for Mingw - C++ Forum
The original MinGW project is dead (no updates in years, website is down). Mingw-w64 has taken over. MinGW-w64 does not need or use separate Windows SDK. It already comes with all the header files (e.g. Windows.h) and associated import libraries that you'll need to use the Win32 API. More on cplusplus.com
🌐 cplusplus.com
November 9, 2022
What is the difference between different mingw versions?
Go here: ( https://nuwen.net/mingw.html ). Posix is a standard for Unix systems. At one time Windows used to provide a Posix compatibility environment where one could run console-based Posix programs. Today, to use Unix tools in Windows you can simply run Unix (usually Ubuntu) in Windows via the Windows Subsystem for Linux, WSL, and though I haven't used the ability it reportedly now supports running also GUI applications. SJLJ, DWARF and SEH are three different ways to implement C++ exception handling . As far as I'm aware 64-bit versions of g++ only use a scheme based on SEH, Windows' own low level exception handling, so the differences are mainly of historic interest. Well, unless you have to use a 32-bit version, in which case go for SJLJ as most generally safe, though not fastest. More on reddit.com
🌐 r/cpp_questions
7
2
October 18, 2022

The MinGW from http://www.mingw.org/ does only support gcc 32 bit (host and target). The independent minGW-w64 project provides support for 64 bit, and also supports a much larger part of the Windows API. The MinGW-w64 project however does not provide official binary builds: These can be grabbed either from the personal build directories of the developers (the most popular being rubenvb), or from associated but independent projects like tdm-gcc or mingw-builds or msys2.

Source: http://wiki.qt.io/MinGW-64-bit

Answer from KindDragon on Stack Overflow
🌐
Wikipedia
en.wikipedia.org › wiki › Mingw-w64
Mingw-w64 - Wikipedia
August 18, 2026 - I have since avoided looking at the mingw-w64 sources to avoid any taint of copyright abuse. I could well be wrong, but I would rather be safe than jeopardise the future of the mingw32, which has tried to maintain a "clean-room" ethic during its development. ↑ Marshall, Keith (19 July 2009). "Re: Harmonizing mingwrt / w32api ...
🌐
Gentoo Wiki
wiki.gentoo.org › wiki › Mingw
MinGW - Gentoo wiki
MinGW (historically MinGW32) is a toolchain that provides a native GCC-based environment for compiling Windows binaries. It can also be used in cross-compilation setups to build binaries on other operating systems. MinGW-w64 is a fork of MinGW that adds support for 64-bit Windows executables.
🌐
SourceForge
sourceforge.net › home › browse › mingw-w64 - for 32 and 64 bit windows › wiki2
MinGW-w64 - for 32 and 64 bit Windows / Wiki2 / GeneralUsageInstructions
TDM-GCC: TDM, who also catered updated GCC installers for mingw.org, supports a mingw-w64 toolchain. Be sure to read the Getting Started page. This is of course not usable for cross-compilation. Please understand TDM uses nonstandard patching that makes his builds binary incompatible with all other builds without these patches. For linux, see below. TDM-GCC comes with an easy installer, please use that. The other builds are quite straightforward to set up: extract the toolchain to a directory: 32-bit mingw-w32: eg C:\mingw32 so that C:\mingw32\bin contains i686-w64-mingw32-gcc.exe 64-bit mingw-w64: eg C:\mingw64 so that C:\mingw64\bin contains x86_64-w64-mingw32-gcc.exe
Find elsewhere
🌐
SourceForge
sourceforge.net › projects › mingw-w64
MinGW-w64 - for 32 and 64 bit Windows download | SourceForge.net
October 11, 2026 - Download MinGW-w64 - for 32 and 64 bit Windows for free. A complete runtime environment for gcc. The mingw-w64 project is a complete runtime environment for gcc to support binaries native to Windows 64-bit and 32-bit operating systems.
🌐
Cplusplus
cplusplus.com › forum › windows › 285056
Setting up Win32 for Mingw - C++ Forum
November 9, 2022 - The original MinGW project is dead (no updates in years, website is down). Mingw-w64 has taken over. MinGW-w64 does not need or use separate Windows SDK. It already comes with all the header files (e.g. Windows.h) and associated import libraries that you'll need to use the Win32 API.
🌐
Reddit
reddit.com › r/cpp_questions › what is the difference between different mingw versions?
r/cpp_questions on Reddit: What is the difference between different mingw versions?
October 18, 2022 -

I am new to windows and cpp. I wanted to install gcc/g++ and found out that I need to install mingw but there are so many variations I have no idea what to select. what is the difference between posix and win32, sjij and seh? will there be any compatibility issues if I select just at random ? I tried searching online but the questions and answers were a bit old. Does it make no difference in modern systems or modern versions ?

another question I have is about msvc. I don't want to install it because it's too large. but is it worth it like if I use msvc I wouldn't have to worry about these(variations in mingw) at all or something like that ?
I am still not sure about the usage of gcc, I'll mostly tryout some game dev, GUI apps etc.

🌐
PySDL
discourse.libsdl.org › sdl development
does x86_64-w64-mingw64 exist? - SDL Development - Simple Directmedia Layer
December 12, 2024 - My chatGPT 3.5 turbo says about x86_64-w64-mingw32 this: “-mingw32” means it will create 32-bit project and “x86_64-w64” means it is made for creating projects using 64-bit windows (the problem is I dont have “x86_64-w64-mingw64” ...
🌐
Mingwpy
mingwpy.github.io › background-mingw.html
MinGW-w64 — mingwpy 0.1 documentation
To date, numpy and scipy have used versions of the mingw compilers to create 32-bit binary distributions on Windows. mingw-w64 has some major advantages over mingw, including:
🌐
GitHub
github.com › msys2 › MINGW-packages › issues › 23473
What's the point for mingw32? · Issue #23473 · msys2/MINGW-packages · GitHub
February 22, 2025 - Perhaps, by building in msys, it's now an msys binary, not a regular win32 binary. Looks like this won't work. Why wasn't regular mingw64 built with support for -m32? I don't use any libs that come preinstalled with mingw64, all my own code, no dependencies. ... The gcc libs are in /opt/lib/gcc/i686-w64-mingw32/14.2.0/ in this case.
🌐
Microsoft Learn
learn.microsoft.com › en-us › vcpkg › users › platforms › mingw
Mingw-w64 | Microsoft Learn
You can use the vcpkg mingw community triplets with toolchains on non-Windows computers to cross-compile software to be run on Windows. Many Linux distributions offer such toolchains in optional packages with a mingw-w64 suffix or prefix.
🌐
GitHub
github.com › rust-lang › rust › issues › 8996
Use Mingw-w64 for Win32 · Issue #8996 · rust-lang/rust · GitHub
September 5, 2013 - However mingw does not support win64 (#1237), so we have to use mingw-w64 (or msvc: #1768). Although mingw and mingw-w64 looks similar, implementations differ: we have issues due to mingw which are already solved on mingw-w64.
🌐
Qt Forum
forum.qt.io › home › qt development › general and desktop › how to distinguish between mingw32 and mingw64
How to distinguish between minGW32 and minGW64 | Qt Forum
January 14, 2020 - Hi, I just found the ?undocumented? variable 'QT_ARCH' which has the value 'i386' for 32Bit MinGW builds and 'x86_64' for 64Bit MinGW builds.
🌐
mingw-w64
mingw-w64.org › downloads
Pre-built Toolchains - mingw-w64
A complete runtime environment for GCC & LLVM for 32-bit (x86), 64-bit (x64), and ARM64 Windows
🌐
Hacker News
news.ycombinator.com › item
I'm guessing it was because of pressure from Mingw. A few years ago, Cygwin was ... | Hacker News
June 24, 2016 - You should use mingw-w64 when you can modify your sources (eg. with lots of #ifdef WIN32) to call Win32 APIs, OR if you are using a framework like glib2 which handles those differences for you · In Fedora we have both Cygwin and the Fedora cross-compiler project which packages mingw-w64 compiler ...
🌐
mingw-w64
mingw-w64.org
Introduction - mingw-w64
A complete runtime environment for GCC & LLVM for 32-bit (x86), 64-bit (x64), and ARM64 Windows