Every frontend repeated the same target wiring (glob sources minus main.cpp → essim_<name> lib linking essim_core; essim exe from main.cpp linking the lib + essim_frontend; RUNTIME_OUTPUT_DIRECTORY=build/). Move it into a reusable helper cmake/EssimFrontend.cmake::essim_add_frontend(name LIBS ...), included once at the top level. The tui CMakeLists now just fetches FTXUI and calls essim_add_frontend(tui LIBS ftxui::screen ftxui::dom ftxui::component). A new frontend's CMakeLists is its toolkit setup + one call. No behaviour change; binary stays ./build/essim, tests green. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
1.3 KiB
1.3 KiB