How to use MinGW’s gcc compiler when installing Python package using Pip?

  • install MinGW with C++ Compiler option checked
  • add C:\MinGW\bin to your PATH
  • in PYTHONPATH\Lib\distutils, create a file distutils.cfg and add these lines:
[build]
compiler=mingw32

Leave a Comment