image thumbnail

MATLAB Support for MinGW-w64 C/C++ Compiler

Install the MinGW-w64 C/C++ compiler for Windows

596.6K Downloads

Updated 10 Mar 2021

Editor's Note: Popular File 2016 2017 2018 2019 2020

This support package is currently unable to download third-party software for MATLAB R2017a and earlier versions. To install MinGW, complete the workaround instructions in the Bug Report, then return to this page and follow the instructions for R2017b and later.

MATLAB R2017b and later versions are unaffected.

MinGW-w64 is a compiler suite for Windows based on the GNU tool chain. It includes a GCC compiler and related tools for compiling C and C++ applications for Windows. C and C++ applications compiled with MinGW-w64 GCC can be called from MATLAB using MEX. This GCC compiler can also be helpful for other MathWorks products that require a C or C++ compiler.

Instructions for R2015b, R2016a, R2016b, and R2017a:
Complete the workaround instructions in the Bug Report, then follow the instructions, below, for R2017b and later.

Instructions for R2017b and later:
Select the download button, above, then double click on the file or drag it into the MATLAB Command Window to install.

FAQ: This link provides answers to some frequently asked questions.
https://www.mathworks.com/matlabcentral/answers/311290-faq-how-do-i-install-the-mingw-compiler#answer_242526?s_tid=prof_contriblnk

This Add-On installs one of the following versions of MinGW GCC based on your version of MATLAB:
MATLAB version__________MinGW version__For more information
R2015b through R2017a____GCC 4.9.2_____http://tdm-gcc.tdragon.net
R2017b and R2018a_______GCC 5.3______ http://mingw-w64.org
R2018b and later__________GCC 6.3______http://mingw-w64.org

See additional information on installing this compiler at:
http://www.mathworks.com/help/matlab/matlab_external/install-mingw-support-package.html

Learn more about other compilers supported by MathWorks Products at:
https://www.mathworks.com/support/requirements/supported-compilers.html

If you are having difficulty installing, please contact Technical Support or see MATLAB Answers:
https://www.mathworks.com/support/contact_us.html
https://www.mathworks.com/matlabcentral/answers/?term=mingw

MATLAB Release Compatibility
Created with R2015b
Compatible with R2015b to R2021a
Platform Compatibility
Windows macOS Linux
Acknowledgements

Inspired: YOKOGAWA GM10 communication interface

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!