/* Define if position independent code is enabled */
#cmakedefine ENABLE_PIC
-/* Define to 1 if you have the `arc4random' function. */
-#cmakedefine HAVE_DECL_ARC4RANDOM ${HAVE_DECL_ARC4RANDOM}
-
/* Define to 1 if you have the `backtrace' function. */
#cmakedefine HAVE_BACKTRACE ${HAVE_BACKTRACE}
/* can use __crashreporter_info__ */
#undef HAVE_CRASHREPORTER_INFO
+/* Define to 1 if you have the declaration of `arc4random', and to 0 if you
+ don't. */
+#cmakedefine01 HAVE_DECL_ARC4RANDOM
+
/* Define to 1 if you have the declaration of `FE_ALL_EXCEPT', and to 0 if you
don't. */
#cmakedefine01 HAVE_DECL_FE_ALL_EXCEPT
return "\033[0m";
}
-#if !defined(HAVE_DECL_ARC4RANDOM) || !HAVE_DECL_ARC4RANDOM
+#if !HAVE_DECL_ARC4RANDOM
static unsigned GetRandomNumberSeed() {
// Attempt to get the initial seed from /dev/urandom, if possible.
int urandomFD = open("/dev/urandom", O_RDONLY);
#endif
unsigned llvm::sys::Process::GetRandomNumber() {
-#if defined(HAVE_DECL_ARC4RANDOM) && HAVE_DECL_ARC4RANDOM
+#if HAVE_DECL_ARC4RANDOM
return arc4random();
#else
static int x = (static_cast<void>(::srand(GetRandomNumberSeed())), 0);