More prototypes.
[heimdal.git] / cf / framework-security.m4
blob3358292f4e6b2fea31efb80978fbf4000c7d20da
1 AC_DEFUN([rk_FRAMEWORK_SECURITY], [
3 AC_MSG_CHECKING([for framework security])
4 AC_CACHE_VAL(rk_cv_framework_security,
6 if test "$rk_cv_framework_security" != yes; then
7         ac_save_LIBS="$LIBS"
8         LIBS="$ac_save_LIBS -framework Security -framework CoreFoundation"
9         AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <Security/Security.h>
10 ]],
11 [[SecKeychainSearchRef searchRef;
12 SecKeychainSearchCreateFromAttributes(NULL,kSecCertificateItemClass,NULL, &searchRef);
13 CFRelease(&searchRef);
14 ]])],[rk_cv_framework_security=yes])
15         LIBS="$ac_save_LIBS"
19 if test "$rk_cv_framework_security" = yes; then
20    AC_DEFINE(HAVE_FRAMEWORK_SECURITY, 1, [Have -framework Security])
21    AC_MSG_RESULT(yes)
22 else
23    AC_MSG_RESULT(no)
25 AM_CONDITIONAL(FRAMEWORK_SECURITY, test "$rk_cv_framework_security" = yes)
27 if test "$rk_cv_framework_security" = yes; then
28    AC_NEED_PROTO([#include <Security/Security.h>],SecKeyGetCSPHandle)