Merge commit '3617691fe0cb3b29ffcdeb5567d85126de91ba15' into main
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 4a8b20a..1194ecc 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -3160,6 +3160,10 @@ if(NOT SDL2_DISABLE_INSTALL)
NAMESPACE SDL2::
DESTINATION ${PKG_PREFIX}
)
+ if(ANDROID AND NOT CMAKE_VERSION VERSION_LESS 3.7)
+ install(EXPORT_ANDROID_MK SDL2Targets
+ DESTINATION "${CMAKE_INSTALL_DATAROOTDIR}/ndk-modules/SDL2")
+ endif()
endif()
if(NOT WINDOWS_STORE AND NOT SDL2_DISABLE_SDL2MAIN)
@@ -3168,6 +3172,10 @@ if(NOT SDL2_DISABLE_INSTALL)
NAMESPACE SDL2::
DESTINATION ${PKG_PREFIX}
)
+ if(ANDROID AND NOT CMAKE_VERSION VERSION_LESS 3.7)
+ install(EXPORT_ANDROID_MK SDL2mainTargets
+ DESTINATION "${CMAKE_INSTALL_DATAROOTDIR}/ndk-modules/SDL2main")
+ endif()
endif()
if(SDL_STATIC)
@@ -3176,6 +3184,10 @@ if(NOT SDL2_DISABLE_INSTALL)
NAMESPACE SDL2::
DESTINATION ${PKG_PREFIX}
)
+ if(ANDROID AND NOT CMAKE_VERSION VERSION_LESS 3.7)
+ install(EXPORT_ANDROID_MK SDL2staticTargets
+ DESTINATION "${CMAKE_INSTALL_DATAROOTDIR}/ndk-modules/SDL2-static")
+ endif()
endif()
if(SDL_TEST)
@@ -3184,6 +3196,10 @@ if(NOT SDL2_DISABLE_INSTALL)
NAMESPACE SDL2::
DESTINATION ${PKG_PREFIX}
)
+ if(ANDROID AND NOT CMAKE_VERSION VERSION_LESS 3.7)
+ install(EXPORT_ANDROID_MK SDL2testTargets
+ DESTINATION "${CMAKE_INSTALL_DATAROOTDIR}/ndk-modules/SDL2test")
+ endif()
endif()
install(