While building on macos, seeing some build issue as below
clang++ -c -I.. -I../.. -I./.. -I./../.. -I../../instrument/stubs -I./../../instrument/stubs -fpascal-strings -fno-common -Wno-four-char-constants -Wno-unknown-pragmas -Dmacintosh -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -fpascal-strings -fno-common -Wno-four-char-constants -Wno-unknown-pragmas -Dmacintosh -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -I/opt/homebrew/Cellar/sdl2/2.32.0/include/SDL2 -D_THREAD_SAFE intel/corei5_lynnfield_750.cc -o intel/corei5_lynnfield_750.o
keymap.cc:133:28: error: use of undeclared identifier 'basename'
133 | if (strncmp(prefix2, basename(keymap_file), strlen(prefix2))) {
| ^
1 error generated.
This patch works for me
diff --git a/gui/keymap.cc b/gui/keymap.cc
index 3426b6b..7bf76d8 100644
--- a/gui/keymap.cc
+++ b/gui/keymap.cc
@@ -30,6 +30,10 @@
#include "gui.h"
#include "keymap.h"
+#if defined(__APPLE__)
+#include <libgen.h>
+#endif
+
// Table of bochs "BX_KEY_*" symbols
// the table must be in BX_KEY_* order
const char *bx_key_symbol[BX_KEY_NBKEYS] = {
Fixed in Bochs source tree on GitHub.