1dnl 2dnl Check for arc4random on BSD systems 3dnl 4AC_CHECK_DECLS([arc4random_buf]) 5 6dnl 7dnl Check for CCRandomGenerateBytes 8dnl header absent in previous macOs releases 9dnl 10AC_CHECK_HEADERS([CommonCrypto/CommonRandom.h], [], [], 11[ 12 #include <sys/types.h> 13 #include <Availability.h> 14 #include <CommonCrypto/CommonCryptoError.h> 15]) 16 17dnl 18dnl Mostly for non Linux systems 19dnl 20AC_CHECK_FUNCS([getrandom]) 21 22dnl 23dnl Setup extension 24dnl 25PHP_NEW_EXTENSION(random, 26 random.c \ 27 engine_combinedlcg.c \ 28 engine_mt19937.c \ 29 engine_pcgoneseq128xslrr64.c \ 30 engine_xoshiro256starstar.c \ 31 engine_secure.c \ 32 engine_user.c \ 33 randomizer.c, 34 no,, -DZEND_ENABLE_STATIC_TSRMLS_CACHE=1) 35PHP_INSTALL_HEADERS([ext/random], [php_random.h]) 36