With HOST_TOOLS_ALL=y, the U-Boot host tools do not build on macOS. crc8.o does not compile and kwboot does not link. The kwboot link error also stops board builds such as turris_omnia.
Patch 1 links kwboot with the system libncurses, patch 2 removes an unused function warning in kwboot, and patch 3 keeps the sandbox asm/sections.h out of the host build of crc8.c. Tested on macOS 27.0.1 with Apple clang 21: tools-only with HOST_TOOLS_ALL=y and the host tools of turris_omnia_defconfig now build, and kwboot boots a Turris Omnia over UART. On Linux (Debian trixie, GCC 14.2) the same tools-only build and a full turris_omnia build still pass, and kwboot still links against libtinfo. Josef Schlehofer (3): tools: kwboot: Link with libncurses on macOS tools: kwboot: Define _is_within_tolerance() only with BOTHER lib: crc8: Do not include asm/sections.h in host builds lib/crc8.c | 4 +++- tools/Makefile | 5 +++++ tools/kwboot.c | 2 ++ 3 files changed, 10 insertions(+), 1 deletion(-) -- 2.54.0 (Apple Git-157)
