Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue in make debug #8

Closed
gnaneshraj14 opened this issue Sep 20, 2023 · 4 comments
Closed

Issue in make debug #8

gnaneshraj14 opened this issue Sep 20, 2023 · 4 comments

Comments

@gnaneshraj14
Copy link

issue_exit_debug

may be I failed to exit debug or don't understand what happend not able to make debug now.

@gnaneshraj14
Copy link
Author

BTW I am on windows platform. The first time is entered make debug it was connected to port. Then as usual I opened new terminal and used the gdb and then quit it from the same terminal. But on the previous one where it was connected to port did exit. any suggestions on how to exit it on windows?

@gnaneshraj14
Copy link
Author

There is a big problem related to using GDB on windows machine. When we do make debug on Terminal1 and then make gdb on Terminal 2, after using GDB in terminal 2 we execute quit command. Then the debug process should be terminated and then in terminal 1 with the command ctrl+c should work to terminate make debug but it doesn’t happen so. If we try to kill the process of qemu by other processes it will crash and with next instance of opening Docker fails it reports error. And now Docker should be uninstalled and reinstalled to run all the process again. This certainly not good way to do. Can you please suggest what can be done here to end the make debug on Terminal 1 without any issues.

@streetdogg
Copy link
Contributor

@ gnaneshraj14: Thank you for reporting the issue! Can I request you to try the following?

Then the debug process should be terminated and then in terminal 1 with the command ctrl+c should work to terminate make debug but it doesn’t happen so.

Use ctrl+a followed by x key to exit the qemu gracefully. You should the prints as below:

c-ninja@c-ninja-linux ~/Documents/test
 % make debug
qemu-system-riscv32 -S -M virt -nographic -bios none -kernel main.elf -gdb tcp::1234
QEMU: Terminated

Exiting QEMU correctly will ensure that the 1234 port is freed up to be used in the follow-up launches. Once we are in the docker container environment the underlying platform (mac, windows, linux etc) should not be a problem.

Please let me know if this helped :)

@gnaneshraj14
Copy link
Author

@streetdogg It did work thank you for your suggestions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants