From: thib <thib>
Date: Mon, 25 Feb 2002 18:41:09 +0000 (+0000)
Subject: added fcrondyn support
X-Git-Tag: ver1564~120
X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=726dc25afcd6f9c1ef2c4fdaf0018325b222b03c;p=fcron

added fcrondyn support
---

diff --git a/config.h.in b/config.h.in
index db8f04d..77b81c1 100644
--- a/config.h.in
+++ b/config.h.in
@@ -21,7 +21,7 @@
  *  `LICENSE' that comes with the fcron source distribution.
  */
 
- /* $Id: config.h.in,v 1.38 2001-12-23 22:05:03 thib Exp $ */
+ /* $Id: config.h.in,v 1.39 2002-02-25 18:44:26 thib Exp $ */
 
 
 /* *********************************************************** */
@@ -151,6 +151,8 @@
 /* where is located pid file ? */
 #undef PIDFILE
 
+/* 1 if we want to compile and install fcrondyn */
+#undef FCRONDYN
 #undef NOLOADAVG
 /* 1 if you want debug mode */
 #undef DEBUG
@@ -313,12 +315,18 @@
 /* Define if you have the <sys/ndir.h> header file.  */
 #undef HAVE_SYS_NDIR_H
 
+/* Define if you have the <sys/socket.h> header file.  */
+#undef HAVE_SYS_SOCKET_H
+
 /* Define if you have the <sys/termios.h> header file.  */
 #undef HAVE_SYS_TERMIOS_H
 
 /* Define if you have the <sys/time.h> header file.  */
 #undef HAVE_SYS_TIME_H
 
+/* Define if you have the <sys/types.h> header file.  */
+#undef HAVE_SYS_TYPES_H
+
 /* Define if you have <sys/wait.h> that is POSIX.1 compatible.  */
 #undef HAVE_SYS_WAIT_H
 
diff --git a/configure.in b/configure.in
index dff7eea..52cc5ab 100644
--- a/configure.in
+++ b/configure.in
@@ -41,6 +41,7 @@ AC_CHECK_HEADERS(errno.h sys/fcntl.h getopt.h limits.h)
 AC_CHECK_HEADERS(stdarg.h)
 AC_CHECK_HEADERS(sys/termios.h)
 AC_CHECK_HEADERS(strings.h)
+AC_CHECK_HEADERS(sys/types.h sys/socket.h)
 AC_CHECK_HEADERS(security/pam_appl.h)
 
 dnl Checks for typedefs, structures, and compiler characteristics.
@@ -526,6 +527,29 @@ USEPAM="$usepam"
 AC_SUBST(USEPAM)
 
 
+fcrondyn=1
+AC_MSG_CHECKING(if fcrondyn should be compiled)
+AC_ARG_WITH(fcrondyn,
+[ --with-fcrondyn=[yes|no]	Compile (or not) fcrondyn (default: yes).],
+[ case "$withval" in
+  no)
+    fcrondyn=0
+    AC_MSG_RESULT(no)
+    ;;
+  yes)
+    AC_MSG_RESULT(yes)
+    ;;
+  *)
+    AC_MSG_ERROR(Must be set to either "yes" or "no".)
+    ;;
+  esac ],
+  AC_MSG_RESULT(yes)
+)
+FCRONDYN="$fcrondyn"
+AC_DEFINE_UNQUOTED(FCRONDYN, "$fcrondyn")
+AC_SUBST(FCRONDYN)
+
+
 dnl ---------------------------------------------------------------------
 dnl Users and groups ...