[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[FYI] Fix config/mailnotify because not everyone has sendmail in their P
From: |
Scott James Remnant |
Subject: |
[FYI] Fix config/mailnotify because not everyone has sendmail in their PATH |
Date: |
Thu, 12 Feb 2004 19:01:41 +0000 |
Applied to HEAD and branch-1-5.
Scott
--
Have you ever, ever felt like this?
Had strange things happen? Are you going round the twist?
diff -ruNp libtool-mailnotify-CVS~/ChangeLog libtool-mailnotify-CVS/ChangeLog
--- libtool-mailnotify-CVS~/ChangeLog 12 Feb 2004 18:41:26 -0000 1.1412
+++ libtool-mailnotify-CVS/ChangeLog 12 Feb 2004 18:56:59 -0000
@@ -0,0 +1,5 @@
+2004-02-12 Scott James Remnant <address@hidden>
+
+ * config/mailnotify (func_sendmail): Look for sendmail in a
+ couple of common non-PATH locations as well.
+
diff -ruNp libtool-mailnotify-CVS~/config/mailnotify
libtool-mailnotify-CVS/config/mailnotify
--- libtool-mailnotify-CVS~/config/mailnotify 12 Feb 2004 13:18:52 -0000
1.2
+++ libtool-mailnotify-CVS/config/mailnotify 12 Feb 2004 18:56:59 -0000
@@ -370,13 +370,21 @@
from_name=`echo "$my_from" | sed 's, *<.*> *$,,;s,",,g'`
from_addr=`echo "$my_from" | sed "$sed_mail_address"`
+ SENDMAIL=sendmail
+ for try_sendmail in sendmail /usr/lib/sendmail /usr/sbin/sendmail; do
+ if which $try_sendmail >/dev/null; then
+ SENDMAIL=$try_sendmail
+ break
+ fi
+ done
+
func_verbose "Delivering mail, please wait..."
if test -n "$from_name"; then
- sendmail -F "$from_name" -f "$from_addr" $my_destination < "$my_infile"
+ $SENDMAIL -F "$from_name" -f "$from_addr" $my_destination <
"$my_infile"
elif test -n "$from_addr"; then
- sendmail -f "$from_addr" $my_destination < "$my_infile"
+ $SENDMAIL -f "$from_addr" $my_destination < "$my_infile"
else
- sendmail $my_destination < "$my_infile"
+ $SENDMAIL $my_destination < "$my_infile"
fi
if test $? -eq 0; then
func_verbose "...succeeded."
signature.asc
Description: This is a digitally signed message part
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [FYI] Fix config/mailnotify because not everyone has sendmail in their PATH,
Scott James Remnant <=