Files
aevolution/docs/engineering/CLIENT.md
T

52 lines
2.4 KiB
Markdown

# Native engineering client (M9.2)
This opens a resizable native window containing a static presentation fixture.
It does not simulate a world, connect to a server or implement cellular gameplay.
Contract: [client architecture](../architecture/CLIENT_ARCHITECTURE.md), ADR-0078.
## Build and run
After [explicit SDL preparation](CLIENT_DEPENDENCIES.md), in a compiler shell:
```sh
cmake --preset client
cmake --build --preset client --parallel 4
ctest --preset client --no-tests=error
./build/client/evo-client
```
Windows: `tools/windows-check.ps1 -Preset client -Action check` configures the
MSVC environment. Use `.exe` for executable paths. Linux requires the X11 or
Wayland development packages described in the dependency guide; the Docker
`ci-client` stage supplies the tested X11 subset.
Close the window to exit. `--renderer software` or `--renderer vulkan` requests
one explicit backend, without fallback. `--frames N` exits after N bounded steps
(including paused steps), maximum 100000; `--hidden` opens without showing the
window and pauses drawing. These options permit unattended smoke checks.
Usage errors exit 2, lifecycle failures exit 1, orderly exit returns 0.
For native X11 regression on a CI host:
```sh
xvfb-run -a env SDL_VIDEO_DRIVER=x11 ./build/client/evo-client-lifecycle-tests
```
CTest uses the dummy driver. The lifecycle suite runs 32 open/destroy rounds,
resize/scale queries, non-unit drawable-scale pixel checks, minimize/restore,
show/hide, focus/foreign events, reset/loss and close. Separate process checks
exercise initialization failure. Tests stay active under NDEBUG. Synthetic
events and software rendering do not qualify physical DPI, keyboard, GPU loss
or compositor behavior; those remain a hardware matrix at M9.8.
Analysis/sanitizers use the existing options, for example configure `--preset
asan -B build/client-asan -DEVO_BUILD_CLIENT=ON` with Clang 19. This instruments
owned frame/platform/app/test code, not SDL/system libraries. Linux X11 builds
link X11 directly (`SDL_X11_SHARED=OFF`) to preserve library lifetime across SDL
cycles. No preload or leak suppression is required. The diagnosed M9.1 dynamic
unload behavior and qualification evidence are documented in VALIDATION.md.
Headless defaults keep both `EVO_BUILD_CLIENT` and `EVO_BUILD_CLIENT_PROBE` OFF.
No prepared SDL sources, display or client runtime are needed for `evo-sim` or
server tests. No Kubernetes deployment change belongs to this desktop gate.