diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2018-08-31 09:56:24 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2018-08-31 09:56:24 +0000 |
commit | 7f0ea220a3de96081d4b1489a83173556aa49b05 (patch) | |
tree | 4ae8ed1c3efc691ff47cc22aae336122c7704d96 /configure.ac | |
parent | a49eac7e88693bd0fd3099b1947f9da782989b06 (diff) | |
download | ruby-7f0ea220a3de96081d4b1489a83173556aa49b05.tar.gz |
random.c: SecRandomCopyBytes
* random.c (fill_random_bytes_syscall): use SecRandomCopyBytes in
Security framework on macOS 10.7 or later.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64596 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac index 92713f3a3b..9328fa532d 100644 --- a/configure.ac +++ b/configure.ac @@ -3309,6 +3309,14 @@ AS_CASE(["$target_os"], ], [darwin*], [ RUBY_APPEND_OPTION(CFLAGS, -pipe) + AC_COMPILE_IFELSE([ + AC_LANG_BOOL_COMPILE_TRY([@%:@include <AvailabilityMacros.h>], + [MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_7])], + [dnl + RUBY_APPEND_OPTION(XLDFLAGS, [-framework Security]) + RUBY_APPEND_OPTION(LIBRUBYARG_STATIC, [-framework Security]) + ]dnl + ) RUBY_APPEND_OPTION(XLDFLAGS, [-framework Foundation]) RUBY_APPEND_OPTION(LIBRUBYARG_STATIC, [-framework Foundation]) ], |