I prefer configurable RSYNCD_CONF by autoconf to RSYNCD_CONF in rsync.h.
--- rsync.h.orig Tue Feb 19 06:46:49 2002
+++ rsync.h Thu Feb 21 00:59:11 2002
@@ -26,7 +26,8 @@
#define RSYNC_RSH_ENV "RSYNC_RSH"
#define RSYNC_NAME "rsync"
-#define RSYNCD_CONF "/etc/rsyncd.conf"
+
+/* RSYNCD_CONF is always set in config.h */
#define DEFAULT_LOCK_FILE "/var/run/rsyncd.lock"
#define URL_PREFIX "rsync://"
--- configure.in.orig Wed Feb 20 08:40:47 2002
+++ configure.in Thu Feb 21 01:26:47 2002
@@ -85,6 +85,30 @@
AC_DEFINE_UNQUOTED(RSYNC_PATH, "$RSYNC_PATH", [location of rsync on
remote machine])
+AC_ARG_WITH(rsyncd-conf,
+ AC_HELP_STRING([--with-rsyncd-conf=PATH], [set configuration file for rsync
server to PATH (default: /etc/rsyncd.conf)]),
+ [ if test ! -z "$with_rsyncd_conf" ; then
+ case $with_rsyncd_conf in
+ yes)
+ RSYNCD_CONF="/etc/rsyncd.conf"
+ ;;
+ no)
+ RSYNCD_CONF="/etc/rsyncd.conf"
+ ;;
+ /*)
+ RSYNCD_CONF="$with_rsyncd_conf"
+ ;;
+ *)
+ AC_MSG_ERROR(You must specify an absolute path
to --with-rsyncd-conf=PATH)
+ ;;
+ esac
+ else
+ RSYNCD_CONF="/etc/rsyncd.conf"
+ fi ],
+ [ RSYNCD_CONF="/etc/rsyncd.conf" ])
+
+AC_DEFINE_UNQUOTED(RSYNCD_CONF, "$RSYNCD_CONF", [location of
configuration file for rsync server])
+
AC_ARG_WITH(rsh,
AC_HELP_STRING([--with-rsh=CMD], [set rsh command to CMD (default:
\"remsh\" or \"rsh\")]))
-- ayamura
Ayamura KIKUCHI, M.D., Ph.D.