Main page
Setting up SDL3 for Web using CMake and MinGW-w64
- Download and unzip MinGW-w64: https://winlibs.com/ I have downloaded GCC 11.2.0 + MinGW-w64 10.0.0 (UCRT) - release 1, Win64. This archive contains the "mingw64" folder. Unzip the "mingw64" folder on the C drive (or on the another drive). It requires 672 MB on your hard disk
- The "mingw64" folder contains the "bin" folder. Add the "C:\mingw64\bin" path to the Path environment variable
- Download and install CMake: https://cmake.org/download/ Download "Windows x64 Installer" and install it
- Check that "mingw32-make" and "cmake" is available from the console:
cmake --version
mingw32-make --version
I use CMake v3.27.7
Download SDL3 sources from GitHub (Code > Download ZIP)
Unzip the downloaded archive. Open the console terminal inside the folder
Copy and paste the following command to the console for the configuration. Replace the installation path to your path if you need:
cmake -G "MinGW Makefiles" --fresh -S . -B dist -DCMAKE_INSTALL_PREFIX=E:\libs\sdl3-desktop-prefix
It requires 3 minutes 20 seconds