Example code

View code examples at github.

Example invocations

launch gdbgui


set the inferior program, pass argument, set a breakpoint at main

gdbgui "./myprogram myarg -myflag"

alternate way to do the same thing (note the lack of quotes)

gdbgui --args ./myprogram myarg command -myflag

use gdb binary not on your $PATH

gdbgui -g build/mygdb

run on port 8080 instead of the default port

gdbgui --port 8080

Pass arbitrary arguments directly to gdb when it is launched

gdbgui --gdb-args="-x gdbcmds.txt"

run on a server and host on Accessible to the outside world as long as port 80 is not blocked.

gdbgui -r

Same as previous but will prompt for a username and password

gdbgui -r --auth

Same as previous but with encrypted https connection.
openssl req -newkey rsa:2048 -nodes -keyout private.key -x509 -days 365 -out host.cert
gdbgui -r --auth --key private.key --cert host.cert

Use Mozilla's record and replay debugging supplement to gdb

gdbgui --rr

Use recording other than the most recent one


Don't automatically open the browser when launching

gdbgui -n

Think something's missing? Create an issue on GitHub.