Skip to content

Commit

Permalink
Fix detection of GTEST_HAS_CLONE for Android.
Browse files Browse the repository at this point in the history
This was not in Gingerbread for anything but ARM (even though the
libs were hacked to lie about it being available in gingerbread).
  • Loading branch information
DanAlbert committed Nov 1, 2016
1 parent ff07a5d commit 4eafafb
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions googletest/include/gtest/internal/gtest-port.h
Expand Up @@ -754,8 +754,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
Expand Down

0 comments on commit 4eafafb

Please sign in to comment.