Having trouble installing bochs with gdb stub

I’m trying to get bochs running with the gdb stub feature installed, so that I can debug a kernel I’m writing from gdb. First, I tried the bochs-gdb package on the AUR, but that complained that error: Linux kernel 2.4, 2.6 or 3.x is required for PCI host device mapping. So then, I tried downloading the bochs source and configuring the makefile with:

./configure --enable-gdb-stub --enable-pci --enable-cpu-level=6

But after doing that and then building bochs, I get the error:

Event type: PANIC
Device: [XGUI  ]
Message: Unknown x11 option 'gui_debug'

So, how can I get this working? On the Bochs website it says to do pretty much just what I did, and that’s not working.

bochs-gdbAUR 2.6.8 was released in 2015. The current version is 2.6.11 released last week.

I just submitted a request to orphan the package and it was auto-accepted, feel free to adopt it and update it.

1 Like
2 Likes

Thanks for the suggestion, I tried something similar to this earlier but it led to the same

Unkown x11 option `gui_debug`

error that I described in my question.

Okay, so I’ve solved it, and feel like a bit of an idiot, but I’m posting the solution here in case someone else misses it as I did. When bochs said

Event type: PANIC
Device: [XGUI  ]
Message: Unknown x11 option 'gui_debug'

A PANIC has occurred.  Do you want to:
  cont       - continue execution
  alwayscont - continue execution, and don't ask again.
               This affects only PANIC events from device [XGUI  ]
  die        - stop execution now
  abort      - dump core 
  debug      - hand control to gdb
Choose one of the actions above: [die] cont

I took that to mean it crashed. But, it hadn’t crashed. If I simply type cont, it progresses and allows me to connect to it in gdb.

1 Like

Updating the package sounds fun, I’ll look into that