cmake: fix name+location of SDL2.dll in configure generated SDL2::SDL2 target
diff --git a/sdl2-config.cmake.in b/sdl2-config.cmake.in
index 37610ba..59c254e 100644
--- a/sdl2-config.cmake.in
+++ b/sdl2-config.cmake.in
@@ -106,7 +106,7 @@ list(REMOVE_ITEM _sdl2_link_libraries SDL2 SDL2main mingw32 cygwin)
if(WIN32)
set(_sdl2_implib "${SDL2_LIBDIR}/${CMAKE_STATIC_LIBRARY_PREFIX}SDL2${CMAKE_SHARED_LIBRARY_SUFFIX}${CMAKE_STATIC_LIBRARY_SUFFIX}")
- set(_sdl2_dll "${SDL2_LIBDIR}/${CMAKE_STATIC_LIBRARY_PREFIX}SDL2${CMAKE_SHARED_LIBRARY_SUFFIX}${CMAKE_STATIC_LIBRARY_SUFFIX}")
+ set(_sdl2_dll "${SDL2_BINDIR}/SDL2${CMAKE_SHARED_LIBRARY_SUFFIX}")
if(EXISTS "${_sdl2_implib}" AND EXISTS "${_sdl2_dll}")
if(NOT TARGET SDL2::SDL2)
add_library(SDL2::SDL2 SHARED IMPORTED)