diff options
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 29 |
1 files changed, 27 insertions, 2 deletions
diff --git a/configure.ac b/configure.ac index e8d9eaf87..d813c6b74 100644 --- a/configure.ac +++ b/configure.ac @@ -1,6 +1,6 @@ dnl Configure.ac script for GnuPG -dnl Copyright (C) 1998, 1999, 2000, 2001, 2002, -dnl 2003 Free Software Foundation, Inc. +dnl Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003 +dnl 2004 Free Software Foundation, Inc. dnl dnl This file is part of GnuPG. dnl @@ -309,6 +309,31 @@ AC_ARG_WITH(included-zlib, AC_MSG_RESULT($g10_force_zlib) dnl +dnl Check for the key/uid cache size. This can't be zero, but can be +dnl pretty small on embedded systems. +dnl +AC_MSG_CHECKING([for the size of the key and uid cache]) +AC_ARG_ENABLE(key-cache, + AC_HELP_STRING([--enable-key-cache=SIZE],[Set key cache to SIZE (default 4096)]),,enableval=4096) + +if test "$enableval" = "no"; then + enableval=5 +elif test "$enableval" = "yes" || test "$enableval" = ""; then + enableval=4096 +fi + +changequote(,)dnl +key_cache_size=`echo "$enableval" | sed 's/[A-Za-z]//g'` +changequote([,])dnl + +if test "$enableval" != "$key_cache_size" || test "$key_cache_size" -lt 5; then + AC_MSG_ERROR([invalid key-cache size]) +fi + +AC_MSG_RESULT($key_cache_size) +AC_DEFINE_UNQUOTED(PK_UID_CACHE_SIZE,$key_cache_size,[Size of the key and UID caches]) + +dnl dnl Check whether we want to use Linux capabilities dnl AC_MSG_CHECKING([whether use of capabilities is requested]) |