There are two supported ways to satisfy the SDL3 dependency:
#### Option 1: Use a system SDL3 package
If your distribution provides SDL3 development packages, install them and configure normally.
Common package names include `libsdl3-dev` (Debian/Ubuntu), `SDL3-devel` (Fedora/openSUSE), or similarly named SDL3 "-devel" packages.
At CMake configure time, A-La-Karte uses `find_package(SDL3 REQUIRED)`. This requires that SDL3 provides a CMake package (e.g. `SDL3Config.cmake`) and that CMake can find it.
If CMake cannot find SDL3, you can point it at the right prefix:
```bash
cmake -B build -S . \
-DCMAKE_BUILD_TYPE=Debug \
-DCMAKE_PREFIX_PATH=/path/to/sdl3/prefix
```
Alternatively you can point directly at SDL3's CMake package directory:
```bash
cmake -B build -S . \
-DCMAKE_BUILD_TYPE=Debug \
-DSDL3_DIR=/path/to/SDL3Config.cmake/parent
```
#### Option 2: Build SDL3 from a source tree
If your distro does not ship SDL3 yet (or ships a version without a usable CMake package), you can build SDL3 as part of the A-La-Karte build by pointing CMake at an SDL3 source checkout:
You can obtain a source tree by cloning upstream SDL:
```bash
git clone https://github.com/libsdl-org/SDL.git
```
```bash
cmake -B build -S . \
-DCMAKE_BUILD_TYPE=Debug \
-DALAKARTE_SDL3_SOURCE_DIR=/path/to/SDL
```
`ALAKARTE_SDL3_SOURCE_DIR` must point at a directory that contains `CMakeLists.txt` from SDL3.
This is intended for local development and CI setups. Distributions should prefer packaging SDL3 as a system dependency.
#### Packaging guidance
Packagers should depend on the system SDL3 development package and ensure CMake can discover it.
In particular:
- The build dependency must include SDL3 headers and the CMake package files.
- A-La-Karte links against `SDL3::SDL3`.
- Avoid using `ALAKARTE_SDL3_SOURCE_DIR` in distribution packaging.