From 0cbd5ae3cb0f7b73c945e1d69f3374d902a9f78d Mon Sep 17 00:00:00 2001 From: Benoit Jacob Date: Tue, 31 Mar 2015 11:17:21 -0400 Subject: [PATCH] Correctly detect Android with ndk_build --- Eigen/src/Core/util/Macros.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Eigen/src/Core/util/Macros.h b/Eigen/src/Core/util/Macros.h index 6b294e77f..7cedb4c97 100644 --- a/Eigen/src/Core/util/Macros.h +++ b/Eigen/src/Core/util/Macros.h @@ -213,7 +213,8 @@ #endif /// \internal EIGEN_OS_ANDROID set to 1 if the OS is Android -#if defined(__ANDROID__) +// note: ANDROID is defined when using ndk_build, __ANDROID__ is defined when using a standalone toolchain. +#if defined(__ANDROID__) || defined(ANDROID) #define EIGEN_OS_ANDROID 1 #else #define EIGEN_OS_ANDROID 0