Bug 45152 - [PATCH] nullmailer's mailq and sendmail clash with system ones
Summary: [PATCH] nullmailer's mailq and sendmail clash with system ones
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Clive Lin
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2002-11-09 01:10 UTC by Aleksandr A Babaylov
Modified: 2002-11-24 19:12 UTC (History)
0 users

See Also:


Attachments
file.diff (2.79 KB, patch)
2002-11-09 01:10 UTC, Aleksandr A Babaylov
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Aleksandr A Babaylov 2002-11-09 01:10:01 UTC
	ports/mail/nullmailer installs /usr/local/bin/mailq and
	/usr/local/sbin/sendmail . $PATH controls
	which one will be used, or system sendmail will be
	used if full path is hardcoded.

Fix: /ets/mail/mailer.conf must be used and mailq and sendmail
	must be moved to directory not in $PATH

	New files files/patch-src-Makefile
	          files/patch-Makefile
	in ports tree

--- pkg-message	4 Mar 2001 13:13:42 -0000
+++ pkg-message	9 Nov 2002 00:20:44 -0000
@@ -4,6 +4,11 @@
 as an example and edit your own 
 %%PREFIX%%/etc/nullmailer/remotes
 
+Please refefine mailq and sendmail in your /etc/mail/mailer.conf:
+
+sendmail	%%PREFIX%%/libexec/nullmailer/sendmail
+mailq		%%PREFIX%%/libexec/nullmailer/mailq
+
 Also man nullmailer-send(8) for more details
 
 ==================================================================
--- pkg-plist	10 Mar 2001 03:24:54 -0000
+++ pkg-plist	9 Nov 2002 00:18:05 -0000
@@ -1,10 +1,10 @@
 libexec/nullmailer/smtp
 libexec/nullmailer/qmqp
-bin/mailq
+libexec/nullmailer/mailq
+libexec/nullmailer/sendmail
 bin/nullmailer-inject
 sbin/nullmailer-queue
 sbin/nullmailer-send
-sbin/sendmail
 etc/nullmailer/remotes.sample
 etc/rc.d/nullmail.sh
 @exec mkdir -p %%LOCALSTATEDIR%%/var/nullmailer/queue
How-To-Repeat: 	Look at ports/mail/nullmailer/pkg-plist or install
	ports/mail/nullmailer
Comment 1 Aleksandr A Babaylov 2002-11-09 22:43:52 UTC
> http://www.freebsd.org/cgi/query-pr.cgi?pr=45152
> >Category:       ports
> >Responsible:    freebsd-ports
> >Synopsis:       [PATCH] nullmailer's mailq and sendmail clash with system ones
> >Arrival-Date:   Fri Nov 08 17:10:01 PST 2002
Sorry, I was too quick.
Corrected patch:

--- pkg-message	4 Mar 2001 13:13:42 -0000
+++ pkg-message	9 Nov 2002 00:20:44 -0000
@@ -4,6 +4,11 @@
 as an example and edit your own 
 %%PREFIX%%/etc/nullmailer/remotes
 
+Please refefine mailq and sendmail in your /etc/mail/mailer.conf:
+
+sendmail	%%PREFIX%%/libexec/nullmailer/sendmail
+mailq		%%PREFIX%%/libexec/nullmailer/mailq
+
 Also man nullmailer-send(8) for more details
 
 ==================================================================
--- pkg-plist	10 Mar 2001 03:24:54 -0000
+++ pkg-plist	9 Nov 2002 00:18:05 -0000
@@ -1,10 +1,10 @@
 libexec/nullmailer/smtp
 libexec/nullmailer/qmqp
-bin/mailq
+libexec/nullmailer/mailq
+libexec/nullmailer/sendmail
 bin/nullmailer-inject
 sbin/nullmailer-queue
 sbin/nullmailer-send
-sbin/sendmail
 etc/nullmailer/remotes.sample
 etc/rc.d/nullmail.sh
 @exec mkdir -p %%LOCALSTATEDIR%%/var/nullmailer/queue
--- Makefile	24 Aug 2002 16:30:51 -0000
+++ Makefile	9 Nov 2002 06:41:14 -0000
@@ -8,7 +8,7 @@
 PORTNAME=	nullmailer
 # PORTVERSION=	1.00RC5
 PORTVERSION=	1.00r5
