Platform Support
What this page describes. The development snapshot 3b43bd86 (branch next, after the 0.1.0 release). It offers three platform implementations — SDL3, the one windowing implementation, plus the windowless Headless and POSIX Terminal hosts — three audio implementations (one native and SDL-free), a build switch that removes SDL for windowless builds, a 31-flag capability contract (29 in alpha.1), and a curated set of 10 renderer identities whose defaults differ per operating system. Everything below is stated at the level the code, CI and CNA’s recorded runs actually prove. Statements about CI describe what the workflow files at this snapshot configure, build, run and assert; we read those files and did not inspect run results (see the caveat under What CI actually covers).
Four separate axes
In this snapshot, “backend” is still too ambiguous to be useful. CNA makes four different decisions, plus one build switch that decides whether SDL is present at all:
| Axis | Question it answers | Selection |
|---|---|---|
| Target operating system | Which toolchain and OS ABI is this binary built for? | CMake toolchain / target; reported by CNA::TargetPlatform |
| Platform implementation | Who owns windows, events, input, timing and host services? | CNA_PLATFORM — 3 implementations |
| Graphics renderer | Who turns CNA draw calls into pixels? | CNA_GRAPHICS_RENDERER and optional CNA_GRAPHICS_RENDERERS — 10 identities |
| Audio implementation | Who opens playback and recording devices, and (for two values) mixes? | CNA_AUDIO_PLATFORM — 3 implementations |
| (switch) SDL availability | Is SDL configured, built and linked at all? | CNA_ENABLE_SDL = AUTO (default), ON or OFF |
The platform implementation implements CNA::Platform::IPlatform and supplies narrow services to a renderer. It does not decide the renderer, audio implementation or target OS. This is also why the old public CNA::Platform enum became CNA::TargetPlatform (Desktop, Android, iOS, Web): CNA::Platform now names the host-integration namespace. The axes are independent with hard exclusions, listed under combination rules.
Platform and audio implementations
| Option | Implemented values | Default | Boundary |
|---|---|---|---|
CNA_PLATFORM | SDL3, HEADLESS, TERMINAL | SDL3 on every OS | SDL3 is the one windowing implementation: Windows, X11, Wayland, macOS, iOS, Android and the browser are reached through SDL’s own video drivers. TERMINAL is offered only off Windows (POSIX termios). Any other value fails configuration by name — there is no fallback to SDL3. Values are case-sensitive. |
CNA_AUDIO_PLATFORM | SDL3, NULL, ALSA | SDL3 on every OS | All three select low-level device code. SDL3 and ALSA also define SOUND_ENABLED and provide a mixer (SDL3_mixer, or CNA's own mixer for ALSA). NULL is not a feature-equivalent game-audio backend. ALSA is Linux-only. OPENAL and WASAPI are reserved and rejected. |
CNA_ENABLE_SDL | AUTO, ON, OFF | AUTO | AUTO and ON configure SDL3 as before. OFF fetches, builds and links no SDL, and refuses any selection that genuinely needs it (platform or audio SDL3; renderers SDL_GPU and FNA3D). |
# A display-free simulation that still uses SDL3 audio
cmake -S . -B build-headless \
-DCNA_PLATFORM=HEADLESS \
-DCNA_AUDIO_PLATFORM=SDL3 \
-DCNA_GRAPHICS_RENDERER=HEADLESS
# No SDL anywhere: a windowless build with ALSA audio and CNA's own mixer (Linux)
cmake -S . -B build-sdl-free -G Ninja \
-DCNA_ENABLE_SDL=OFF \
-DCNA_PLATFORM=HEADLESS \
-DCNA_AUDIO_PLATFORM=ALSA \
-DCNA_GRAPHICS_RENDERER=HEADLESS
# POSIX terminal host: CPU renderers only
cmake -S . -B build-terminal \
-DCNA_PLATFORM=TERMINAL \
-DCNA_AUDIO_PLATFORM=NULL \
-DCNA_GRAPHICS_RENDERER=SOFTWARE
Audio selection is ahead of audio parity. In modules/CMakeLists.txt, SOUND_ENABLED is defined for CNA_AUDIO_PLATFORM=SDL3 and CNA_AUDIO_PLATFORM=ALSA only. NULL builds omit the mixer, decoder and mixer-dependent tests; the XNA audio facade remains present but does not gain production playback from the Null device class (SoundEffect::Play() returns false). Null is therefore useful for deterministic configuration and device-contract work, not proof that a silent mixer consumes normal game audio. Audio System has the full implementation matrix.
The three platform implementations
| Implementation | What it is | Third-party inputs | Automatic CI evidence |
|---|---|---|---|
SDL3 Default | The one windowing implementation, on every target: Windows, X11 and Wayland sessions, macOS, iOS, Android and the browser through SDL’s own video drivers. A renderer that needs a native handle (HWND; X11 Display* and window; Wayland wl_display* and wl_surface*; a Cocoa or UIKit window) gets it from the SDL3 window through NativeWindowHandle. | Vendored SDL3 (shared on Linux, macOS, Windows and Android; static on iOS and Emscripten) | Many workflows: platform matrix (OPENGLES3, SDL_GPU, WEBGPU and SOFTWARE cells, with the SDL3 window suite also run on SDL’s x11 driver under Xvfb and its wayland driver under a headless Weston), input, general tests, Apple, Emscripten; the native-MSVC Windows job is manual |
HEADLESS | One window object, no optional services (only the always-present file-system and system-information services), every capability false. Always compiled in. | None | Platform matrix (including an SDL-free Headless + ALSA job), multi-renderer CI |
TERMINAL | POSIX-only terminal host (termios/poll, Kitty keyboard probe); presents finished CPU frames. One window. | None | Platform matrix cell plus a pseudo-TTY demo integration test |
The three audio implementations at a glance
| Value | Mixer (SOUND_ENABLED) | OS | Capture | Notes |
|---|---|---|---|---|
SDL3 (default) | Yes — SDL3_mixer | Every target | Yes | Needs SDL, so it cannot be combined with CNA_ENABLE_SDL=OFF. |
NULL | No | All | No | Deterministic silent transport; the only SDL-free choice off Linux. |
ALSA | Yes — CNA's own mixer | Linux only | Yes | No SDL. libasound is loaded at run time; CNA_AUDIO_DEVICE and CNA_AUDIO_RECORDING_DEVICE pick devices. |
Combination rules and hard exclusions
TERMINALaccepts only CPU renderers:SOFTWARE,HEADLESS,STUB.CNA_ENABLE_SDL=OFFrefuses platformSDL3, audioSDL3and the two SDL-linked renderers, with a message naming the reason.- Platform gates:
TERMINALonly off Windows;ALSAonly on Linux. A windowed build on any operating system usesSDL3. - Renderer combinations in
CNA_GRAPHICS_RENDERERSobey one rule: identities gated to different operating systems cannot be mixed. See Runtime Renderer Selection. - A name outside the 10 public renderer identities is a configure-time error, and a retired one is refused by name.
Window systems through SDL3, and SDL-free builds
SDL3 is CNA’s one windowing implementation, and the window system is SDL’s choice of video driver rather than a separate CNA platform: Windows uses SDL’s windows driver, a Linux desktop its x11 or wayland driver, and macOS, iOS, Android and the browser SDL’s own drivers for them. The native handles a renderer needs still reach it unchanged — an HWND, an X11 Display* and window, a Wayland wl_display* and wl_surface* — through NativeWindowHandle and its TryGetWin32/TryGetX11/TryGetWayland accessors (and CNA_NATIVE_WINDOW_SYSTEM_* in the C API). The dedicated page, Windows, X11 and Wayland, has the details and the evidence.
X11 through SDL3
In CISDL’s x11 video driver on an Xorg session (or Xwayland). CnaPlatformSdl3X11Tests runs the SDL3 window suite on a private Xvfb and checks that the Display* and window a renderer receives match the driver; the platform workflow runs it on every push. The recorded local validation ran seven renderers’ 2D and 3D demos on it.
Wayland through SDL3
In CISDL’s wayland video driver on a Wayland session, provided the Wayland development packages were present when the vendored SDL3 was first configured. CnaPlatformSdl3WaylandTests runs the same window suite on a private headless Weston and checks the wl_display* and wl_surface* a renderer receives.
Windows through SDL3
Manual CISDL’s windows video driver, with the HWND passed to DIRECTX9; the default renderer, SDL_GPU, presents through SDL’s Direct3D 12 GPU driver. The sdl3-windows job builds CNA natively with MSVC and runs the platform module suite on GitHub’s windows-latest image; it runs on manual dispatch, and its recorded run passed. A mingw-w64 cross-build of the window suite also passed under Wine.
SDL-free builds
In CI-DCNA_ENABLE_SDL=OFF builds a binary with no SDL in it, for servers, test runners and terminal games. It has no window: the platform is HEADLESS or TERMINAL, the renderer HEADLESS, SOFTWARE or STUB, and audio NULL or (on Linux) ALSA. A platform job builds a Headless + ALSA tree this way and checks that nothing links SDL.
Two other tutorials cover the remaining pieces: Tutorial 137 (ALSA audio with CNA's own mixer) and Tutorial 139 (the POSIX terminal platform).
Capability matrix (31 flags)
Every platform reports a fixed set of 31 boolean capabilities through IPlatform::GetCapabilities(), and answers a single one through IPlatform::Supports(PlatformCapability), which the runtime uses instead of reading the whole set (asking about the camera starts SDL’s camera subsystem; nothing else does). A capability is true only when the service behind it is really wired up; a false one means the call refuses deterministically with PlatformNotSupportedException (never a silent no-op). “If…” entries depend on the machine and are decided once, when the platform is created. Three flags — dragAndDrop, primarySelection, clipboardData — were appended since alpha.1's 29, and the Vulkan-surface flag went with the renderer that used it.
| Capability flag | SDL3 | Terminal | Headless |
|---|---|---|---|
multipleWindows | Yes | No (one) | No (one) |
highDpi | Yes | No | No |
multipleDisplays | Yes | No | No |
borderlessFullscreen | Yes | No | No |
nativeWindowHandle | Yes | No | No |
surfacePresentation | Yes | If stdout is a TTY | No |
openGlContext | Yes | No | No |
clipboard | Yes | No | No |
clipboardData | Yes | No | No |
dragAndDrop | Yes | No | No |
primarySelection | Yes (Unix desktops) | No | No |
textInput | Yes | No | No |
ime | Yes | No | No |
exactKeyboardState | Yes | If the Kitty keyboard protocol answers | No |
pixelAccurateMouse | Yes | No (cells) | No |
relativeMouse | Yes | No | No |
cursorShapes | Yes | No | No |
globalPointer | Yes | No | No |
inputDeviceEnumeration | Yes | No | No |
gamepad | Yes | No | No |
joystick | Yes | No | No |
gamepadRumble | Yes | No | No |
gamepadSensors | Yes | No | No |
haptics | Yes | No | No |
sensors | Yes | No | No |
powerInfo | Yes | No | No |
messageBox | Yes | No | No |
nativeFileDialog | Yes | No | No |
tray | If supported | No | No |
camera | If supported | No | No |
managedEntrypoint | Yes (Android and iOS main) | No | No |
What "supported" means here
"Supported" is doing a lot of work in most framework documentation. This page avoids the word and names the level instead, because the difference between "there is code for it" and "someone ran it" is exactly the difference that costs you a weekend.
| Level | What it means |
|---|---|
| Code path exists | Sources and CMake wiring are present for the target. |
| Configures | CMake accepts the target and the chosen renderer, and produces a build system. |
| Cross-compiles | A full build completes from a different host operating system. |
| Runs under Wine or an emulator | The binaries execute and render, but not on the operating system they target. |
| Runs on real hardware | Someone ran it on the actual platform. |
| Covered by CI | A workflow builds or tests it automatically on push and pull request — the only level that keeps working without anyone remembering to check. |
These levels do not imply each other. The repository contains MinGW/Wine paths, but no automatic workflow uses them; the native-Windows lanes still require manual dispatch. macOS and iOS have build workflows that trigger automatically, and an earlier campaign on a physical Mac (see macOS). Android has source/NDK wiring and no workflow.
Platform matrix
| Platform | Renderers | Highest level reached | Automatic CI |
|---|---|---|---|
| Linux | Every renderer that is not Windows-only (1) or Emscripten-only (1) — 8 of the 10 identities. Default: OPENGLES3. |
Runs on real hardware | Yes — multiple focused workflows on ubuntu-* runners (Xvfb and Mesa software drivers) |
| Windows | The Windows-only DIRECTX9, plus the portable renderers. Default: SDL_GPU (SDL’s Direct3D 12 driver). |
Cross-built with MinGW-w64 and run under Wine (DXVK for DIRECTX9, vkd3d-proton for SDL_GPU); no current real-Windows hardware validation |
No automatic Windows job — the MSVC DIRECTX9 and SDL_GPU smoke, SDL3 platform and content workflows are manual dispatch only |
| Web (Emscripten) | WEBGL2, plus WEBGPU. Default: WEBGL2. |
Build workflow configured; 90 C++ sample builds played in Chrome | An Emscripten multi-renderer build/link lane (WEBGL2 + WEBGPU); runtime evidence is the published sample gallery, each build run in Chrome when it was published, and CNA.NET’s headless-Chromium runs |
| macOS | SDL_GPU (SDL’s Metal driver), OPENGL33, WEBGPU, FNA3D, SOFTWARE and the other portable renderers. Default: SDL_GPU. |
CI builds and runs portable suites with SOFTWARE; the default SDL_GPU is not re-qualified on Apple hardware |
Yes — apple-ci.yml on GitHub’s macos-26 runners (a paravirtual GPU), with a gating SDL_GPU-on-Metal smoke leg that had not recorded a run at this snapshot |
| Android | Portable renderers via the NDK toolchain. Default: OPENGLES3 (SDL_GPU on Android is not qualified). |
OPENGLES3 runs on an x86_64 emulator (CNA’s record); NDK sensor implementations exist |
No CI of any kind |
| iOS / tvOS | SOFTWARE and SDL_GPU (the iOS allow-list; SDL_GPU, the default, has never been built for iOS); tvOS has no validated path. |
iOS Simulator smoke app with SOFTWARE; never run on a device |
iOS device and simulator builds with SOFTWARE and a simulator smoke launch; non-gating SDL_GPU legs. No physical-device claim. |
A single renderer remains the default build. The opt-in CNA_GRAPHICS_RENDERERS mode can link compatible sets, but it does not erase per-renderer capability or platform boundaries.
Status by operating system and platform implementation
Only what CI or code proves. CI = an automatic workflow (push or pull request to next, develop, main) builds or tests it. Manual CI = a workflow exists but runs only on workflow_dispatch. Code = sources and CMake wiring, no workflow. Local = only in-tree documents or scripts claim validation.
| Target | Platform implementations available | Real / tested | Experimental | Not proven |
|---|---|---|---|---|
| Linux, X11 session (Xorg) | SDL3 (default; SDL’s x11 driver), HEADLESS, TERMINAL |
CI SDL3 × OPENGLES3/SDL_GPU/WEBGPU/SOFTWARE, and the SDL3 window suite on the x11 driver; an SDL-free Headless + ALSA build. All on Xvfb. Local CNA’s full Debug suites for SDL_GPU, WEBGPU, SOFTWARE, FNA3D and a multi-renderer tree on its private runner (17 October 2026). |
— | Real desktops and physical GPUs are not a CI gate; the GPU pixel/oracle matrix is not gated. |
| Linux, Wayland session | SDL3 (SDL’s wayland driver, which exists only if the Wayland development packages were present when SDL was first built; otherwise X11 through Xwayland) |
CI the SDL3 window suite on the wayland driver under a private headless Weston. Local CNA’s private test runner uses a headless Weston with Xwayland. |
— | Real compositors (GNOME, KDE) are not a CI gate. |
| Windows | SDL3 (default; SDL’s windows driver), HEADLESS |
Manual CI MSVC builds of the DIRECTX9 suite and an SDL_GPU Direct3D 12 smoke set (not yet run); the SDL3 platform suite on MSVC; a Headless content-pipeline build. Local MinGW-w64 under Wine: CnaGraphicsTests.exe 2,688 of 2,688 and the DIRECTX9 suite 59 of 59 (60 of 60 with DXVK 3.1.1); SDL_GPU through vkd3d-proton. |
— | FFmpeg video (never built for Windows); WASAPI audio (reserved); XInput. |
| macOS | SDL3 (default; SDL’s Cocoa driver). CMake also offers HEADLESS and TERMINAL, which no macOS lane exercises. |
CI, configured macos-26 builds of SOFTWARE with the portable platform and storage suites and a self-contained .app launch, and a gating SDL_GPU-on-Metal smoke set. Earlier CNA’s Apple campaign of early October ran full test trees on a physical Mac mini M4 (Apple M4, 16 GB, macOS 27.0.1, Xcode 27), among them SOFTWARE, OPENGL33, SDL_GPU, WEBGPU and FNA3D, before the renderer set changed; it was not repeated. Deployment floor 13.3. |
— | A re-run of SDL_GPU, the default, on Apple hardware; on-screen presentation; Intel Macs; any recorded green run of the SDL_GPU leg. |
| iOS | SDL3 (default; SDL’s UIKit driver). HEADLESS and TERMINAL are not exercised on iOS. |
Simulator a SOFTWARE smoke app in the iOS Simulator. Build only a SOFTWARE device app final-links. Deployment floor 16.3; networking must be off (CNA_ENABLE_NET=OFF). |
The whole target is experimental; SDL_GPU legs are non-gating and it has never been built for iOS |
Any physical iPhone or iPad: device pixels, touch, audio, storage, background and resume, performance; tvOS. |
| Android | SDL3 (default; the only one CI configures). CMake also offers HEADLESS and TERMINAL; none is exercised on Android. |
Code; emulator runs outside CI NDK sensors, the SDL entry point and a Gradle demo project (minSdk 24, arm64-v8a); lifecycle, Back-button, portrait and APK-content fixes were found by running samples and games on the x86_64 Android emulator, and CNA records OPENGLES3 rendering there. No workflow, no preset. |
— | Physical devices, GL context loss, and everything at run time beyond those emulator runs. |
| WebAssembly (Emscripten) | SDL3 (default; the only one CI configures). CMake also offers HEADLESS and TERMINAL; none is exercised on the web. |
CI workflows, configured one bundle with WEBGL2;WEBGPU built and its renderer archives, registry entries and JS selection surface asserted; emsdk 6.0.3; Draco off. |
Threads option CNA_ENABLE_EMSCRIPTEN_THREADS; CNA_EMSCRIPTEN_USE_WASMFS=OFF for persistent saves in a threaded build |
Video (no FFmpeg build), sanitizers, any CNA_PLATFORM other than SDL3. |
| POSIX terminal | TERMINAL |
CI TerminalPlatform unit tests plus a pseudo-TTY run of the 2D demo with SOFTWARE. |
— | The Windows console (not offered). |
| Headless (any host) | HEADLESS |
CI platform matrix and multi-renderer jobs. | — | — |
Renderer availability by operating system
Which identities CMake will accept for each target. “Gated” means a hard FATAL_ERROR on any other target; “not gated” means CMake has no operating-system rule (the renderer may still need its own dependency: a Vulkan loader, a fetched library, a sibling checkout). This is configure-time acceptance, not a statement that every accepted pair has been run.
| Renderer group | Linux | Windows | macOS | iOS | Android | Web |
|---|---|---|---|---|---|---|
DIRECTX9 (1, Windows-only) | Refused | Gated to here (native or mingw-w64) | Refused | Refused | Refused | Refused |
WEBGL2 (1, Emscripten-only) | Refused | Refused | Refused | Refused | Refused | Gated to here. Default WEBGL2 |
OPENGLES3, OPENGL33 (EasyGL; need ../easy-gl and ../meta-gl) | Default is OPENGLES3 | Accepted | Accepted (OPENGL33 on Apple’s core context) | Refused (allow-list) | Default is OPENGLES3 | Refused (use WEBGL2) |
SDL_GPU | Not gated | Default | Default | Default (allow-listed; never built) | Not gated (not qualified) | Not gated by CMake; not built by CI for the web |
SOFTWARE | Not gated | Not gated | Not gated | Allow-listed | Not gated | Not gated by CMake; not built by CI for the web |
WEBGPU, FNA3D, HEADLESS, STUB | Not gated | Not gated | Not gated | Refused (allow-list) | Not gated | Not gated by CMake; only WEBGL2 and WEBGPU are built by CI |
That is 1 + 1 platform-gated identities and 8 that are not gated by operating system, for the 10 in total. The iOS allow-list can be overridden with CNA_APPLE_ALLOW_UNVALIDATED_RENDERER=ON for experiments only; that is not a support claim. TERMINAL further restricts the choice to SOFTWARE, HEADLESS and STUB. Which native window services a renderer needs is on Windows, X11 and Wayland.
Default selection per operating system
| Target | CNA_PLATFORM | CNA_AUDIO_PLATFORM | CNA_GRAPHICS_RENDERER | CNA_ENABLE_VIDEO (AUTO resolves to) |
|---|---|---|---|---|
| Linux | SDL3 | SDL3 | OPENGLES3 (needs the easy-gl and meta-gl siblings) | On if the four FFmpeg pkg-config modules are found |
| Windows (MSVC or MinGW) | SDL3 | SDL3 | SDL_GPU | Off (unsupported target) |
| macOS | SDL3 | SDL3 | SDL_GPU | On if FFmpeg is found (for example from Homebrew) |
| iOS | SDL3 | SDL3 | SDL_GPU (SOFTWARE is the other allowed, and the one CI builds) | Off |
| Android | SDL3 | SDL3 | OPENGLES3 | Off |
| Emscripten | SDL3 | SDL3 | WEBGL2 | Off |
There is no per-OS default for the platform or audio axes — both are SDL3 everywhere — and no CNA_PLATFORM environment variable. Only the renderer has run-time selection (CNA_GRAPHICS_RENDERER in the environment, in a multi-renderer build).
Linux
Linux is CNA's primary development platform and carries most of its CI. It is where the largest number of renderers can be selected, where all three platform implementations are offered, and where the project is developed on real hardware — the default renderer here is OPENGLES3, one of the three EasyGL profiles.
SDL3 (the default) works on X11 and Wayland sessions alike, through SDL’s x11 and wayland video drivers; SDL_VIDEO_DRIVER chooses between them when both are available. HEADLESS and TERMINAL need no display server. See Windows, X11 and Wayland.
The Windows renderers are also driven from Linux: DIRECTX9 and SDL_GPU’s Direct3D 12 driver are cross-compiled with MinGW-w64 and executed under Wine (DXVK, vkd3d-proton), so a Linux workstation is in practice the machine where Windows rendering gets exercised too. See Windows for what that does and does not prove.
Practical requirements: the sharp-runtime sibling checkout (version 0.1.x; its next branch for this snapshot) for every build, easy-gl plus meta-gl for the default renderer, a C++23 compiler (CI uses GCC 14), and, for a windowed build, the X11/Wayland/GL/ALSA/D-Bus development packages so the vendored SDL3 gets real video drivers (a Vulkan driver at run time for SDL_GPU). FFmpeg development packages are optional now. Building has the exact commands and package lists.
Windows
One renderer refuses to configure anywhere but Windows: DIRECTX9, real Direct3D 9. The default renderer on Windows is SDL_GPU, on SDL’s Direct3D 12 GPU driver; it is validated under Wine (vkd3d-proton) only, and has gaps there that matter for a port: ShaderEffect is compiled out on Windows and occlusion queries are unavailable. Windows windows come from SDL3’s windows video driver, which hands DIRECTX9 the HWND it presents into; HEADLESS is the windowless alternative. An SDL-free Windows build is therefore windowless, and must also use CNA_AUDIO_PLATFORM=NULL.
The repository provides MinGW cross-build and Wine execution paths, but none is an automatic workflow in this snapshot. CNA’s recorded Windows evidence is those Wine runs: DIRECTX9 through DXVK (its compiled-effect test hangs in DXVK 2.6.0’s device teardown and passes with DXVK 3.1.1) and SDL_GPU through vkd3d-proton. The native MSVC workflows — the DIRECTX9 suite with an SDL_GPU smoke leg, the SDL3 platform suite and a Headless content-pipeline build — are all manual dispatch, and CNA records no current real-Windows hardware validation. Treat runtime claims as results from the exact configuration, not as continuous native-Windows coverage.
Two further Windows facts worth knowing before you plan a release:
- FFmpeg video is never built for Windows.
CNA_ENABLE_VIDEO=AUTOsilently falls back to the no-video backend on Windows and MinGW, andONis a configure error.VideoandVideoPlayerstill compile and link; without a decoder they throwSystem::NotSupportedExceptionat run time. - The MinGW cross-build is not covered by CI. Apart from a MinGW header-compatibility check for the experimental C API, building the engine for Windows is exercised by hand (MinGW-w64 + Wine) or by the manual MSVC workflows. The MinGW build compiles every test binary; tests that need what Windows cannot provide there (a Python interpreter,
/dev/full, symbolic links, …) report a skip.
Web (Emscripten)
The web target is real and has a browser build workflow. WEBGL2 is Emscripten-only and the default; WEBGPU also has a browser route. The strongest evidence is the 90 C++ sample builds playable at samples.libcna.com; saves persist in the browser’s IndexedDB, and games that start threads use a threaded build. The multi-renderer Emscripten job configures and links a WEBGL2 + WEBGPU bundle, and the workflow pins emsdk 6.0.3. The platform is SDL3 here by default and in every browser workflow (CMake’s platform selection would also list HEADLESS and TERMINAL, neither of which is exercised on the web); CNA_PLATFORM=EMSCRIPTEN is reserved and refused.
Saves persist on the web. The storage module mounts the browser’s IndexedDB (IDBFS) for StorageDevice (/cna-storage) and isolated storage (/save) and restores it before main(). Threaded builds keep WasmFS by default and need -DCNA_EMSCRIPTEN_USE_WASMFS=OFF for persistence; if the mount fails, StorageDevice reports the device as not connected. See Storage.
Your Game object no longer must be heap-allocated on the web. Earlier builds unwound the caller's stack, so a stack-allocated Game was silently corrupted. In this snapshot Game::Run() blocks on the caller's own stack through Asyncify, so an ordinary local MyGame game; game.Run(); is supported. CNA-owned application executables link Asyncify automatically; an external final executable that uses a blocking Game::Run() must link CNA::EmscriptenAsyncify.
Video links but cannot decode here: the Video/VideoPlayer types are part of every build, no FFmpeg backend exists for Emscripten, and playback throws System::NotSupportedException at run time. Networking discovery does not work on Emscripten either.
Serve the generated .html, .js and .wasm from a local web server; browsers block direct file:// access. Configure with emcmake: emcmake cmake --preset web — the web preset carries no toolchain file, so cmake --preset web alone would configure natively.
macOS
macOS is reached through SDL3’s Cocoa video driver, not through a CNA backend of its own. At this snapshot the default renderer there is SDL_GPU, which SDL runs on its Metal GPU driver; OPENGL33 (Apple’s 4.1 core context), WEBGPU (whose wgpu-native library drives Metal there), FNA3D and SOFTWARE are the other renderers CMake accepts there, and OPENGLES3 does not apply (macOS has no native OpenGL ES).
The macOS default is not re-qualified. CNA’s own handoff lists a re-run on Apple hardware as not done since its renderer set changed on 13 October 2026. The evidence that exists: apple-ci.yml builds CNA with SOFTWARE on GitHub’s macos-26 runners, runs the portable platform and storage suites and launches a self-contained .app; a gating job builds the SDL_GPU smoke set and runs it on the runners’ Metal device, which had not recorded a run at this snapshot. SDL_GPU on Apple compiles ShaderEffect out and has no occlusion queries.
Earlier, CNA’s Apple stabilization campaign (early October 2026, before this snapshot) ran full CTest trees on a physical Mac mini M4 (Apple M4, arm64, 16 GB, macOS 27.0.1, Xcode 27, Apple clang 21) with no failing test, among them SOFTWARE (11,084 passed), OPENGL33 with compiled effects (11,916), SDL_GPU on SDL’s Metal driver (10,962), WEBGPU (10,968) and FNA3D (10,875), and 90 or 91 of the 91 ported samples on several of them (LensFlare needs occlusion queries). Those runs were made with the console locked, so on-screen presentation and vsync pacing were never observed, no Intel Mac was run, and they describe the CNA of that time, not this snapshot.
Practical notes. The macOS deployment floor is 13.3 (a lower CNA_MACOS_DEPLOYMENT_TARGET is a configure error, because CNA needs Apple’s floating-point std::to_chars); Xcode 15.4 is too old, CI uses Xcode 26. FFmpeg is optional (CNA_ENABLE_VIDEO=AUTO uses it when found), but Homebrew’s FFmpeg is built for the host macOS, so a binary linked against it does not start on an older macOS whatever the deployment target says; use CNA_ENABLE_VIDEO=OFF or an FFmpeg built for the floor. Online Gamer Services sessions need a libcurl with WebSocket support (Homebrew’s curl): Apple’s system libcurl lacks it, and the relay then refuses by name. SystemLink discovery between processes works on macOS. SDL3 is the platform; CMake also offers HEADLESS and TERMINAL, which no macOS lane exercises. See Tutorial 109.
Android
Android is genuinely wired rather than aspirational: the NDK toolchain path is in the build system, the code paths exist, and the NDK sensor implementations are real — Compass and Motion are in fact Android-only and report NotSupported elsewhere. See Sensors.
Android has no CI at all — zero jobs, zero presets. Every Android build is one somebody ran by hand, and nothing catches an Android regression automatically. The only Android build project in the repository is the Devices demo (Gradle: minSdk 24, target/compile SDK 35, arm64-v8a only). CNA records NDK cross-builds of CNA and its C API (NDK 29, x86_64, android-24) and runs on the x86_64 Android emulator only: C# samples through CNA.NET, and, on 14 October 2026, a C API lifecycle smoke drawing with OPENGLES3 on the emulator’s OpenGL ES 3.0 (android-graphics-limitations.md). No physical device has run CNA, and SDL_GPU has no recorded Android build. Video is unavailable here too.
iOS and tvOS
iOS support is experimental. The snapshot ships an iOS toolchain file (cmake/toolchains/ios.cmake, with CNA_IOS_SIMULATOR=ON for the simulator SDK) and admits two renderers: SOFTWARE, presented through the platform’s surface presenter, and SDL_GPU on SDL’s Metal GPU driver, which is the default but has never been built for iOS. A configure needs -DCNA_ENABLE_NET=OFF (the iOS SDK ships no libcurl), so iOS builds have no networking, and FFmpeg video is off. The deployment floor is iOS 16.3.
What has been demonstrated, at its real level:
- An iOS Simulator smoke app with
SOFTWARE.apple-ci.ymlbuilds the simulator app and launches it. - A final-linked device build. The
SOFTWAREdevice app compiles and links (arm64, iOS 16.3, system frameworks only). It was never run: there was no physical device or signing identity. SDL_GPUlegs for the device and the simulator are configured as non-gating CI jobs (continue-on-error).
No physical iPhone or iPad has run CNA, so nothing here establishes device pixels, real touch input, audio, storage, background and resume, or performance. CNA_APPLE_ALLOW_UNVALIDATED_RENDERER=ON merely permits experiments outside the allow-list; it is not a support claim. tvOS has no validated path.
What CI actually covers
This snapshot contains 18 GitHub Actions workflow files (25 jobs; 16 files run automatically on pushes and pull requests to next, develop and main, and two are manual or branch-specific). They cover general tests, platform conformance, multi-renderer Linux and Emscripten builds, Apple platforms, declared C API compatibility/release gates and generated routes, and focused renderer/subsystem checks. Trigger and evidence still matter more than the raw file count. The general job configures OPENGLES3, runs a full default build and an unfiltered ctest, and tolerates a single named known failure.
Configured is not the same as passing. Statements on this page describe what the workflow files at this snapshot configure, build, run and assert; we read those files and did not inspect run results, except where a run recorded in CNA’s own plans is cited. Every workflow now takes sharp-runtime (and, where needed, easy-gl and meta-gl) from the branch matching CNA’s own — the pushed branch, then next, then develop — through scripts/ci/sibling_branch.sh, so no lane builds against a stale sibling pin.
| Workflow | Trigger | Runner | What it does |
|---|---|---|---|
| General, input, devices and focused renderer checks | Mostly push / PR | Linux | Unit, build, browser and renderer-specific contracts; exact filters vary by workflow. |
multi-renderer-ci.yml and emscripten-multi-renderer-ci.yml | Push / PR | Linux / Emscripten | Runtime-selection sets, combination rules and the Emscripten WEBGL2 + WEBGPU build/link check. |
platform-ci.yml | Push / PR (one job manual) | Linux; Windows for the manual job | Platform abstraction and SDL3/Headless/Terminal combinations; the SDL3 window suite on SDL’s x11 driver (private Xvfb) and wayland driver (private headless Weston); an SDL-free Headless + ALSA build; the CNA_ENABLE_SDL matrix; and, on manual dispatch, the SDL3 platform suite built natively with MSVC. |
apple-ci.yml | Push / PR | macOS (macos-26) | macOS SOFTWARE portable suites and an .app launch; a gating SDL_GPU-on-Metal smoke set; iOS device final-link and simulator launch with SOFTWARE; non-gating iOS SDL_GPU legs. |
Six c-api-*.yml workflows | Push / PR | Linux | ABI baseline, compatibility, coverage, generated-routes, limitations and release-gate checks. No workflow builds the C API library. |
d3d-windows-ci.yml and content-pipeline-windows-ci.yml | Manual only | Windows | Native MSVC DIRECTX9 suite and SDL_GPU Direct3D 12 smoke set, and the Headless content-pipeline suites (the last also runs on pushes to one named branch). |
How to read the matrix
The snapshot has much broader automated coverage than alpha.1, but a workflow is not universal proof:
- The Windows Direct3D 9,
SDL_GPU, SDL3-on-Windows and content-pipeline lanes remain manual, so their existence is not an automatic merge gate. - The iOS device lane final-links; the simulator lane launches a
SOFTWAREsmoke app. Neither establishes physical-device or full-game correctness, and theSDL_GPUlegs are non-gating. - The Emscripten multi-renderer lane covers configuration and linking; the runtime evidence for the web is the published sample gallery and CNA.NET’s headless-Chromium runs.
- Android has source and NDK wiring but no automatic workflow.
- Every Linux job runs on a virtual X server (or a headless Weston) with Mesa’s software drivers, and the macOS jobs on GitHub’s virtual Macs. None provides a physical-GPU or real-desktop run; the physical-hardware evidence comes from CNA’s recorded campaigns.
Not exercised by any workflow: Android, tvOS, CNA_BUILD_C_API=ON builds, Clang on Linux (except C header compatibility), CNA_ENABLE_VIDEO=OFF on Linux, the full engine + DirectX under Wine/MinGW, and the GPU pixel/oracle corpus (run locally, by hand). Verification & Known Issues covers the wider testing picture, and Graphics Renderers the per-renderer side of it.
Where video is available
Video and VideoPlayer exist in every build and link everywhere, but decoding is available on Linux and macOS only, and only where the optional FFmpeg backend was compiled in: CNA_ENABLE_VIDEO is ON, or AUTO found libavcodec, libavformat, libavutil and libswresample. On Windows, Emscripten, Android and iOS FFmpeg is never built (AUTO falls back silently, ON is a configure error). Without a backend the calls throw System::NotSupportedException at run time — a run-time exception, not a link error. Audio and MediaPlayer song playback do not depend on FFmpeg. See Video Playback.
Deep dives on this topic
Long-form pages that explain the exact semantics, invariants and evidence behind this subject.
- Android and Apple targets: structure, lifecycle, assets and evidence — How CNA's Android application and NDK code are structured, how Game handles mobile lifecycle events, how assets and saves are found on a device, and what the Mac mini M4 qualification, the iOS Simulator probe and the Apple workflows show.
- Configuring CNA per target: routes, toolchains and what a green build proves — How the Linux, Windows (MSVC and MinGW-w64 with Wine), Android, Emscripten and Apple routes configure CNA, run its tests, and what a successful configure, build or test run on each one proves.
- The cross-platform contract: axes, composition and evidence per route — How target OS, platform implementation, renderer set, audio implementation and the XNA surface compose in CNA, what IPlatform owns, and why each platform claim is an evidence vector.
- The web target: Emscripten build contract, browser loop, storage and renderer evidence — CNA's Emscripten build contract (exception ABI, Asyncify, threads), the Asyncify browser loop, content and IndexedDB-backed save storage in the virtual file system, web networking, and the evidence per browser renderer.
- Windows from Linux: MinGW cross-builds, runtime staging and Wine evidence — The MinGW-w64 route from Linux to a runnable Windows test: toolchain, target-built SDL, DLL staging, CTest emulators, which Wine runtime owns each renderer, prefix hygiene and evidence tiers.
Known issues in this area
Current defects, gaps and limitations at this snapshot that touch this subject.
- CNA-BUG-041: A relative ContentManager root still follows the working directory on the non-SDL3 platforms, and the loose tier cannot see Android packaged assets — ContentManager now roots a relative RootDirectory under TitleLocation and reads .cnb through the platform on Android, but TitleLocation is the working directory on the non-SDL3 platforms and the loose tier still gates on
- CNA-BUG-142: Without a mixer (NULL audio) songs never end: queued copies carry no Duration, so the elapsed-time fallback never fires — LoadSong copies only a Song's file and name, so every queued Song has a zero Duration and, in builds without SOUND_ENABLED, DetectSongEndedByElapsedTime never reports an end: MediaPlayer stays Playing and the queue never
- CNA-BUG-162: The phone notification channel and sender never initialise Winsock or link ws2_32, so on Windows they work only if something else did — modules/phone calls no WSAStartup and its library names no Winsock import library, so on Windows Open and SendAsync work only after another component initialised Winsock. Its INVALID_SOCKET checks were fixed on 2026-10-2
- CNA-BUG-177: The Headless and Terminal window constructors accept BorderlessFullscreen although their own SetFullscreenMode refuses it — Both capability-minimal windows store WindowDescription::fullscreenMode directly at construction instead of routing it through SetFullscreenMode, so a window created in BorderlessFullscreen reports that mode though the p
- CNA-GAP-054: The terminal window title is stored but never emitted, so SetTitle has no visible effect — TerminalWindow::SetTitle records the title and defers the OSC emission to the session, but the session prologue emits no title sequence and nothing else writes one, so a terminal window title is never shown.
- CNA-GAP-055: TerminalSession does not restore or re-establish the terminal on job-control stop and continue (SIGTSTP/SIGCONT) — The session's restoring signal set covers termination and crash signals but not SIGTSTP/SIGCONT, so a Ctrl-Z that suspends a terminal game leaves the terminal in raw mode, the alternate screen and mouse reporting until t
- CNA-PLAT-016: On Apple, SamplerState.MipMapLevelOfDetailBias does not reach the GPU on FNA3D's non-OpenGL drivers — FNA3D on macOS and iOS hands a sampler LOD bias to SDL's Metal-backed GPU driver, which ignores it, so the bias is accepted without effect; RendererFeature::SamplerLevelOfDetailBias reports that.
- CNA-PLAT-017: FNA3D has no occlusion queries on its SDL_GPU driver, the driver FNA3D tries first and the one it runs on Apple — Fna3dRenderer probes queries only on FNA3D's OpenGL and Direct3D 11 drivers; on its SDL_GPU driver (FNA3D's first choice, and its Metal route on Apple) OcclusionQuery is reported unsupported and its constructor refuses,
- CNA-VGAP-008: Android and iOS have no device evidence at this snapshot: no Android workflow, iOS only in the Simulator, and lifecycle and packaged-content loading untested on a device — Android has no preset or workflow; iOS evidence is device final-links plus a one-frame Simulator smoke on SOFTWARE, the SDL_GPU iOS legs are non-gating and never recorded as built, no physical device has run CNA, and no
- CNA-VGAP-011: No test exercises PlatformSelection.cmake's reserved-identifier refusal paths — PlatformSelection.cmake fails configure for SDL12, EMSCRIPTEN and TERMINAL on Windows, but no test asserts those refusals; the one platform-selection test, CnaPlatformSelection_Retired, covers only the retired and unknow
- CNA-VGAP-020: The hand-written CnaPlatformTests filter misses TerminalPresenterThroughPlatformTest and nine other platform suites, so the platform CI cells never select them — CnaPlatformTests selects suites by hand-written name tokens: TerminalPresenter.* misses TerminalPresenterThroughPlatformTest, and nine more platform suites (key codes, scancodes, filesystem, sensor session, SDL3 device s
- CNA-VGAP-061: SDL_GPU is the default renderer on Windows, macOS and iOS but is not qualified there — Since the native Windows and Apple renderers were retired, a build for Windows, macOS or iOS defaults to SDL_GPU, yet CNA records no native Windows run of it, no Apple run since the retirement and no iOS build.