[VSCode] [C++] | Der Compiler gibt mir Error “.Exe does not exist”?
Guten Tag!
Das Problem handelt sich um “VisualCodeStudio” Abk. “VSCode”, mit der Sprache C++.
Ich habe VSCode bisher kaum verwendet und kenne mich daher nur wenig mit dem Programm aus.
Hauptsächlich habe ich das Programm “Community Edition – PyCharm” für Python und “Community Edition – CLion” für C++ genutzt. Da die Community Edition von CLion nicht mehr unterstützt wird, wollte ich auf VSCode umsteigen.
Jedoch gibt mir der Compiler von “VSCode” einige Probleme. (sehe Bild)
- Die Installation von Msys2 war erfolgreich (über CMD überprüft)
- Die Installation von MinGW war ebenfalls erfolgreich (über CMD überprüft)
- Path wurde correct in “Enviroment Variables” hinzugefügt
- Auch die C++-Erweiterung wurde korrekt installiert.
(Note: Ich habe Msys2 deinstalliert, um MinGW zu testen.)
Trotzdem erhalte ich immer den selben Fehler. Hat jemand eine Lösung?
Would appreciate any help!
MfG
With your current build, the standard library is not included, so there is a build error.
Use g++.exe instead of the gcc.exe to compile, because it automatically sets a corresponding link.
To configure the g++.exe as a standard, you need the file (or file path) in tasks.json (Tasks > command) indicate. There you can also (in args-Array) Put compiler flags if you need it.
Make sure that the newly set path is used when compiling in the console.
Thank you!!!!
He helped me a lot!
Looks like the C++ libraries are not integrated. With the clickibunti I don’t know myself, but in my bash I’ll bring the C++ compiler g++ on. With gcc I only start the C compiler and get comparable error messages from the linker.
See if you find an option to the language used somewhere in the IDE.
Thanks for the answer!
Has helped me understand g++ and gcc a little more!