summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBilly Donahue <BillyDonahue@users.noreply.github.com>2016-11-03 20:36:28 (GMT)
committerGitHub <noreply@github.com>2016-11-03 20:36:28 (GMT)
commita2b8a8e07628e5fd60644b6dd99c1b5e7d7f1f47 (patch)
tree3e2e9c1572e3f263dbfa43e489ea0c7152e68ee1
parent3447fc31b4eea1fbcb86fa0e2f5d9ed9f38776bf (diff)
parent4eafafbde585418303229607227055106a86f507 (diff)
downloadgoogletest-a2b8a8e07628e5fd60644b6dd99c1b5e7d7f1f47.zip
googletest-a2b8a8e07628e5fd60644b6dd99c1b5e7d7f1f47.tar.gz
googletest-a2b8a8e07628e5fd60644b6dd99c1b5e7d7f1f47.tar.bz2
Merge pull request #918 from DanAlbert/fix-android-GTEST_HAS_CLONE
Fix detection of GTEST_HAS_CLONE for Android.
-rw-r--r--googletest/include/gtest/internal/gtest-port.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/googletest/include/gtest/internal/gtest-port.h b/googletest/include/gtest/internal/gtest-port.h
index 860aaaf..0d53ad2 100644
--- a/googletest/include/gtest/internal/gtest-port.h
+++ b/googletest/include/gtest/internal/gtest-port.h
@@ -760,8 +760,12 @@ using ::std::tuple_size;
# if GTEST_OS_LINUX && !defined(__ia64__)
# if GTEST_OS_LINUX_ANDROID
-// On Android, clone() is only available on ARM starting with Gingerbread.
-# if defined(__arm__) && __ANDROID_API__ >= 9
+// On Android, clone() became available at different API levels for each 32-bit
+// architecture.
+# if defined(__LP64__) || \
+ (defined(__arm__) && __ANDROID_API__ >= 9) || \
+ (defined(__mips__) && __ANDROID_API__ >= 12) || \
+ (defined(__i386__) && __ANDROID_API__ >= 17)
# define GTEST_HAS_CLONE 1
# else
# define GTEST_HAS_CLONE 0