I an trying to understand how to enable the gcc debugger in vscode for the c++ track.
While working on the Log Levels example, I was able to solve it and build it locally. "make-C build" generates the binary and passes all the test. Now suppose I want to run this particular example under the gcc debugger, I followed the instructions in https://forum.exercism.org/t/local-testing-in-vsc-on-c-how-to-use-debug-features/7270, creating the launch.json and task.json but i still get an error.
* Executing task: C/C++: g++ build active file
Starting build...
/usr/bin/g++ -fdiagnostics-color=always -g /home/alejandrojginerd/exercism/cpp/log-levels/log_levels.cpp -o /home/alejandrojginerd/exercism/cpp/log-levels/log_levels
/usr/bin/ld: /usr/lib/gcc/x86_64-linux-gnu/11/../../../x86_64-linux-gnu/Scrt1.o: in function `_start':
(.text+0x1b): undefined reference to `main'
collect2: error: ld returned 1 exit status
Build finished with error(s).
* The terminal process failed to launch (exit code: -1).
* Terminal will be reused by tasks, press any key to close it.
it seems it is looking for the main() function witch does not exist but then why was it able to build it in the first place (not under gcc debugger). What am i missing?