android CMakeLists.txt: added support for both 'support' and 'compatibility' in support library path for v7 appcompat

supports path styles:
$ANDROID_SDK/extras/android/support/v7/appcompat
$ANDROID_SDK/extras/android/compatibility/v7/appcompat
This commit is contained in:
Gerry Reno 2014-07-13 14:54:48 -04:00
parent 9fa451428b
commit d06ed2fa2f

View File

@ -62,10 +62,19 @@ else()
endif()
set(APPCOMPAT_DIR "${CMAKE_CURRENT_BINARY_DIR}/appcompat_v7")
add_custom_target(copy_appcompat ALL
COMMAND ${CMAKE_COMMAND} -E copy_directory ${ANDROID_SDK}/extras/android/support/v7/appcompat ${APPCOMPAT_DIR}
COMMAND ${ANDROID_COMMAND} update lib-project -p ${APPCOMPAT_DIR}
)
set(supportdir "${ANDROID_SDK}/extras/android/support/v7/appcompat")
set(compatibilitydir "${ANDROID_SDK}/extras/android/compatibility/v7/appcompat")
if(EXISTS "${supportdir}" AND IS_DIRECTORY "${supportdir}")
add_custom_target(copy_appcompat ALL
COMMAND ${CMAKE_COMMAND} -E copy_directory "${supportdir}" ${APPCOMPAT_DIR}
COMMAND ${ANDROID_COMMAND} update lib-project -p ${APPCOMPAT_DIR}
)
elseif(EXISTS "${compatibilitydir}" AND IS_DIRECTORY "${compatibilitydir}")
add_custom_target(copy_appcompat ALL
COMMAND ${CMAKE_COMMAND} -E copy_directory "${compatibilitydir}" ${APPCOMPAT_DIR}
COMMAND ${ANDROID_COMMAND} update lib-project -p ${APPCOMPAT_DIR}
)
endif()
add_subdirectory(FreeRDPCore)
add_subdirectory(aFreeRDP)