1AC_CHECK_DECL([arc4random_buf], 2 [AC_DEFINE([HAVE_ARC4RANDOM_BUF], [1], 3 [Define to 1 if you have the 'arc4random_buf' function.])]) 4 5dnl 6dnl Check for CCRandomGenerateBytes 7dnl header absent in previous macOs releases 8dnl 9AC_CHECK_HEADERS([CommonCrypto/CommonRandom.h],,, [dnl 10 #include <sys/types.h> 11 #include <Availability.h> 12 #include <CommonCrypto/CommonCryptoError.h> 13]) 14 15dnl 16dnl Mostly for non Linux systems 17dnl 18AC_CHECK_FUNCS([getrandom]) 19 20dnl 21dnl Setup extension 22dnl 23PHP_NEW_EXTENSION([random], m4_normalize([ 24 csprng.c 25 engine_mt19937.c 26 engine_pcgoneseq128xslrr64.c 27 engine_secure.c 28 engine_user.c 29 engine_xoshiro256starstar.c 30 gammasection.c 31 random.c 32 randomizer.c 33 zend_utils.c 34 ]), 35 [no],, 36 [-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1]) 37PHP_INSTALL_HEADERS([ext/random], m4_normalize([ 38 php_random_csprng.h 39 php_random_uint128.h 40 php_random.h 41])) 42