I downloaded MingGW x64 as specified here: https://code.visualstudio.com/docs/languages/cpp
then added C:\msys64\mingw64\bin
to path
When opening the MSYS2 MINGW x64 app from the start button and checking the version, it seems to be working fine:
$ g++ --version
g++.exe (Rev3, Built by MSYS2 project) 12.1.0
Copyright (C) 2022 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
However, I'd like to include this into my visual studio workflow, but when checking for the compiler in the VS terminal, I get an error:
>>g++ --version
g++ : The term 'g++' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path
was included, verify that the path is correct and try again.
At line:1 char:1
+ g++ --version
+ ~~~
+ CategoryInfo : ObjectNotFound: (g++:String) [], CommandNotFoundException
+ FullyQualifiedErrorId : CommandNotFoundException
what could this be?