Subject: bin/9409: sendmail-8.9.3: smrsh installed in wrong place and uses wrong sm.bin
To: None <gnats-bugs@gnats.netbsd.org>
From: None <jbernard@mines.edu>
List: netbsd-bugs
Date: 02/13/2000 12:17:26
>Number:         9409
>Category:       bin
>Synopsis:       smrsh installed in wrong place and uses wrong sm.bin
>Confidential:   no
>Severity:       serious
>Priority:       high
>Responsible:    bin-bug-people (Utility Bug People)
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sun Feb 13 12:15:00 2000
>Last-Modified:
>Originator:     Jim Bernard
>Organization:
	Speaking for myself
>Release:        Feb. 12, 2000
>Environment:
System: NetBSD zoo 1.4S NetBSD 1.4S (ZOO) #0: Sat Feb 12 12:21:08 MST 2000 local@zoo:/home/tmp/compile/sys/arch/i386/compile/ZOO i386


>Description:
	The newly imported sendmail 8.9.3 distribution installs smrsh in
	/usr/sbin instead of /usr/libexec (where it used to be, and where
	distrib/sets/lists/base/mi still says it's supposed to be.

	Also, smrsh looks in /usr/adm/sm.bin for binaries it's allowed to
	execute, instead of /usr/libexec/sm.bin, where smrsh from sendmail
	8.8.8 looked.  But we have no /usr/adm, hence no /usr/adm/sm.bin.

>How-To-Repeat:
	Install -current after recent import of sendmail 8.9.3.  Note that
	mail breaks after modifying sendmail.cf to find smrsh in /usr/sbin
	(showing that smrsh itself is not finding its binaries).  Run strings
	on /usr/sbin/smrsh and discover that it's looking in /usr/adm/sm.bin,
	which doesn't (and shouldn't) exist.  Note that there's no evidence
	of an intentional move of smrsh to /usr/sbin.

>Fix:
	Add customization of BINDIR and CMDDIR to smrsh Makefile, like in
	the previous version:

--- Makefile-dist	Tue Feb  8 06:45:36 2000
+++ Makefile	Sun Feb 13 12:46:10 2000
@@ -3,11 +3,13 @@
 .include <bsd.own.mk>
 
 DIST=		${.CURDIR}/../../../dist
 .PATH: ${DIST}/sendmail/smrsh
 
+BINDIR=		/usr/libexec
 PROG=		smrsh
 
 MAN=		smrsh.8
 CPPFLAGS+=	-I${DIST}/sendmail/src
+CPPFLAGS+=	-DCMDDIR=\"/usr/libexec/sm.bin\"
 
 .include <bsd.prog.mk>
>Audit-Trail:
>Unformatted: