Two stale-build traps cost UI test runs:
- The generated C did not depend on its defines, so building with
KRYON_TEST_DRIVER after a plain build kept the old C and the UI tests
stopped with "this build has no test driver". The defines are now
recorded in build/kryon/generated-defines.txt, rewritten only when they
change, and the generation depends on it.
- A compile killed part way, as the memory guard does, left an empty
object newer than its source; make then skipped it and the link failed
on undefined symbols. Each object is now compiled to a .part file and
moved into place.
Local tests: make native with and without KRYON_TEST_DRIVER regenerates
once and a repeat build regenerates nothing; desktop-window-test passes
on a private Xvfb.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
The native build handed every generated module, SQLite, and the embedded
assets to one compiler call and wiped and re-touched the generated tree
first, so any change recompiled everything on one core. Generation now
updates the tree in place and prunes stale files, and each source builds
its own object with header dependencies, so rebuilds recompile only
what changed and use every core.