DEV Community

Discussion on: Setting Up C/C++ Development Environment in Visual Studio Code Using MinGW

Collapse
 
dyfet profile image
David Sugar

A more different approach is actually to use mingw as packaged in debian / ubuntu or fedora from wsl, which vsc supports rather well, rather than installing and running mingw on windows. If your using cmake, you can even use cpack to package the resulting binaries with a windows installer if you install nsis in debian / ubuntu wsl, too.

Collapse
 
mohosin2126 profile image
Md Mohosin Ali Shah

Thank you for sharing this alternative approach! Using MinGW within WSL (Windows Subsystem for Linux) indeed has its own advantages, especially when paired with tools like CMake and CPACK for packaging. It can provide a more Unix-like environment for development and streamline workflows that involve cross-platform compatibility or additional packaging requirements.

For beginners or those looking for a quick native Windows setup, my guide with the standalone MinGW installation might be a simpler starting point. However, for more advanced users or those already comfortable with WSL, your suggestion is definitely worth exploring.

I'll look into trying out WSL with MinGW and potentially adding it as an alternative setup method in future updates to the guide. Thanks again for the valuable input!