Repository navigation
Description
Version
codebase-memory-mcp dev
Platform
Linux (x64)
Install channel
Built from source
Binary variant
standard
What happened, and what did you expect?
clone repo, run scripts/build.sh
got build errors
some related to -Werror=discarded-qualifiers
some related to a missing include needed for recent libgit
gcc (GCC) 16.1.1 20260430
pkg-config --modversion libgit2 1.9.4
I think it is, because gcc 16.1.1 is picky about discarded qualifiers by default.
these changes let it build
❯ git diff
diff --git a/internal/cbm/cbm.c b/internal/cbm/cbm.c
index d611f18..81bc99d 100644
--- a/internal/cbm/cbm.c
+++ b/internal/cbm/cbm.c
@@ -21,6 +21,7 @@
#include "sqlite3.h" // sqlite3_mem_methods, sqlite3_config, SQLITE_CONFIG_MALLOC — bind sqlite to mimalloc
#if defined(HAVE_LIBGIT2)
#include <git2.h> // git_allocator, git_libgit2_opts, GIT_OPT_SET_ALLOCATOR — bind libgit2 to mimalloc
+#include <git2/sys/alloc.h>
#endif
#endif
#include <stdint.h> // uint32_t, uint64_t, int64_t
diff --git a/src/cli/cli.c b/src/cli/cli.c
index 4228dba..8219da6 100644
--- a/src/cli/cli.c
+++ b/src/cli/cli.c
@@ -1457,12 +1457,12 @@ int cbm_remove_codex_mcp(const char config_path) {
/ Splice out an existing [CODEX_HOOK_BEGIN .. CODEX_HOOK_END] block (inclusive,
- plus a leading newline). Returns a newly-malloc'd string the caller frees, or
- NULL if no block was present (content is left untouched). */
-static char *codex_hook_strip(const char *content) {
- char *begin = strstr(content, CODEX_HOOK_BEGIN);
+static char *codex_hook_strip(const char *content) {
- const char *begin = strstr(content, CODEX_HOOK_BEGIN);
if (!begin) {
return NULL;
}
- char *end = strstr(begin, CODEX_HOOK_END);
- const char *end = strstr(begin, CODEX_HOOK_END);
Reproduction
reproducible on vanilla cachyos, just clone the repo and try to build.
Logs
Project scale (if relevant)
No response
Confirmations
- I searched existing issues and this is not a duplicate.
- My reproduction uses shareable code (a dummy snippet or a public OSS repository), not proprietary code.
Activity
DeusData commentedon Jun 23, 2026
Hey, yes we are currently in a "in between release" phase. It's currently not all verified to be working. Please use the release binaries from 0.8.1 or check out to the commit version listed in the release :)
haarer commentedon Jun 23, 2026
DeusData commentedon Jun 23, 2026
@haarer alright will have a look, thx for reporting
DeusData commentedon Jun 26, 2026
Thanks for the persistence on this — and you were right to push back. v0.8.1 is a
release tag, not an in-between state. Apologies for the confusion.
Your diff looks directionally correct. Before we merge, we want to confirm the
<git2/sys/alloc.h>path is stable across distros and that no older toolchain breakswith the
const char *changes. Could you share:Instructions for your coding agent:
The
findoutput (step 3) confirminggit2/sys/alloc.hexists at that path is themost important piece — it determines whether we can use the include unconditionally or
need a configure-time check.
Thanks for the patch and for the detailed context!
github-actions commentedon Jun 26, 2026
Thanks for the report! To move this forward we need a bit more so we can reproduce it ourselves:
codebase-memory-mcp --versionyou're onOnce that's here we'll pick it straight back up. Heads-up: issues left
awaiting-reporterare automatically closed after a few weeks of silence, but a comment reopens the door anytime.DeusData commentedon Sep 25, 2026
Thank you, Alexander, for the patch and for pushing back; you were right that v0.8.1 was a proper tag! Both problems are fixed as of v0.9.0: the const-qualifier errors in c13a9db (#588) and the libgit2 include in 03a0840. The optional libgit2 dependency was later dropped entirely, so that include is gone. Could you confirm that a build from the v0.11.0 tag succeeds with your gcc 16.1.1? If we don't hear back, we'll close this as fixed.
github-actions commentedon Sep 26, 2026
Thanks for the report! To move this forward we need a bit more so we can reproduce it ourselves:
codebase-memory-mcp --versionyou're onOnce that's here we'll pick it straight back up. Heads-up: issues left
awaiting-reporterare automatically closed after a few weeks of silence, but a comment reopens the door anytime.github-actions commentedon Oct 18, 2026
This issue has been waiting on more information for 21 days (a version, exact steps, or a public repro), so it's now marked
stale. It will not be closed automatically — a maintainer reviews stale issues by hand. Adding a comment with the details clears the label and puts it straight back in the queue. We're happy to pick it back up the moment we can reproduce it.DeusData commentedon Oct 19, 2026
Thank you again for the CachyOS patch and correction about the release tag. Checking back on the September request: does building a newer tagged release succeed with your GCC version? I have no fresh toolchain result to add, and silence alone will not be treated as your confirmation.
haarer commentedon Oct 20, 2026
i tested on the tag v0.12.1 and on head and it builds fine on cachyos now.
so it is fixed for me.
thank you