1
  
2
  
3
  
4
  
5
  
6
  
7
  
8
  
9
  
10
  
11
  
12
  
13
  
14
  
15
  
16
  
17
  
18
  
19
  
20
  
21
  
22
  
23
  
24
  
25
  
26
  
27
  
28
  
29
  
30
  
31
  
32
  
33
  
34
  
35
  
36
  
37
  
38
  
39
  
40
  
41
  
42
  
43
  
44
  
45
  
46
  
47
  
48
  
49
  
50
  
51
  
52
  
53
  
54
  
55
  
56
  
57
  
58
  
59
  
60
  
61
  
62
  
# $Id: configure.in,v 1.16 2004/04/21 00:01:21 jhs Exp $ 
AC_INIT(nettle.cmod) 
AC_CONFIG_HEADER(nettle_config.h) 
 
AC_SET_MAKE 
 
AC_MODULE_INIT() 
 
if test "$with_nettle" = "no"; then 
  PIKE_FEATURE_WITHOUT(nettle) 
else 
  AC_CHECK_LIB(gmp, mpz_init) 
  AC_CHECK_LIB(gmp, __mpz_init) 
  AC_CHECK_LIB(gmp, __gmpz_init) 
  AC_CHECK_LIB(nettle, nettle_md5_init) 
  AC_CHECK_LIB(nettle, md5_init) 
 
  AC_SUBST(IDEA_OBJ) 
 
  if test "x$ac_cv_lib_nettle_nettle_md5_init" = "xyes" -o \ 
          "x$ac_cv_lib_nettle_md5_init" = "xyes"; then 
    PIKE_FEATURE_OK(Nettle) 
 
    # md4 is available in later versions of nettle 
    AC_CHECK_FUNCS(nettle_md4_init) 
 
    AC_MSG_CHECKING([for idea.c]) 
    # Have the patent-encumbered idea files been purged? 
    if test -f "$srcdir/idea.c" ; then 
      AC_MSG_RESULT([found]) 
      AC_DEFINE([WITH_IDEA], 1, [idea.c available]) 
      IDEA_OBJ=idea.o 
    else 
      AC_MSG_RESULT([no]) 
      IDEA_OBJ="" 
    fi 
  else 
    if test "$ac_cv_lib_gmp_mpz_init:$ac_cv_lib_gmp___mpz_init:$ac_cv_lib_gmp___gmpz_init" = "no:no:no"; then 
      # No gmp found; enable it if possible. 
      PIKE_ENABLE_BUNDLE(gmp, [ 
        ac_cv_lib_gmp_mpz_init 
        ac_cv_lib_gmp___mpz_init 
        ac_cv_lib_gmp___gmpz_init 
      ]) 
    fi 
    PIKE_ENABLE_BUNDLE(nettle, [ 
      ac_cv_lib_nettle_nettle_md5_init 
      ac_cv_lib_nettle_md5_init 
    ], [Cannot compile --with-nettle without the Nettle library. 
It is highly recommended that you install a working Nettle 
library on your system as that will add features to Pike 
required by many applications. These features include ciphers, 
hash algorithms and random generators. If you know that you do 
not need cryptographic functions, you can re-run configure 
with the option --without-nettle instead. 
    ]) 
    PIKE_FEATURE_NODEP(Nettle) 
  fi 
fi 
 
AC_OUTPUT(Makefile,echo FOO >stamp-h )