When compiling on Ubuntu 20.04 using the system version of SDL2, the build fails in two places:
cmake reports it can't find libSDL2. This is fixed by removing the 2.0.0 version arguments to find_package in CMakeLists.txt. (SDL is pretty good about backward compatibility so I'm reasonably confident this won't be a source of problems.)
Linking fails with a message that it can't find SDL::SDL. This is fixed by removing the SDL:: prefix from the SDL packages. It also fixes a bunch of cmake warnings.
Once these changes are made, the build succeeds.
I've attached my changes as a diff but I can submit a pull request if you want.
When compiling on Ubuntu 20.04 using the system version of SDL2, the build fails in two places:
cmake
reports it can't find libSDL2. This is fixed by removing the2.0.0
version arguments tofind_package
inCMakeLists.txt
. (SDL is pretty good about backward compatibility so I'm reasonably confident this won't be a source of problems.)Linking fails with a message that it can't find
SDL::SDL
. This is fixed by removing theSDL::
prefix from the SDL packages. It also fixes a bunch of cmake warnings.Once these changes are made, the build succeeds.
I've attached my changes as a diff but I can submit a pull request if you want.