mirror of
https://github.com/ALLFATHER-BV/wadamesh.git
synced 2026-11-10 11:37:17 +00:00
beta_93 pinned the Heltec V4 to the beta_92 .lang files because the full table no longer fit. lang_reach.py now works out which keys any source can look up: a .lang key is kept when it equals a C string literal anywhere in the sources (every #if branch, adjacent literals joined, LV_SYMBOL_*/UI_ICON_* and other string macros expanded, escapes decoded as GCC does), or that literal with TR()'s glyph prefix stripped, or a string in any Lua app. 1818 of 1925 keys survive; the 107 dropped look unused (old dropdown strings, texts the source has reworded). The trimmed live table is 15.5 KB smaller than the pinned one (V4 4,025,365 B used, 37.9 KB free) and carries every translation added since beta_92. Guards: the generator refuses to trim when an input is missing (lv_symbol_def.h, UITask.cpp, or under 80% kept) and leaves the header alone; after linking the V4, --check-objects reads the strings the compiler emitted and fails the build if a translated key among them was dropped (proved by dropping a live one). The pre-build hook regenerates on source changes too, and the header is only rewritten when its content changes. The pinned copy is gone (git history). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>