-PORTREVISION=	1
+PORTREVISION=	2
 CATEGORIES=	mail
 MASTER_SITES=	http://untroubled.org/nullmailer/
 # MASTER_SITE_SUBDIR=	${PORTVERSION}
--- files/patch-src-Makefile	Thu Jan  1 03:00:00 1970
+++ files/patch-src-Makefile	Sat Nov  9 09:40:44 2002
@@ -0,0 +1,66 @@
+--- src/Makefile.in	Sat Dec 30 07:22:57 2000
++++ src/Makefile.in	Sat Nov  9 09:34:23 2002
+@@ -68,9 +68,11 @@
+ STRIP = @STRIP@
+ VERSION = @VERSION@
+ 
+-bin_PROGRAMS =  	mailq 	nullmailer-inject
++libexecdir = @libexecdir@/nullmailer
+ 
+-sbin_PROGRAMS =  	nullmailer-queue 	nullmailer-send 	sendmail
++bin_PROGRAMS = nullmailer-inject
++libexec_PROGRAMS = mailq sendmail
++sbin_PROGRAMS = nullmailer-queue nullmailer-send
+ 
+ 
+ #noinst_PROGRAMS = address
+@@ -95,7 +97,7 @@
+ mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
+ CONFIG_HEADER = ../config.h
+ CONFIG_CLEAN_FILES = 
+-PROGRAMS =  $(bin_PROGRAMS) $(sbin_PROGRAMS)
++PROGRAMS =  $(bin_PROGRAMS) $(sbin_PROGRAMS) $(libexec_PROGRAMS)
+ 
+ 
+ DEFS = @DEFS@ -I. -I$(srcdir) -I..
+@@ -192,6 +194,31 @@
+ 	  rm -f $(DESTDIR)$(sbindir)/`echo $$p|sed 's/$(EXEEXT)$$//'|sed '$(transform)'|sed 's/$$/$(EXEEXT)/'`; \
+ 	done
+ 
++mostlyclean-libexecPROGRAMS:
++
++clean-libexecPROGRAMS:
++	-test -z "$(libexec_PROGRAMS)" || rm -f $(libexec_PROGRAMS)
++
++distclean-libexecPROGRAMS:
++
++maintainer-clean-libexecPROGRAMS:
++
++install-libexecPROGRAMS: $(libexec_PROGRAMS)
++	@$(NORMAL_INSTALL)
++	$(mkinstalldirs) $(DESTDIR)$(libexecdir)
++	@list='$(libexec_PROGRAMS)'; for p in $$list; do \
++	  if test -f $$p; then \
++	    echo "  $(INSTALL_PROGRAM) $(INSTALL_STRIP_FLAG) $$p $(DESTDIR)$(libexecdir)/`echo $$p|sed 's/$(EXEEXT)$$//'|sed '$(transform)'|sed 's/$$/$(EXEEXT)/'`"; \
++	     $(INSTALL_PROGRAM) $(INSTALL_STRIP_FLAG) $$p $(DESTDIR)$(libexecdir)/`echo $$p|sed 's/$(EXEEXT)$$//'|sed '$(transform)'|sed 's/$$/$(EXEEXT)/'`; \
++	  else :; fi; \
++	done
++
++uninstall-libexecPROGRAMS:
++	@$(NORMAL_UNINSTALL)
++	list='$(libexec_PROGRAMS)'; for p in $$list; do \
++	  rm -f $(DESTDIR)$(libexecdir)/`echo $$p|sed 's/$(EXEEXT)$$//'|sed '$(transform)'|sed 's/$$/$(EXEEXT)/'`; \
++	done
++
+ .c.o:
+ 	$(COMPILE) -c $<
+ 
+@@ -308,7 +335,7 @@
+ check: check-am
+ installcheck-am:
+ installcheck: installcheck-am
+-install-exec-am: install-binPROGRAMS install-sbinPROGRAMS
++install-exec-am: install-binPROGRAMS install-sbinPROGRAMS install-libexecPROGRAMS
+ install-exec: install-exec-am
+ 
+ install-data-am:
--- files/patch-Makefile	Thu Jan  1 03:00:00 1970
+++ files/patch-Makefile	Sat Nov  9 10:28:04 2002
@@ -0,0 +1,22 @@
+--- Makefile.in	Sat Dec 30 07:22:51 2000
++++ Makefile.in	Sat Nov  9 10:16:13 2002
+@@ -66,6 +66,8 @@
+ STRIP = @STRIP@
+ VERSION = @VERSION@
+ 
++libexecdir = @libexecdir@/nullmailer
++
+ localstatedir = @localstatedir@/nullmailer
+ sysconfdir = @sysconfdir@/nullmailer
+ 
+@@ -368,8 +370,8 @@
+ 	chown nullmail $(DESTDIR)$(localstatedir)/*
+ 	chown nullmail $(DESTDIR)$(sbindir)/nullmailer-queue
+ 	chmod u+s $(DESTDIR)$(sbindir)/nullmailer-queue
+-	chown nullmail $(DESTDIR)$(bindir)/mailq
+-	chmod u+s $(DESTDIR)$(bindir)/mailq
++	chown nullmail $(DESTDIR)$(libexecdir)/mailq
++	chmod u+s $(DESTDIR)$(libexecdir)/mailq
+ 
+ dist-hook:
+ 	sed -e s/@VERSION\@/@VERSION@/ \


-- 
@BABOLO      http://links.ru/
Comment 2 Ying-Chieh Liao freebsd_committer freebsd_triage 2002-11-11 16:44:47 UTC
Responsible Changed
From-To: freebsd-ports->clive

over to maintainer
Comment 3 clive 2002-11-11 16:55:46 UTC
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

place nullmailer's mailq and sendmail in /etc/mail/mail.conf is a bad
idea. It's mailq is not good enough last time I tried. It's sendmail
is even worse; it makes daily periodic sciprt mail output crazy. The
condition is, daily/weekly/monthly periodic script outputs are meant
to be delivered locally, not piped to smtp servers.

IMHO, nullmailer's mailq and sendmail are not good replacement for
regular mailq && sendmail.

Clive


On Mon, Nov 11, 2002 at 08:44:54AM -0800, Ying-Chieh Liao wrote:
> Synopsis: [PATCH] nullmailer's mailq and sendmail clash with system ones
> 
> Responsible-Changed-From-To: freebsd-ports->clive
> Responsible-Changed-By: ijliao
> Responsible-Changed-When: Mon Nov 11 08:44:47 PST 2002
> Responsible-Changed-Why: 
> over to maintainer
> 
> http://www.freebsd.org/cgi/query-pr.cgi?pr=45152
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.1 (FreeBSD)

iD8DBQE9z+C8dFUoBaAIwD4RAvJUAJsGJz8i+WMv4+llwObq2K8oAdvbMACdG30J
G9Fjy2m+NLX+KnFmUVoNy8U=
=lOj6
-----END PGP SIGNATURE-----
Comment 4 Aleksandr A Babaylov 2002-11-12 00:05:50 UTC
> 
> place nullmailer's mailq and sendmail in /etc/mail/mail.conf is a bad
> idea. It's mailq is not good enough last time I tried. It's sendmail
> is even worse; it makes daily periodic sciprt mail output crazy. The
> condition is, daily/weekly/monthly periodic script outputs are meant
> to be delivered locally, not piped to smtp servers.
> 
> IMHO, nullmailer's mailq and sendmail are not good replacement for
> regular mailq && sendmail.
Yes, you are right in common case.
This is reason to my proposition.
_If_ do not want nullmail's mailq/sendmail,
do _not_ edit /etc/mail/mail.conf.

But _if_ do not want any local mail,
_do_ substitute at least sendmail (and send-mail)
in /etc/mail/mail.conf.

In current state choose of native or nullmailer's
sendmail/mailq depends on order of paths in $PATH
instead of sysadmins choose.

nullmailer port is {careful|provident|attentive|anxious|solicitous|
|mindful|thoughtful|heedful|jealous|regardful|tender|advertent|
|overwarm|considerate|forethoughtful|sisterly|attent}
(sorry, I can't choose right word here)
in respect to change system files for/instead of
sysadmin, and I do _NOT_ want include /etc/mail/mail.conf
in that list of files tuned by port.

May be text as:

... if you want substitute system mailq/sendmail
by nullmailer's mailq/sendmail do ...

in pkg-message is better?

My main goal is to move mailq/sendmail from
$PATH, not substitute mailq/sendmail by default.

Sorry, my English is not good for good wording.

-- 
@BABOLO      http://links.ru/
Comment 5 Clive Lin freebsd_committer freebsd_triage 2002-11-24 19:12:00 UTC
State Changed
From-To: open->closed

Committed, thanks.