AC_MSG_ERROR(no SUS compliant shell found - on Solaris, install SUNWxcu4)
fi
-
-AC_CHECK_HEADERS([arpa/nameser.h md5.h])
+AC_CHECK_HEADERS([arpa/nameser.h])
AC_CHECK_HEADERS([resolv.h],,,[
#include <sys/types.h>
AC_REPLACE_FUNCS([stpcpy strlcpy strlcat])
-have_md5=no
-if test "$ac_cv_header_md5_h" != no ; then
- AC_SEARCH_LIBS(MD5Init, [md], [have_md5=yes])
-fi
-
-if test "$have_md5" != yes ; then
- AC_LIBSOURCE(md5c.c)
- EXTRAOBJ="$EXTRAOBJ md5c.\$(OBJEXT)"
-fi
-
AC_CHECK_FUNC(getopt_long, [],
[AC_LIBSOURCES([getopt.c, getopt1.c])
EXTRAOBJ="$EXTRAOBJ getopt.\$(OBJEXT) getopt1.\$(OBJEXT)"])
AC_DEFINE_UNQUOTED(PID_DIR, "/var/run", directory for PID lock files)
+AC_ARG_ENABLE(pwmd,
+ [ --enable-pwmd enable Password Manager Daemon support],
+ , [enable_pwmd=no])
+
+if test "$enable_pwmd" = "yes"; then
+ PKG_CHECK_EXISTS([libpwmd], have_libpwmd=1,
+ AC_MSG_ERROR([Could not find libpwmd pkg-config module.]))
+
+
+ PKG_CHECK_MODULES([libpwmd], [libpwmd >= 6.0.0])
+ AM_CONDITIONAL(HAVE_LIBPWMD, true)
+ AC_DEFINE(HAVE_LIBPWMD, 1, [Define if you have libPWMD installed.])
+else
+ AM_CONDITIONAL(HAVE_LIBPWMD, false)
+fi
+
# We may have a fallback MDA available in case the socket open to the
# local SMTP listener fails. Best to use procmail for this, as we know
# it won't try delivering through local SMTP and cause a mail loop.
### use option --enable-opie to compile in the OPIE support
AC_ARG_ENABLE(opie,
[ --enable-opie support OTP through the OPIE library],
- [ AC_CHECK_HEADER(opie.h,, [AC_MSG_ERROR(cannot find <opie.h>, which is required for OPIE support.)])
- AC_CHECK_LIB(opie,opiegenerator,, [AC_MSG_ERROR(cannot find libopie, which is required for OPIE support.)])
+ [ AC_CHECK_HEADER(opie.h,, [AC_MSG_ERROR([cannot find <opie.h>, which is required for OPIE support.])])
+ AC_CHECK_LIB(opie,opiegenerator,, [AC_MSG_ERROR([cannot find libopie, which is required for OPIE support.])])
with_opie=$enableval],
[with_opie=no])
test "$with_opie" = "yes" && AC_DEFINE(OPIE_ENABLE,1,Define if you want OPIE support compiled in)