[android_compat_fixes] fixed Android NDK r23 duplicate __ANDROID_API__ define

Signed-off-by: AMZN-ScottR <24445312+AMZN-ScottR@users.noreply.github.com>
This commit is contained in:
AMZN-ScottR
2021-11-02 13:05:54 -07:00
parent 4468a9213d
commit d1805dbd1c
@@ -12,6 +12,11 @@ if(CMAKE_CXX_COMPILER_ID STREQUAL "Clang")
include(cmake/Platform/Common/Configurations_common.cmake)
include(cmake/Platform/Common/Clang/Configurations_clang.cmake)
set(_android_api_define)
if(${LY_TOOLCHAIN_NDK_PKG_MAJOR} VERSION_LESS "23")
set(_android_api_define __ANDROID_API__=${LY_TOOLCHAIN_NDK_API_LEVEL})
endif()
ly_append_configurations_options(
DEFINES
LINUX64
@@ -22,9 +27,9 @@ if(CMAKE_CXX_COMPILER_ID STREQUAL "Clang")
MOBILE
_HAS_C9X
ENABLE_TYPE_INFO
__ANDROID_API__=${LY_TOOLCHAIN_NDK_API_LEVEL}
NDK_REV_MAJOR=${LY_TOOLCHAIN_NDK_PKG_MAJOR}
NDK_REV_MINOR=${LY_TOOLCHAIN_NDK_PKG_MINOR}
${_android_api_define}
COMPILATION
-femulated-tls # All accesses to TLS variables are converted to calls to __emutls_get_address in the runtime library