I would like to make the minimal OS image that could boot and run a SDL 2 app, in a raspberry pi 5.
Imagine you are putting a game for display in a convention and you want it running as fast as the thing turns, if some kid force closes it should turn back on, and it should have the minimal amount of things running in parallel in the OS, It should be dedicated the best as possible to this SDL2 game.
It’s not going to be actually used in a convention but the idea would be in a kid birthday party. Anyone done something like this before?
Here’s how you can build a Buildroot image for the Raspberry Pi 5:
git clone https://github.com/buildroot/buildroot
cd buildroot && git checkout 2025.05
make raspberrypi5_defconfig
make menuconfig # enable BR2_PACKAGE_SDL2 and configure buildroot to your liking
make
You’ll find the final image in output/images/sdcard.img.
This image will only contain SDL2 and you still need to build your own app. This section in the Buildroot manual should walk you through the process.