Skip to content

Conversation

@Theldus
Copy link
Contributor

@Theldus Theldus commented Aug 30, 2023

Summary

This PR fixes a build issue that occurred while building with GDB stub support (-DGDBSTUB=ON) enabled, as can be seen in:

$ cmake -DGDBSTUB=ON ..
...
$ make
...
/home/david/86Box/src/gdbstub.c: In function ‘gdbstub_client_write_reg’:
/home/david/86Box/src/gdbstub.c:551:14: error: ‘GDB_REG_FS_BASE’ undeclared (first use in this function); did you mean ‘GDB_REG_FSTAT’?
  551 |         case GDB_REG_FS_BASE ... GDB_REG_GS_BASE:
      |              ^~~~~~~~~~~~~~~
      |              GDB_REG_FSTAT

The issue was introduced in commit 565421a, which commented out the GDB_REG_FS_BASE and GDB_REG_GS_BASE registers, but did not remove the code snippets that referenced them in gdbstub_client_write_reg(). This PR comments out those code snippets as well.

Additionally, I've removed the fs_base and gs_base registers from the XML file, to ensure the correct numbering of the registers for the GDB.


Note: I have three other small patches for gdbstub.c, should I submit them in separate PRs or is one enough?

Checklist

References

This commit fixes a build issue that occurred when compiling with
GDBSTUB support (-DGDBSTUB=ON). The issue was introduced in commit
565421a, which commented out the GDB_REG_FS_BASE and GDB_REG_GS_BASE
registers, but did not remove the code snippets that referenced them
in gdbstub_client_write_reg(). This commit comments out those code
snippets as well.

Additionally, this commit removes the fs_base and gs_base registers
from the XML file, to ensure the correct numbering of the registers
for the GDB.
@OBattler OBattler merged commit b6713dc into 86Box:master Aug 31, 2023
@OBattler
Copy link
Member

I recommend making another PR witth those patches.

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

Successfully merging this pull request may close these issues.

2 participants