3

I'm getting MinGW from https://sourceforge.net/projects/mingw/files/ which I need for mingw32-gcc.exe for compiling LuaRocks packages, so I can't really use Mingw-w64.

The latest version from the Installation Manager seems to be on 6.3.0, but I also previously had 8.2.0 from around 2019. Why does it give me an older version?

PS C:\Users\Ketho> mingw32-gcc --version
    mingw32-gcc.exe (MinGW.org GCC-6.3.0-1) 6.3.0
    Copyright (C) 2016 Free Software Foundation, Inc.
PS C:\Users\Ketho> mingw32-gcc --version
    mingw32-gcc.exe (MinGW.org GCC-8.2.0-3) 8.2.0
    Copyright (C) 2018 Free Software Foundation, Inc.

Ketho
  • 508
  • 3
  • 11

1 Answers1

4

The MinGW project seems to have stayed behind somewhat on development.

But in the meantime the MinGW-w64 project, which is a fork of the original MinGW, has been actively developed recently. It supports both Windows 32-bit and Windows 64-bit.

I recommend switching to MinGW-w64 entirely.

The latest GCC compiler built against the latest MinGW-w64 can be downloaded from https://winlibs.com/ as a standalone package.

If you use MSYS2 shell you can also install MinGW-w64 via its package manager pacman.

Brecht Sanders
  • 6,215
  • 1
  • 16
  • 40
  • (edit) This doesn't answer the apparent rollback from the original MinGW project to 6.3.0 though. Just a namechange from `gcc.exe` or `i686-w64-mingw32-gcc.exe` from the w64 project to `mingw32-gcc.exe` did work for my 32-bit LuaRocks setup so I switched to (WinLibs) MinGW-w64, thanks! – Ketho Jul 14 '21 at 15:15
  • 1
    Normally gcc is preceded with the entire host/platform triplet (in this case `i686-w64-mingw32`). Apparently the old MinGW didn't do it that way and used `mingw32-gcc.exe` instead. This version only supported 32-bit Windows and cross-compilation was not supported either. – Brecht Sanders Jun 01 '22 at 12:30