--- ./man/Makefile Wed Aug 24 14:52:00 1994 +++ ../procmail-3.22/./man/Makefile Mon Mar 31 14:53:35 2003 @@ -1,16 +1,157 @@ -#$Id: Makefile,v 1.7 1994/08/24 18:52:00 berg Exp $ -all: init - $(MAKE) make $@ +LOCKINGTEST=__defaults__ -# The only real thing that can be made right now is: +#LOCKINGTEST=/tmp . # Uncomment and add any directories you see fit. +# If LOCKINGTEST is defined, autoconf will NOT +# prompt you to enter additional directories. +# See INSTALL for more information about the +# significance of the locking tests. + +######################################################################## +# Only edit below this line if you *think* you know what you are doing # +######################################################################## + +#LOCKINGTEST=100 # Uncomment (and change) if you think you know +# it better than the autoconf lockingtests. +# This will cause the lockingtests to be hotwired. +# 100 to enable fcntl() +# 010 to enable lockf() +# 001 to enable flock() +# Or them together to get the desired combination. + +# Optional system libraries we search for +SEARCHLIBS = -lm -ldir -lx -lsocket -lnet -linet -lnsl_s -lnsl_i -lnsl -lsun \ + -lgen -lsockdns -ldl +# -lresolv # not really needed, is it? + +# Informal list of directories where we look for the libraries in SEARCHLIBS +LIBPATHS=/lib /usr/lib /usr/local/lib + +GCC_WARNINGS = -O2 -pedantic -Wreturn-type -Wunused -Wformat -Wtraditional \ + -Wpointer-arith -Wconversion -Waggregate-return \ + #-Wimplicit -Wshadow -Wid-clash-6 #-Wuninitialized + +# The place to put your favourite extra cc flag +CFLAGS0 = -O #$(GCC_WARNINGS) +LDFLAGS0= -s +# Read my libs :-) +LIBS= + +CFLAGS1 = $(CFLAGS0) #-posix -Xp +LDFLAGS1= $(LDFLAGS0) $(LIBS) #-lcposix + +####CC = cc # gcc +# object file extension +O = o +RM = /bin/rm -f +MV = mv -f +LN = ln +BSHELL = /bin/sh +INSTALL = cp +DEVNULL = /dev/null +STRIP = strip +MKDIRS = new/mkinstalldirs + +SUBDIRS = src man +BINSS = procmail lockfile formail mailstat +MANS1S = procmail formail lockfile +MANS5S = procmailrc procmailsc procmailex + +# Possible locations for the sendmail.cf file +SENDMAILCFS = /etc/mail/sendmail.cf /etc/sendmail.cf /usr/lib/sendmail.cf + +# Makefile.1 - mark, don't (re)move this, a sed script needs it + +FGREP = grep -F +STRIP = +CFLAGS = $(CFLAGS1) +LDFLAGS = $(LDFLAGS1) -lm -lsocket -lnsl -lsun -lgen -ldl -lc + +BINS= new/procmail new/lockfile new/formail new/mailstat +MANS= new/procmail.1 new/formail.1 new/lockfile.1 new/procmailrc.5 new/procmailsc.5 new/procmailex.5 +MANS1= procmail.$(MAN1SUFFIX) formail.$(MAN1SUFFIX) lockfile.$(MAN1SUFFIX) +MANS5= procmailrc.$(MAN5SUFFIX) procmailsc.$(MAN5SUFFIX) procmailex.$(MAN5SUFFIX) +MANSS= procmail.1 formail.1 lockfile.1 procmailrc.5 procmailsc.5 procmailex.5 +NBINS= ../new/procmail ../new/lockfile ../new/formail ../new/mailstat +NMANS= ../new/procmail.1 ../new/formail.1 ../new/lockfile.1 ../new/procmailrc.5 ../new/procmailsc.5 ../new/procmailex.5 -init: - cd ..; $(MAKE) make init + +#$Id: Makefile.0,v 1.9 1994/09/27 15:03:36 berg Exp $ + +all: $(MANSS) +make: + @$(SHELL) -c "exit 0" + .PRECIOUS: Makefile -Makefile makefile Makefiles makefiles: init +../config.check: + @cd ..; $(MAKE) config.check + +man.sed: man_sed + +man_sed: + @cd ../src; $(MAKE) ../man/man.sed + +clean: + $(RM) $(MANSS) man.sed* _Makefile *core* + +Makefile: ../Makefile Makefile.0 + @echo "You have made changes to the master Makefile, in order for" + @echo "these changes to show through, you will first have to do:" + @echo "$(MAKE) makefiles" + +makefiles Makefiles makefile: + cd ..; $(MAKE) makefiles + +init: + cd ..; $(MAKE) $@ -procmail.1 procmailrc.5 procmailsc.5 procmailex.5 lockfile.1 formail.1: init - $(MAKE) make $@ +../new/procmail.1: procmail.1 ../config.check + @test -d ../new || mkdir ../new + @$(RM) $@ + $(LN) ../man/procmail.1 $@ + +../new/formail.1: formail.1 ../config.check + @test -d ../new || mkdir ../new + @$(RM) $@ + $(LN) ../man/formail.1 $@ + +../new/lockfile.1: lockfile.1 ../config.check + @test -d ../new || mkdir ../new + @$(RM) $@ + $(LN) ../man/lockfile.1 $@ + +../new/procmailrc.5: procmailrc.5 ../config.check + @test -d ../new || mkdir ../new + @$(RM) $@ + $(LN) ../man/procmailrc.5 $@ + +../new/procmailsc.5: procmailsc.5 ../config.check + @test -d ../new || mkdir ../new + @$(RM) $@ + $(LN) ../man/procmailsc.5 $@ + +../new/procmailex.5: procmailex.5 ../config.check + @test -d ../new || mkdir ../new + @$(RM) $@ + $(LN) ../man/procmailex.5 $@ + +procmail.1: procmail.man man.sed mansed + $(SHELL) ./mansed $(SHELL) procmail.man $@ "$(RM)" $(DEVNULL) + +formail.1: formail.man man.sed mansed + $(SHELL) ./mansed $(SHELL) formail.man $@ "$(RM)" $(DEVNULL) + +lockfile.1: lockfile.man man.sed mansed + $(SHELL) ./mansed $(SHELL) lockfile.man $@ "$(RM)" $(DEVNULL) + +procmailrc.5: procmailrc.man man.sed mansed + $(SHELL) ./mansed $(SHELL) procmailrc.man $@ "$(RM)" $(DEVNULL) + +procmailsc.5: procmailsc.man man.sed mansed + $(SHELL) ./mansed $(SHELL) procmailsc.man $@ "$(RM)" $(DEVNULL) + +procmailex.5: procmailex.man man.sed mansed + $(SHELL) ./mansed $(SHELL) procmailex.man $@ "$(RM)" $(DEVNULL) +# --- ./src/pipes.c Tue Sep 11 00:58:44 2001 +++ ../procmail-3.22/./src/pipes.c Mon Mar 31 14:55:03 2003 @@ -194,7 +194,7 @@ makeblock(&temp,Stdfilled); tmemmove(temp.p,Stdout,Stdfilled); readdyn(&temp,&Stdfilled,Stdfilled+backlen+1); - Stdout=realloc(Stdout,&Stdfilled+1); + Stdout=realloc(Stdout,Stdfilled+1); tmemmove(Stdout,temp.p,Stdfilled+1); freeblock(&temp); retStdout(Stdout,pwait&&pipw,!backblock); @@ -244,7 +244,7 @@ { rclose(PWRO); return -1; /* dump mail in the pipe */ } - if((len=dump(PWRO,ft_PIPE,source,len))&&(!ignwerr||(len=0))) + if((len=dump(PWRO,ft_PIPE,source,len))&&(!ignwerr||(len==0))) writeerr(line); /* pipe was shut in our face, get mad */ ;{ int excode; /* optionally check the exitcode */ if(pwait&&(excode=waitfor(pidchild))!=EXIT_SUCCESS) --- ./src/mailfold.c Tue Sep 11 00:58:34 2001 +++ ../procmail-3.22/./src/mailfold.c Mon Mar 31 14:53:35 2003 @@ -185,7 +185,7 @@ } if(!rlink(buf2,buf,0)) /* try rename-via-link */ opn: unlink(buf2); /* success; remove the original */ - else if(errno=EEXIST||!stat(buf,&stbuf)||errno!=ENOENT||rename(buf2,buf)) + else if(errno==EEXIST||!stat(buf,&stbuf)||errno!=ENOENT||rename(buf2,buf)) ret: return -1; /* rename it, but only if it won't replace an existing file */ setlastfolder(buf); return opena(buf); --- ./src/Makefile Sun Dec 31 01:08:16 2000 +++ ../procmail-3.22/./src/Makefile Mon Mar 31 14:53:35 2003 @@ -1,17 +1,300 @@ -#$Id: Makefile,v 1.9 2000/09/28 01:23:11 guenther Exp $ -all: init - $(MAKE) make $@ +LOCKINGTEST=__defaults__ -# The only real thing that can be made right now is: +#LOCKINGTEST=/tmp . # Uncomment and add any directories you see fit. +# If LOCKINGTEST is defined, autoconf will NOT +# prompt you to enter additional directories. +# See INSTALL for more information about the +# significance of the locking tests. -init: - cd ..; $(MAKE) make init +######################################################################## +# Only edit below this line if you *think* you know what you are doing # +######################################################################## + +#LOCKINGTEST=100 # Uncomment (and change) if you think you know +# it better than the autoconf lockingtests. +# This will cause the lockingtests to be hotwired. +# 100 to enable fcntl() +# 010 to enable lockf() +# 001 to enable flock() +# Or them together to get the desired combination. + +# Optional system libraries we search for +SEARCHLIBS = -lm -ldir -lx -lsocket -lnet -linet -lnsl_s -lnsl_i -lnsl -lsun \ + -lgen -lsockdns -ldl +# -lresolv # not really needed, is it? + +# Informal list of directories where we look for the libraries in SEARCHLIBS +LIBPATHS=/lib /usr/lib /usr/local/lib + +GCC_WARNINGS = -O2 -pedantic -Wreturn-type -Wunused -Wformat -Wtraditional \ + -Wpointer-arith -Wconversion -Waggregate-return \ + #-Wimplicit -Wshadow -Wid-clash-6 #-Wuninitialized + +# The place to put your favourite extra cc flag +CFLAGS0 = -O #$(GCC_WARNINGS) +LDFLAGS0= -s +# Read my libs :-) +LIBS= + +CFLAGS1 = $(CFLAGS0) #-posix -Xp +LDFLAGS1= $(LDFLAGS0) $(LIBS) #-lcposix + +####CC = cc # gcc +# object file extension +O = o +RM = /bin/rm -f +MV = mv -f +LN = ln +BSHELL = /bin/sh +INSTALL = cp +DEVNULL = /dev/null +STRIP = strip +MKDIRS = new/mkinstalldirs + +SUBDIRS = src man +BINSS = procmail lockfile formail mailstat +MANS1S = procmail formail lockfile +MANS5S = procmailrc procmailsc procmailex + +# Possible locations for the sendmail.cf file +SENDMAILCFS = /etc/mail/sendmail.cf /etc/sendmail.cf /usr/lib/sendmail.cf +# Makefile.1 - mark, don't (re)move this, a sed script needs it + +FGREP = grep -F +STRIP = +CFLAGS = $(CFLAGS1) +LDFLAGS = $(LDFLAGS1) -lm -lsocket -lnsl -lsun -lgen -ldl -lc + +BINS= new/procmail new/lockfile new/formail new/mailstat +MANS= new/procmail.1 new/formail.1 new/lockfile.1 new/procmailrc.5 new/procmailsc.5 new/procmailex.5 +MANS1= procmail.$(MAN1SUFFIX) formail.$(MAN1SUFFIX) lockfile.$(MAN1SUFFIX) +MANS5= procmailrc.$(MAN5SUFFIX) procmailsc.$(MAN5SUFFIX) procmailex.$(MAN5SUFFIX) +MANSS= procmail.1 formail.1 lockfile.1 procmailrc.5 procmailsc.5 procmailex.5 +NBINS= ../new/procmail ../new/lockfile ../new/formail ../new/mailstat +NMANS= ../new/procmail.1 ../new/formail.1 ../new/lockfile.1 ../new/procmailrc.5 ../new/procmailsc.5 ../new/procmailex.5 + +#$Id: Makefile.0,v 1.63 2001/06/21 11:59:25 guenther Exp $ + +PM_OBJ=cstdio.$(O) common.$(O) exopen.$(O) goodies.$(O) locking.$(O) \ + mailfold.$(O) foldinfo.$(O) misc.$(O) pipes.$(O) regexp.$(O) robust.$(O) \ + sublib.$(O) acommon.$(O) mcommon.$(O) lastdirsep.$(O) authenticate.$(O) \ + lmtp.$(O) memblk.$(O) variables.$(O) from.$(O) comsat.$(O) +LF_OBJ=exopen.$(O) sublib.$(O) acommon.$(O) mcommon.$(O) authenticate.$(O) \ + lastdirsep.$(O) +FM_OBJ=common.$(O) fields.$(O) formisc.$(O) sublib.$(O) ecommon.$(O) \ + acommon.$(O) +MG_OBJ=sublib.$(O) ecommon.$(O) mcommon.$(O) hsort.$(O) lastdirsep.$(O) + +all: $(BINSS) + +make: # fake target + @$(SHELL) -c "exit 0" + .PRECIOUS: Makefile -Makefile makefile Makefiles makefiles: init +procmail: procmail.$(O) $(PM_OBJ) setid + $(CC) $(CFLAGS) $@.$(O) $(PM_OBJ) -o $@ $(LDFLAGS) + @test -z "$(STRIP)" || ( echo $(STRIP) $@; $(STRIP) $@ ) + +lockfile: lockfile.$(O) $(LF_OBJ) + $(CC) $(CFLAGS) $@.$(O) $(LF_OBJ) -o $@ $(LDFLAGS) + @test -z "$(STRIP)" || ( echo $(STRIP) $@; $(STRIP) $@ ) + +formail: formail.$(O) $(FM_OBJ) + $(CC) $(CFLAGS) $@.$(O) $(FM_OBJ) -o $@ $(LDFLAGS) + @test -z "$(STRIP)" || ( echo $(STRIP) $@; $(STRIP) $@ ) + +mailstat: ../examples/mailstat + cp ../examples/$@ $@ + @chmod 0755 $@ + +multigram: multigram.$(O) $(MG_OBJ) setid + $(CC) $(CFLAGS) $@.$(O) $(MG_OBJ) -o $@ $(LDFLAGS) + +../config.check: + @cd ..; $(MAKE) config.check + +_autotst: _autotst.$(O) sublib.c sublib.h + $(CC) $(CFLAGS) $@.$(O) -o $@ $(LDFLAGS) + +../autoconf.h: autoconf Makefile ../patchlevel.h + @echo No this was not make -n >make_n + $(SHELL) ./autoconf $(SHELL) "$(RM)" "$(MV)" $(DEVNULL) \ + "$(FGREP)" "$(MAKE)" $(O) "$(LOCKINGTEST)" \ + "$(VISIBLE_BINDIR)" $@ + +autoconf.h: ../autoconf.h + +targetdir.h: + echo "You only can/need to make multigram if you are installing" + echo "the mailinglist scripts. Read ../SmartList/INSTALL for" + echo "more directions." + exit 64 + +acommon.$(O): ../autoconf.h ../config.h includes.h acommon.h robust.h shell.h + +authenticate.$(O): ../autoconf.h ../config.h includes.h robust.h shell.h +authenticate.$(O): misc.h authenticate.h authenticate.c + $(CC) -c -DPROCMAIL $(CFLAGS) $*.c + +common.$(O): ../autoconf.h ../config.h includes.h procmail.h sublib.h robust.h +common.$(O): shell.h misc.h common.h + +comsat.$(O): ../autoconf.h ../config.h includes.h procmail.h sublib.h robust.h +comsat.$(O): shell.h common.h mailfold.h variables.h comsat.h network.h + +cstdio.$(O): ../autoconf.h ../config.h includes.h procmail.h robust.h cstdio.h +cstdio.$(O): misc.h shell.h variables.h + +ecommon.$(O): ../autoconf.h ../config.h includes.h ecommon.h common.h shell.h + +exopen.$(O): ../autoconf.h ../config.h includes.h procmail.h acommon.h robust.h +exopen.$(O): misc.h exopen.h + +fields.$(O): ../autoconf.h ../config.h includes.h formail.h sublib.h shell.h +fields.$(O): common.h fields.h ecommon.h formisc.h + +foldinfo.$(O): ../autoconf.h ../config.h includes.h procmail.h misc.h +foldinfo.$(O): lastdirsep.h robust.h exopen.h foldinfo.h + +formail.$(O): ../autoconf.h ../config.h includes.h formail.h acommon.h sublib.h +formail.$(O): shell.h common.h fields.h ecommon.h formisc.h header.h +formail.$(O): ../patchlevel.h + +formisc.$(O): ../autoconf.h ../config.h includes.h formail.h sublib.h shell.h +formisc.$(O): common.h ecommon.h formisc.h + +goodies.$(O): ../autoconf.h ../config.h includes.h procmail.h sublib.h robust.h +goodies.$(O): shell.h misc.h pipes.h common.h cstdio.h variables.h goodies.h + +hsort.$(O): ../autoconf.h ../config.h includes.h hsort.h + +lastdirsep.$(O): ../autoconf.h ../config.h includes.h lastdirsep.h + +lmtp.$(O): ../autoconf.h ../config.h includes.h procmail.h sublib.h robust.h +lmtp.$(O): shell.h misc.h common.h authenticate.h cstdio.h +lmtp.$(O): mailfold.h lmtp.h memblk.h foldinfo.h from.h + +lockfile.$(O): ../autoconf.h ../config.h includes.h sublib.h exopen.h mcommon.h +lockfile.$(O): authenticate.h ../patchlevel.h + +locking.$(O): ../autoconf.h ../config.h includes.h procmail.h robust.h shell.h +locking.$(O): misc.h pipes.h exopen.h locking.h lastdirsep.h + +mailfold.$(O): ../autoconf.h ../config.h includes.h procmail.h acommon.h +mailfold.$(O): sublib.h robust.h shell.h misc.h pipes.h common.h exopen.h +mailfold.$(O): variables.h locking.h mailfold.h memblk.h from.h + +mcommon.$(O): ../autoconf.h ../config.h includes.h mcommon.h + +memblk.$(O): ../autoconf.h ../config.h includes.h procmail.h shell.h +memblk.$(O): exopen.h memblk.h + +misc.$(O): ../autoconf.h ../config.h includes.h procmail.h +misc.$(O): acommon.h sublib.h robust.h shell.h misc.h pipes.h common.h cstdio.h +misc.$(O): exopen.h regexp.h mcommon.h goodies.h locking.h comsat.h mailfold.h +misc.$(O): lastdirsep.h authenticate.h memblk.h foldinfo.h variables.h + +multigram.$(O): ../autoconf.h ../config.h includes.h sublib.h hsort.h shell.h +multigram.$(O): ecommon.h mcommon.h lastdirsep.h targetdir.h + +pipes.$(O): ../autoconf.h ../config.h includes.h procmail.h robust.h shell.h +pipes.$(O): misc.h pipes.h common.h cstdio.h mcommon.h variables.h memblk.h +pipes.$(O): mailfold.h + +procmail.$(O): ../patchlevel.h ../autoconf.h ../config.h includes.h procmail.h +procmail.$(O): acommon.h sublib.h robust.h shell.h misc.h pipes.h common.h +procmail.$(O): cstdio.h exopen.h regexp.h mcommon.h goodies.h locking.h +procmail.$(O): mailfold.h lastdirsep.h authenticate.h lmtp.h memblk.h +procmail.$(O): variables.h comsat.h from.h + +regexp.$(O): ../autoconf.h ../config.h includes.h procmail.h sublib.h robust.h +regexp.$(O): shell.h misc.h regexp.h variables.h + +robust.$(O): ../autoconf.h ../config.h includes.h procmail.h robust.h shell.h +robust.$(O): misc.h pipes.h common.h mailfold.h shell.h + +sublib.$(O): ../autoconf.h ../config.h includes.h sublib.h shell.h + +variables.$(O): ../autoconf.h ../config.h includes.h procmail.h shell.h +variables.$(O): authenticate.h goodies.h misc.h comsat.h variables.h + +from.$(O): ../autoconf.h ../config.h includes.h procmail.h robust.h shell.h +from.$(O): memblk.h from.h + +gethome.$(O) setid.$(O) recommend.$(O): ../autoconf.h ../config.h includes.h + +gethome.$(O): gethome.c + @$(CC) -c $(CFLAGS) $*.c + +setid.$(O): setid.c + @$(CC) -c $(CFLAGS) $*.c + +recommend.$(O): recommend.c + @$(CC) -c $(CFLAGS) $*.c + +.c.$(O): + $(CC) -c $(CFLAGS) $< + +gethome: gethome.$(O) setid + @$(CC) $(CFLAGS) $@.$(O) -o $@ $(LDFLAGS) + +getparams: + @echo "ln=\"$(LN)\"" >../SmartList/targetdir.tmp + +setid: setid.$(O) + @$(CC) $(CFLAGS) $@.$(O) -o $@ $(LDFLAGS) + +recommend: recommend.$(O) sublib.$(O) + @$(CC) $(CFLAGS) $@.$(O) sublib.$(O) -o $@ $(LDFLAGS) + +../man/man.sed: manconf.c ../autoconf.h ../config.h includes.h procmail.h +../man/man.sed: ../patchlevel.h + @$(CC) $(CFLAGS) "-DBINDIR=\"$(VISIBLE_BINDIR)\"" -o _autotst \ + manconf.c $(LDFLAGS) + @./_autotst $@ + @echo Housekeeping file >$@ + @$(RM) _autotst + +clean: + $(RM) -r _locktest + $(RM) procmail.$(O) $(PM_OBJ) lockfile.$(O) $(LF_OBJ) formail.$O \ + $(FM_OBJ) multigram.$(O) $(MG_OBJ) $(BINSS) multigram ../autoconf.h \ + _autotst* lookfor _locktst* grepfor recommend recommend.$(O) manconf \ + _Makefile lock.log *core* targetdir.h setid setid.$(O) gethome \ + gethome.$(O) make_n realloc.log + +Makefile: ../Makefile Makefile.0 + @echo "You have made changes to the master Makefile, in order for" + @echo "these changes to show through, you will first have to do:" + @echo "$(MAKE) makefiles" + +makefiles Makefiles makefile: + cd ..; $(MAKE) makefiles + +init: + cd ..; $(MAKE) $@ +VISIBLE_BINDIR=/usr/bin + +../new/procmail: procmail ../config.check + @test -d ../new || mkdir ../new + @$(RM) $@ + $(LN) ../src/procmail $@ + +../new/lockfile: lockfile ../config.check + @test -d ../new || mkdir ../new + @$(RM) $@ + $(LN) ../src/lockfile $@ + +../new/formail: formail ../config.check + @test -d ../new || mkdir ../new + @$(RM) $@ + $(LN) ../src/formail $@ -procmail lockfile formail multigram mailstat setid getparams gethome \ -../autoconf.h autoconf.h: init - $(MAKE) make $@ +../new/mailstat: mailstat ../config.check + @test -d ../new || mkdir ../new + @$(RM) $@ + $(LN) ../src/mailstat $@ +# --- ./src/procmail.c Tue Sep 11 00:59:14 2001 +++ ../procmail-3.22/./src/procmail.c Mon Mar 31 14:55:50 2003 @@ -652,8 +652,7 @@ nrcond= -1; if(tolock) /* clear temporary buffer for lockfile name */ free(tolock); - for(i=maxindex(flags);i;i--) /* clear the flags */ - flags[i]=0; + bbzero(flags,sizeof(flags)); /* clear the flags */ for(tolock=0,locknext=0;;) { chp=skpspace(chp); switch(i= *chp++) --- ./src/lmtp.c Thu Jun 28 22:20:51 2001 +++ ../procmail-3.22/./src/lmtp.c Mon Mar 31 14:53:35 2003 @@ -51,7 +51,7 @@ int childserverpid; -static ctopfd; +static int ctopfd; static char*overread; static size_t overlen; --- ./Makefile Tue Sep 11 00:53:09 2001 +++ ../procmail-3.22/./Makefile Mon Mar 31 14:53:35 2003 @@ -114,31 +114,180 @@ # Possible locations for the sendmail.cf file SENDMAILCFS = /etc/mail/sendmail.cf /etc/sendmail.cf /usr/lib/sendmail.cf -# Makefile - mark, don't (re)move this, a sed script needs it +# Makefile.1 - mark, don't (re)move this, a sed script needs it -all: init - $(MAKE) make $@ +FGREP = grep -F +STRIP = +CFLAGS = $(CFLAGS1) +LDFLAGS = $(LDFLAGS1) -lm -lsocket -lnsl -lsun -lgen -ldl -lc +BINS= new/procmail new/lockfile new/formail new/mailstat +MANS= new/procmail.1 new/formail.1 new/lockfile.1 new/procmailrc.5 new/procmailsc.5 new/procmailex.5 +MANS1= procmail.$(MAN1SUFFIX) formail.$(MAN1SUFFIX) lockfile.$(MAN1SUFFIX) +MANS5= procmailrc.$(MAN5SUFFIX) procmailsc.$(MAN5SUFFIX) procmailex.$(MAN5SUFFIX) +MANSS= procmail.1 formail.1 lockfile.1 procmailrc.5 procmailsc.5 procmailex.5 +NBINS= ../new/procmail ../new/lockfile ../new/formail ../new/mailstat +NMANS= ../new/procmail.1 ../new/formail.1 ../new/lockfile.1 ../new/procmailrc.5 ../new/procmailsc.5 ../new/procmailex.5 + +#$Id: Makefile.1,v 1.52 2001/07/12 01:27:20 guenther Exp $ + +all: bins mans recommend + @echo If you would like to inspect the results before running make \ +install: + @echo All installable files can be found in the new/ subdirectory. + make: - @$(BSHELL) -c "exit 0" + @$(SHELL) -c "exit 0" .PRECIOUS: Makefile -init: - $(BSHELL) ./initmake $(BSHELL) "$(SHELL)" "$(RM)" "$(MV)" "$(LN)" \ - "$(SEARCHLIBS)" \ - "$(LIBPATHS)" \ - $(DEVNULL) "$(MAKE)" $(O) \ - "$(CC)" "$(CFLAGS1)" "$(LDFLAGS1)" "$(BINSS)" \ - "$(MANS1S)" \ - "$(MANS5S)" "$(SUBDIRS)" \ - "$(VISIBLE_BINDIR)" \ - "$(STRIP)" - -makefiles makefile Makefiles Makefile: init - @$(BSHELL) -c "exit 0" - -help target targets \ -bins mans install.bin install.man install recommend install-suid clean setid \ -realclean veryclean clobber deinstall autoconf.h $(BINSS) multigram: init - $(MAKE) make $@ +help target targets: + @sed "/^##*\*#$$/,/^##*\*#$$/ !d" $@ + @-if $(FGREP) -n -e '`' config.h $(DEVNULL) | $(FGREP) -v EOFName ; \ + then \ + echo;echo ' ^^^^^^^^^^^^^^^^^^^^ WARNING ^^^^^^^^^^^^^^^^^^^^^';\ + echo ' * Having backquotes in there could be unhealthy! *';\ + echo;fi;exit 0 + +recommend: autoconf.h src/Makefile + @cd src; $(MAKE) $@ + @echo ================================================================\ +=============== + @if $(FGREP) CF_no_procmail_yet autoconf.h >$(DEVNULL); \ + then echo If you are a system administrator you should consider \ +integrating procmail; echo into the mail-delivery system -- for advanced \ +functionality, speed AND; echo SECURITY "--. For" more information about \ +this topic you should look in the; echo examples/advanced file.; elif \ + cat $(SENDMAILCFS) 2>$(DEVNULL) | \ + grep 'Mlocal.*procmail.*F=[a-zA-Z]*u' >$(DEVNULL) ; then \ + echo The recommendation for the sendmail.cf entry of procmail has \ +changed.; echo I suggest you remove the '`u'"'"-flag 'like in:'; echo ; \ + sed -n 's/.*\(Mlocal.*procmail.*F=[a-zA-Z]*\)u/\1/p' `if test -f \ + /etc/sendmail.cf; then echo /etc/sendmail.cf; else \ + echo /usr/lib/sendmail.cf; fi`; fi + @echo + @echo \ + "Also, HIGHLY RECOMMENDED (type 'make install-suid' to execute it):" + @echo + @src/$@ $(BINDIR)/procmail $(BINDIR)/lockfile >suid.sh + @src/$@ $(BINDIR)/procmail $(BINDIR)/lockfile + @echo ================================================================\ +=============== + +suid.sh: recommend + +install-suid: suid.sh install.bin + @cat suid.sh + @$(SHELL) ./suid.sh + @cd $(BINDIR); echo Installed in $(BINDIR); ls -l $(BINSS) + +$(MANS): mans + +$(BINS): bins + +$(BASENAME): + $(MKDIRS) $(BASENAME) + +install.man: $(MANS) $(BASENAME) + @-$(MKDIRS) $(MANDIR) 2>$(DEVNULL); exit 0 + @-test -d $(MAN1DIR) || $(RM) $(MAN1DIR); exit 0 + @-$(MKDIRS) $(MAN1DIR) 2>$(DEVNULL); exit 0 + @-test -d $(MAN5DIR) || $(RM) $(MAN5DIR); exit 0 + @-$(MKDIRS) $(MAN5DIR) 2>$(DEVNULL); exit 0 + @chmod 0644 $(MANS) + @for a in $(MANS1S); \ + do $(INSTALL) new/$$a.1 $(MAN1DIR)/$$a.$(MAN1SUFFIX) || exit 1; \ + if test "X$(MANCOMPRESS)" != "X"; \ + then $(MANCOMPRESS) -c new/$$a.1 >$(MAN1DIR)/$$a.$(MAN1SUFFIX); \ + else :; fi; \ + done + @for a in $(MANS5S); \ + do $(INSTALL) new/$$a.5 $(MAN5DIR)/$$a.$(MAN5SUFFIX) || exit 1; \ + if test "X$(MANCOMPRESS)" != "X"; \ + then $(MANCOMPRESS) -c new/$$a.5 >$(MAN5DIR)/$$a.$(MAN5SUFFIX); \ + else :; fi; \ + done + echo Housekeeping file >install.man + +install.bin: $(BINS) $(BASENAME) + @-$(MKDIRS) $(BINDIR) 2>$(DEVNULL); exit 0 + @chmod 0755 $(BINS) + $(INSTALL) $(BINS) $(BINDIR) + @-dirname / >$(DEVNULL) || $(INSTALL) examples/dirname $(BINDIR) + echo Housekeeping file >install.bin + +install: + @$(MAKE) install.man install.bin + @echo + @cd $(BINDIR); echo Installed in $(BINDIR); ls -l $(BINSS) + @cd $(MAN1DIR); echo Installed in $(MAN1DIR); ls -l $(MANS1) + @cd $(MAN5DIR); echo Installed in $(MAN5DIR); ls -l $(MANS5) + @$(MAKE) recommend + +deinstall: + @echo ============================= Deinstalling the procmail package. + @$(RM) install.man install.bin + @echo ============================= Checking if everything was removed: + @-cd $(BINDIR); $(RM) $(BINSS); ls -l $(BINSS); exit 0 + @-cd $(MAN1DIR); $(RM) $(MANS1); ls -l $(MANS1); exit 0 + @-cd $(MAN5DIR); $(RM) $(MANS5); ls -l $(MANS5); exit 0 + @echo ============================= Ready. + +clean: config.check + -for a in $(SUBDIRS); do cd $$a; $(MAKE) $@; cd ..; done; exit 0 + cd SmartList; $(RM) targetdir.h targetdir.tmp install.list asked.patch + $(RM) $(MANS) $(BINS) install.man install.bin suid.sh _Makefile \ + *core* autoconf.h.tmp + +realclean: clean _init + $(RM) config.check + -for a in $(SUBDIRS); do $(MV) $$a/Makefile.init $$a/Makefile; done; \ + exit 0 + +veryclean clobber: realclean + +_init: + sed -e '/^# Makefile.1 - mark/,$$ d' _Makefile + cat Makefile.0 >>_Makefile + $(MV) _Makefile Makefile + $(RM) Makefile.0 + +man/Makefile: man/Makefile.0 Makefile + +src/Makefile: src/Makefile.0 Makefile + +HIDEMAKE=$(MAKE) + +man/Makefile src/Makefile Makefile: Makefile.1 initmake + sed -e '/^# Makefile.1 - mark/,$$ d' _Makefile + cat Makefile.0 >>_Makefile + $(MV) _Makefile Makefile + $(RM) Makefile.0 + $(HIDEMAKE) init + +init makefiles Makefiles makefile: man/Makefile src/Makefile --- ./config.h Tue Sep 11 00:53:50 2001 +++ ../procmail-3.22/./config.h Mon Mar 31 14:53:35 2003 @@ -33,8 +33,8 @@ * override those settings you should uncomment and possibly change the * DEFSPATH and DEFPATH defines below */ -/*#define DEFSPATH "PATH=/bin:/usr/bin" /* */ -/*#define DEFPATH "PATH=$HOME/bin:/bin:/usr/bin" /* */ +#define DEFSPATH "PATH=/usr/freeware/bin:/usr/sbin:/usr/bsd:/sbin:/usr/bin:/usr/bin/X11" +#define DEFPATH "PATH=$HOME/bin:/usr/freeware/bin:/usr/sbin:/usr/bsd:/sbin:/usr/bin:/usr/bin/X11" /* every environment variable appearing in PRESTENV will be set or wiped * out of the environment (variables without an '=' sign will be thrown @@ -52,7 +52,7 @@ is group writable or contained in a group writable home directory if the group involved is the user's default group. */ -/*#define LMTP /* uncomment this if you +#define LMTP /* uncomment this if you want to use procmail as an LMTP (rfc2033) server, presumably for invocation by an MTA. The file examples/local_procmail_lmtp.m4 contains info on how to @@ -116,11 +116,11 @@ is not found, maildelivery will proceed as normal to the default system mailbox. This also must be an absolute path */ -#define ETCRC "/etc/procmailrc" /* optional global procmailrc startup +#define ETCRC "/usr/freeware/etc/procmailrc" /* optional global procmailrc startup file (will only be read if procmail is started with no rcfile on the command line). */ -#define ETCRCS "/etc/procmailrcs/" /* optional trusted path prefix for +#define ETCRCS "/usr/freeware/etc/procmailrcs/" /* optional trusted path prefix for rcfiles which will be executed with the uid of the owner of the rcfile (this only happens if procmail is called with the -m option, without variable assignments on the command --- ./examples/1rmail Fri Dec 20 22:28:15 1996 +++ ../procmail-3.22/./examples/1rmail Mon Mar 31 14:53:35 2003 @@ -18,4 +18,4 @@ # # Call your favourite mailer here. # -/usr/ucb/mail -f $* +/usr/bin/mail -f $* --- ./examples/3rmail Fri Dec 20 22:28:15 1996 +++ ../procmail-3.22/./examples/3rmail Mon Mar 31 14:53:35 2003 @@ -24,4 +24,4 @@ # # Call your favourite mailer here. # -/usr/ucb/mail -f $* +/usr/bin/mail -f $* --- ./examples/2rmail Fri Dec 20 22:28:15 1996 +++ ../procmail-3.22/./examples/2rmail Mon Mar 31 14:53:35 2003 @@ -18,4 +18,4 @@ # # Call your favourite mailer here. # -/usr/ucb/mail -f $* +/usr/bin/mail -f $* --- ./examples/1procmailrc Thu May 26 09:46:39 1994 +++ ../procmail-3.22/./examples/1procmailrc Mon Mar 31 14:53:35 2003 @@ -1,7 +1,7 @@ # Please check if all the paths in PATH are reachable, remove the ones that # are not. -PATH=$HOME/bin:/usr/bin:/usr/ucb:/bin:/usr/local/bin:. +PATH=$HOME/bin:/usr/bin:/bin:/usr/freeware/bin:. MAILDIR=$HOME/Mail # You'd better make sure it exists DEFAULT=$MAILDIR/mbox LOGFILE=$MAILDIR/from --- ./examples/2procmailrc Thu May 26 09:46:40 1994 +++ ../procmail-3.22/./examples/2procmailrc Mon Mar 31 14:53:35 2003 @@ -1,7 +1,7 @@ # Please check if all the paths in PATH are reachable, remove the ones that # are not. -PATH=$HOME/bin:/usr/bin:/usr/ucb:/bin:/usr/local/bin:. +PATH=$HOME/bin:/usr/bin:/bin:/usr/freeware/bin:. MAILDIR=$HOME/Mail # You'd better make sure it exists DEFAULT=$MAILDIR/mbox # We don't use a global lockfile here now. --- ./examples/3procmailrc Thu May 26 09:46:41 1994 +++ ../procmail-3.22/./examples/3procmailrc Mon Mar 31 14:53:35 2003 @@ -1,7 +1,7 @@ # Please check if all the paths in PATH are reachable, remove the ones that # are not. -PATH=$HOME/bin:/usr/bin:/global/bin:/usr/ucb:/bin:/usr/local/bin: +PATH=$HOME/bin:/usr/bin:/bin:/usr/freeware/bin: MAILDIR = $HOME/Mail # You'd better make sure it exists DEFAULT = $MAILDIR/mbox LOGFILE = $MAILDIR/from --- ./examples/local_procmail_lmtp.m4 Tue Sep 11 00:54:15 2001 +++ ../procmail-3.22/./examples/local_procmail_lmtp.m4 Mon Mar 31 14:53:35 2003 @@ -17,7 +17,7 @@ # # This feature can take up to three arguments: # 1. Path to the mailer program -# [default: PROCMAIL_MAILER_PATH or /usr/local/bin/procmail] +# [default: PROCMAIL_MAILER_PATH or /usr/freeware/bin/procmail] # 2. Argument vector including name of the program # [default: procmail -Y -a $h -z] # 3. Flags for the mailer [default: PSXhmnz9] @@ -37,7 +37,7 @@ ifelse(defn(`_ARG_'), `', ifdef(`PROCMAIL_MAILER_PATH', PROCMAIL_MAILER_PATH, - `/usr/local/bin/procmail'), + `/usr/freeware/bin/procmail'), _ARG_)) define(`LOCAL_MAILER_ARGS', ifelse(len(X`'_ARG2_), `1', `procmail -Y -a $h -z', _ARG2_))