summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorMike Brady <mikebrady@eircom.net>2019-04-05 16:21:58 +0100
committerMike Brady <mikebrady@eircom.net>2019-04-05 16:21:58 +0100
commit6d088ac4d9caea81a40a728e6aaf214f15f0c011 (patch)
treefdfd0c8dd1b1d0bcedb663663f891c44c0d381f7 /configure.ac
parent25765ef555c410687d99581a8e62e09a0266e1eb (diff)
reinstate the development branch README.md, stop including libdaemon automatically, improve some erro messages concerning -k / -d options.
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac46
1 files changed, 16 insertions, 30 deletions
diff --git a/configure.ac b/configure.ac
index 7379a65..e466adb 100644
--- a/configure.ac
+++ b/configure.ac
@@ -44,36 +44,6 @@ AM_CONDITIONAL([BUILD_FOR_OPENBSD], [test "x${with_os}" = xopenbsd ])
AC_ARG_WITH([pkg_config],
[ --with-pkg-config = use pkg-config to find libraries], ,[with_pkg_config=yes])
-# Look for libdaemon
-AC_ARG_WITH(libdaemon, [ --with-libdaemon = include support for daemonising in older non-systemd systems],
- if test "x${with_libdaemon}" = xyes ; then
- [AC_MSG_RESULT(>>Including libdaemon support for older systems)
- AC_DEFINE([CONFIG_LIBDAEMON], 1, [Include libdaemon])
- REQUESTED_LIBDAEMON=1
- if test "x${with_pkg_config}" = xyes ; then
- PKG_CHECK_MODULES(
- [DAEMON], [libdaemon],
- [LIBS="${DAEMON_LIBS} ${LIBS}"])
- else
- AC_CHECK_LIB([daemon],[daemon_fork], , AC_MSG_ERROR(libdaemon needed))
- fi
- ]
- fi,
- #default is to include libdaemon
- [AC_MSG_RESULT(>>Including libdaemon support for older systems)
- AC_DEFINE([CONFIG_LIBDAEMON], 1, [Include libdaemon])
- REQUESTED_LIBDAEMON=1
- if test "x${with_pkg_config}" = xyes ; then
- PKG_CHECK_MODULES(
- [DAEMON], [libdaemon],
- [LIBS="${DAEMON_LIBS} ${LIBS}"])
- else
- AC_CHECK_LIB([daemon],[daemon_fork], , AC_MSG_ERROR(libdaemon needed))
- fi
- ]
- )
-AM_CONDITIONAL([USE_LIBDAEMON], [test "x$REQUESTED_LIBDAEMON" = "x1"])
-
##### The following check for the pthreads library doesn't put the compiler into the correct pthread mode
##### so we add the -pthread compilation flag in AMFLAGS in the Makefile.am as well.
@@ -162,6 +132,22 @@ AC_ARG_WITH(piddir, [ --with-piddir=<pathname> Specify a pathname to a directory
AC_DEFINE([DEFINED_CUSTOM_PID_DIR],1,[Hook up special proc to libdaemon to point to this directory])], )
AM_CONDITIONAL([USE_CUSTOMPIDDIR], [test "x$REQUESTED_CUSTOMPIDDIR" = "x1"])
+
+# Look for libdaemon
+AC_ARG_WITH(libdaemon, [--with-libdaemon = include support for daemonising in non-systemd systems], REQUESTED_LIBDAEMON=1, )
+if test "x$REQUESTED_LIBDAEMON" = "x1"; then
+ AC_MSG_RESULT(>>Including libdaemon support for older systems)
+ AC_DEFINE([CONFIG_LIBDAEMON], 1, [Include libdaemon])
+ if test "x${with_pkg_config}" = xyes ; then
+ PKG_CHECK_MODULES(
+ [DAEMON], [libdaemon],
+ [LIBS="${DAEMON_LIBS} ${LIBS}"])
+ else
+ AC_CHECK_LIB([daemon],[daemon_fork], , AC_MSG_ERROR(libdaemon needed))
+ fi
+fi
+AM_CONDITIONAL([USE_LIBDAEMON], [test "x$REQUESTED_LIBDAEMON" = "x1"])
+
# Check --with-ssl=argument
AC_ARG_WITH(ssl, [ choose --with-ssl=openssl, --with-ssl=mbedtls or --with-ssl=polarssl (deprecated) for encryption services ], [
AC_MSG_CHECKING(encryption libraries chosen)