franneck94 / Vscode-C-Cpp-Runner

🚀 Compile, run and debug single or multiple C/C++ files with ease. 🚀
MIT License
53 stars 14 forks source link

gdb options #30

Closed n-zu closed 3 years ago

n-zu commented 3 years ago

I'm using the following line to debug in the terminal: gdb -q -s obj/kern/kernel -ex 'target remote 127.0.0.1:26000' -n -x .gdbinit

I couldn't figure out how to configure the options (-q -s) with the extension.

franneck94 commented 3 years ago

I guess it can be set with the setupCommands entry in the launch.json file (see here).

But i dont know if this works, your request is also more related to Microsoft's C/C++ extension since my extension just consumes their debugger. You may ask in their repository for help.

PS: You want to debug on a remote system, right? Wouldnt it be easier to connect VSCode via SSH to the remote and then use it as it was your standard PC?

n-zu commented 3 years ago

Thanks for the help ! sadly, it didn't work

You are right, sorry, got confused w/ the extensions. ill go ask there.

Yes, i want to debug a remote system. But I don't know if I can do that. It's complicated ( at least to me, I'm super confused ), but the 'program' is actually an operating system running on a VM. Something like JOS . I assume i cant connect, but then again, i don't quite get what I'm doing.

Once again thanks !