From ab66b89a461810f612f69a3d8eb873cb08557a6a Mon Sep 17 00:00:00 2001 From: Brad King Date: Tue, 20 Jun 2023 10:33:53 -0400 Subject: Android: Restore platform id vars with legacy toolchain file Restore definition of `ANDROID` and `UNIX` when `CMAKE_SYSTEM_VERSION` is `1`. This was broken by commit 1373373823 (enable_language: Establish target platform identification variables earlier, 2023-06-06, v3.27.0-rc1~3^2~1). Fixes: #25004 --- Modules/Platform/Android-Initialize.cmake | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Modules/Platform/Android-Initialize.cmake b/Modules/Platform/Android-Initialize.cmake index 2a2f6e2..e2b2bd5 100644 --- a/Modules/Platform/Android-Initialize.cmake +++ b/Modules/Platform/Android-Initialize.cmake @@ -10,6 +10,11 @@ if(CMAKE_ANDROID_NDK) include(${CMAKE_ANDROID_NDK}/build/cmake/hooks/pre/Android-Initialize.cmake OPTIONAL) endif() +include(Platform/Linux-Initialize) +unset(LINUX) + +set(ANDROID 1) + # Support for NVIDIA Nsight Tegra Visual Studio Edition was previously # implemented in the CMake VS IDE generators. Avoid interfering with # that functionality for now. @@ -23,11 +28,6 @@ if(CMAKE_SYSTEM_VERSION EQUAL 1) return() endif() -include(Platform/Linux-Initialize) -unset(LINUX) - -set(ANDROID 1) - set(CMAKE_BUILD_TYPE_INIT "RelWithDebInfo") if(CMAKE_ANDROID_NDK_TOOLCHAIN_UNIFIED) -- cgit v0.12