Appendix G: WSL Support
FNA games can be run via the Windows Subsystem for Linux, easing the development and testing process for native Linux games on Windows. This is recommended over using a VM, but as always, you are also welcome to install Linux on real hardware :)
Installing
The installation process for an FNA-compatible environment is as follows:
- Open PowerShell
- Enter
wsl --install FedoraLinux-44. (If it says something about rebooting, reboot then enter this command again.) - Create a username for the Linux container, it can be anything you want
- Install the minimum requirements for GUI/audio support by entering
sudo dnf install SDL3-devel - You should now be able to copy Linux builds to your container's home directory, copy and run!
After these steps are complete, you only need to enter wsl in PowerShell to enter your container.
Caveats
There is only one remaining caveat for testing, which is that the D3D12 swapchain on Linux is passed to Windows via host memory - essentially, it's going from GPU -> CPU -> GPU. This is incredibly slow, especially at high resolutions, so for testing purposes you may want to use a smaller window size (i.e. 1280x720) to avoid Windows-bound performance issues.
The above issue is being tracked here.
As for building, note that this environment is not suitable for compiling native binaries as it uses a glibc version higher than our standard OS minimum requirement. Instead, you are strongly encouraged to use the build OS listed in Appendix F.