From 2bfce03d292f8993ff82a9389b31d87c46d08770 Mon Sep 17 00:00:00 2001 From: Miroslav Lichvar Date: Fri, 24 Jun 2011 13:27:30 +0200 Subject: [PATCH] Add configure option for sendmail path --- configure | 6 ++++++ reference.c | 2 -- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/configure b/configure index 74c92e3..cb49808 100755 --- a/configure +++ b/configure @@ -103,6 +103,7 @@ For better control, use the options below. --disable-rtc Don't include RTC even on Linux --disable-linuxcaps Disable Linux capabilities support --enable-forcednsretry Force retry on DNS failure + --with-sendmail=PATH Path to sendmail binary [/usr/lib/sendmail] Fine tuning of the installation directories: --sysconfdir=DIR chrony.conf location [/etc] @@ -173,6 +174,7 @@ feat_pps=1 try_setsched=0 try_lockmem=0 feat_forcednsretry=0 +mail_program="/usr/lib/sendmail" for option do @@ -240,6 +242,9 @@ do --enable-forcednsretry) feat_forcednsretry=1 ;; + --with-sendmail=* ) + mail_program=`echo $option | sed -e 's/^.*=//;'` + ;; --host-system=* ) OPERATINGSYSTEM=`echo $option | sed -e 's/^.*=//;'` ;; @@ -500,6 +505,7 @@ if [ "x$SETDOCDIR" != "x" ]; then fi add_def DEFAULT_CONF_DIR "\"$SYSCONFDIR\"" +add_def MAIL_PROGRAM "\"$mail_program\"" if [ -f version.txt ]; then add_def CHRONY_VERSION "\"`cat version.txt`\"" diff --git a/reference.c b/reference.c index 8c77e40..cad321a 100644 --- a/reference.c +++ b/reference.c @@ -78,8 +78,6 @@ static double drift_file_age; static void update_drift_file(double, double); -#define MAIL_PROGRAM "/usr/lib/sendmail" - /* ================================================== */ static LOG_FileID logfileid;