Skip to content

Commit 095d992

Browse files
zahclaude
andcommitted
build: build the io-mon shim with a writable nimcache (read-only source)
The package build and dev shell consume io-mon as a Nix flake input (a read-only store path), but io-mon's build_shim.sh wrote its nimcache to a path relative to its own source tree, so `mkdir build`/the nim cache write failed with "Permission denied" / "Read-only file system" — breaking `nix build .#default`, the `repro` bootstrap, and `just test`. Pass IO_MON_SHIM_NIMCACHE_DIR (new, absolute, under reprobuild's writable build/) alongside the existing IO_MON_SHIM_OUT_DIR so the shim writes nothing into io-mon's source; bump io-mon-src to the release carrying that knob. Verified: `nix build .#default` now builds the shim (SuccessX) and proceeds to compile with no build-dir error. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
1 parent d5e9c02 commit 095d992

2 files changed

Lines changed: 8 additions & 3 deletions

File tree

flake.lock

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

scripts/build_apps.sh

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,12 @@ if [ ! -x "${io_mon_src}/scripts/build_shim.sh" ]; then
4444
echo "missing io-mon shim builder at ${io_mon_src}/scripts/build_shim.sh; set IO_MON_SRC" >&2
4545
exit 2
4646
fi
47+
# Point BOTH the shim's output dir and its nimcache at reprobuild's own
48+
# (writable) build tree. io-mon's source is read-only when it comes from a Nix
49+
# flake input / store path (the package build + dev shell), so the shim must not
50+
# write its nimcache into its own source — pass an absolute writable dir.
4751
IO_MON_SHIM_OUT_DIR="$(pwd)/build/lib" \
52+
IO_MON_SHIM_NIMCACHE_DIR="$(pwd)/build/nimcache/io-mon-shim" \
4853
IO_MON_BUILD_MODE="${REPROBUILD_BUILD_MODE:-debug}" \
4954
bash "${io_mon_src}/scripts/build_shim.sh"
5055

0 commit comments

Comments
 (0)