cmake: Fix detection of ALSA::ALSA for static linking

This was still conditional on whether SDL2::SDL2-static exists, but
it's now SDL3 that matters.

Resolves: https://github.com/libsdl-org/SDL/issues/6801
Fixes: 9eb4d1f "cmake: use FindALSA.cmake to find ALSA libraries"
Signed-off-by: Simon McVittie <smcv@collabora.com>
This commit is contained in:
Simon McVittie 2022-12-13 12:02:47 +00:00 committed by Ryan C. Gordon
parent 45ebdfb1dc
commit 07fa2769b8
1 changed files with 1 additions and 1 deletions

View File

@ -34,7 +34,7 @@ include("${CMAKE_CURRENT_LIST_DIR}/sdlfind.cmake")
set(SDL_ALSA @SDL_ALSA@)
set(SDL_ALSA_SHARED @SDL_ALSA_SHARED@)
if(SDL_ALSA AND NOT SDL_ALSA_SHARED AND TARGET SDL2::SDL2-static)
if(SDL_ALSA AND NOT SDL_ALSA_SHARED AND TARGET SDL3::SDL3-static)
sdlFindALSA()
endif()
unset(SDL_ALSA)