From d1599c3f7fc7200894c95a47ee41265d9c8b9c2d Mon Sep 17 00:00:00 2001 From: leha-bot Date: Fri, 13 Aug 2021 17:05:01 +0300 Subject: Fix build on Android (host) --- Source/cmake.cxx | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Source/cmake.cxx b/Source/cmake.cxx index ab8309d..7f8f654 100644 --- a/Source/cmake.cxx +++ b/Source/cmake.cxx @@ -114,7 +114,9 @@ # include "cmExtraSublimeTextGenerator.h" #endif -#if defined(__linux__) || defined(_WIN32) +// NOTE: the __linux__ macro is predefined on Android host too, but +// main CMakeLists.txt filters out this generator by host name. +#if (defined(__linux__) && !defined(__ANDROID__)) || defined(_WIN32) # include "cmGlobalGhsMultiGenerator.h" #endif @@ -2528,7 +2530,7 @@ void cmake::AddDefaultGenerators() this->Generators.push_back(cmGlobalMinGWMakefileGenerator::NewFactory()); #endif #if !defined(CMAKE_BOOTSTRAP) -# if defined(__linux__) || defined(_WIN32) +# if (defined(__linux__) && !defined(__ANDROID__)) || defined(_WIN32) this->Generators.push_back(cmGlobalGhsMultiGenerator::NewFactory()); # endif this->Generators.push_back(cmGlobalUnixMakefileGenerator3::NewFactory()); -- cgit v0.12