summaryrefslogtreecommitdiffstats
path: root/contrib/sendmail/mailstats
diff options
context:
space:
mode:
authorgshapiro <gshapiro@FreeBSD.org>2000-08-12 21:55:49 +0000
committergshapiro <gshapiro@FreeBSD.org>2000-08-12 21:55:49 +0000
commitc3cd75415d60bc002b20182ffd3383ea9e901a80 (patch)
tree211dfd0f771f89d6abe14fa94cab53985a9d0116 /contrib/sendmail/mailstats
parent231592eb7942ebd4becae24ea8e018acea3742a9 (diff)
parent4332139a9a11f773ffe5109bed871561e3c290a1 (diff)
downloadFreeBSD-src-c3cd75415d60bc002b20182ffd3383ea9e901a80.zip
FreeBSD-src-c3cd75415d60bc002b20182ffd3383ea9e901a80.tar.gz
This commit was generated by cvs2svn to compensate for changes in r64562,
which included commits to RCS files with non-trunk default branches.
Diffstat (limited to 'contrib/sendmail/mailstats')
-rw-r--r--contrib/sendmail/mailstats/Makefile17
-rw-r--r--contrib/sendmail/mailstats/Makefile.m4107
-rw-r--r--contrib/sendmail/mailstats/mailstats.8147
3 files changed, 109 insertions, 162 deletions
diff --git a/contrib/sendmail/mailstats/Makefile b/contrib/sendmail/mailstats/Makefile
new file mode 100644
index 0000000..6dbcb62
--- /dev/null
+++ b/contrib/sendmail/mailstats/Makefile
@@ -0,0 +1,17 @@
+# $Id: Makefile,v 8.5 1999/09/23 22:36:36 ca Exp $
+
+SHELL= /bin/sh
+BUILD= ./Build
+OPTIONS= $(CONFIG) $(FLAGS)
+
+all: FRC
+ $(SHELL) $(BUILD) $(OPTIONS) $@
+clean: FRC
+ $(SHELL) $(BUILD) $(OPTIONS) $@
+install: FRC
+ $(SHELL) $(BUILD) $(OPTIONS) $@
+
+fresh: FRC
+ $(SHELL) $(BUILD) $(OPTIONS) -c
+
+FRC:
diff --git a/contrib/sendmail/mailstats/Makefile.m4 b/contrib/sendmail/mailstats/Makefile.m4
index 2de9904..5a9259d 100644
--- a/contrib/sendmail/mailstats/Makefile.m4
+++ b/contrib/sendmail/mailstats/Makefile.m4
@@ -1,97 +1,20 @@
-#
-# This Makefile is designed to work on the old "make" program.
-#
-# @(#)Makefile.m4 8.15 (Berkeley) 7/12/1998
-#
+include(confBUILDTOOLSDIR`/M4/switch.m4')
-# C compiler
-CC= confCC
+# sendmail dir
+SMSRCDIR= ifdef(`confSMSRCDIR', `confSMSRCDIR', `${SRCDIR}/sendmail')
+PREPENDDEF(`confENVDEF', `confMAPDEF')
+PREPENDDEF(`confINCDIRS', `-I${SMSRCDIR} ')
-# Shell
-SHELL= confSHELL
+bldPRODUCT_START(`executable', `mailstats')
+define(`bldINSTALL_DIR', `S')
+define(`bldSOURCES', `mailstats.c ')
+bldPUSH_SMLIB(`smutil')
+APPENDDEF(`confENVDEF', `-DNOT_SENDMAIL')
+bldPRODUCT_END
-# use O=-O (usual) or O=-g (debugging)
-O= ifdef(`confOPTIMIZE', `confOPTIMIZE', `-O')
+bldPRODUCT_START(`manpage', `mailstats')
+define(`bldSOURCES', `mailstats.8')
+bldPRODUCT_END
-# location of sendmail source directory
-SRCDIR= ifdef(`confSRCDIR', `confSRCDIR', `../../src')
+bldFINISH
-# environment definitions (e.g., -D_AIX3)
-ENVDEF= ifdef(`confENVDEF', `confENVDEF')
-
-# see also conf.h for additional compilation flags
-
-# include directories
-INCDIRS=-I${SRCDIR} confINCDIRS
-
-# loader options
-LDOPTS= ifdef(`confLDOPTS', `confLDOPTS')
-
-# library directories
-LIBDIRS=confLIBDIRS
-
-# libraries required on your system
-LIBS= ifdef(`confLIBS', `confLIBS')
-
-# location of mailstats binary (usually /usr/sbin or /usr/etc)
-SBINDIR=${DESTDIR}ifdef(`confSBINDIR', `confSBINDIR', `/usr/sbin')
-
-# additional .o files needed
-OBJADD= ifdef(`confOBJADD', `confOBJADD')
-
-undivert(1)
-
-################### end of user configuration flags ######################
-
-BUILDBIN=confBUILDBIN
-COPTS= -I. ${INCDIRS} ${ENVDEF}
-CFLAGS= $O ${COPTS}
-
-BEFORE= confBEFORE
-OBJS= mailstats.o ${OBJADD}
-
-NROFF= ifdef(`confNROFF', `confNROFF', `groff -Tascii')
-MANDOC= ifdef(`confMANDOC', `confMANDOC', `-mandoc')
-
-INSTALL=ifdef(`confINSTALL', `confINSTALL', `install')
-BINOWN= ifdef(`confUBINOWN', `confUBINOWN', `bin')
-BINGRP= ifdef(`confUBINGRP', `confUBINGRP', `bin')
-BINMODE=ifdef(`confUBINMODE', `confUBINMODE', `555')
-
-MANOWN= ifdef(`confMANOWN', `confMANOWN', `bin')
-MANGRP= ifdef(`confMANGRP', `confMANGRP', `bin')
-MANMODE=ifdef(`confMANMODE', `confMANMODE', `444')
-
-MANROOT=${DESTDIR}ifdef(`confMANROOT', `confMANROOT', `/usr/share/man/cat')
-MAN8= ${MANROOT}ifdef(`confMAN8', `confMAN8', `8')
-MAN8EXT=ifdef(`confMAN8EXT', `confMAN8EXT', `8')
-MAN8SRC=ifdef(`confMAN8SRC', `confMAN8SRC', `0')
-
-ALL= mailstats mailstats.${MAN8SRC}
-
-all: ${ALL}
-
-mailstats: ${BEFORE} ${OBJS}
- ${CC} -o mailstats ${LDOPTS} ${OBJS} ${LIBDIRS} ${LIBS}
-
-undivert(3)
-
-mailstats.${MAN8SRC}: mailstats.8
- ${NROFF} ${MANDOC} mailstats.8 > mailstats.${MAN8SRC}
-
-install: install-mailstats install-docs
-
-install-mailstats: mailstats
- ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m ${BINMODE} mailstats ${SBINDIR}
-
-install-docs: mailstats.${MAN8SRC}
-ifdef(`confNO_MAN_INSTALL', `dnl',
-` ${INSTALL} -c -o ${MANOWN} -g ${MANGRP} -m ${MANMODE} mailstats.${MAN8SRC} ${MAN8}/mailstats.${MAN8EXT}')
-
-clean:
- rm -f ${OBJS} mailstats mailstats.${MAN8SRC}
-
-################ Dependency scripts
-include(confBUILDTOOLSDIR/M4/depend/ifdef(`confDEPEND_TYPE', `confDEPEND_TYPE',
-`generic').m4)dnl
-################ End of dependency scripts
diff --git a/contrib/sendmail/mailstats/mailstats.8 b/contrib/sendmail/mailstats/mailstats.8
index be2203d..2fab81d 100644
--- a/contrib/sendmail/mailstats/mailstats.8
+++ b/contrib/sendmail/mailstats/mailstats.8
@@ -1,100 +1,107 @@
-.\" Copyright (c) 1998 Sendmail, Inc. All rights reserved.
+.\" Copyright (c) 1998-2000 Sendmail, Inc. and its suppliers.
+.\" All rights reserved.
.\"
.\" By using this file, you agree to the terms and conditions set
.\" forth in the LICENSE file which can be found at the top level of
.\" the sendmail distribution.
.\"
.\"
-.\" @(#)mailstats.8 8.8 (Berkeley) 11/13/1998
+.\" $Id: mailstats.8,v 8.17 2000/03/11 20:18:21 gshapiro Exp $
.\"
-.Dd April 25, 1996
-.Dt MAILSTATS 1
-.Os BSD 3
-.Sh NAME
-.Nm mailstats
-.Nd display mail statistics
-.Sh SYNOPSIS
-.Nm mailstats
-.Op Fl o
-.if \nP .Op Fl p
-.Op Fl C Ar cffile
-.Op Fl f Ar stfile
-.Sh DESCRIPTION
+.TH MAILSTATS 1 "April 25, 1996"
+.SH NAME
+.B mailstats
+\- display mail statistics
+.SH SYNOPSIS
+.B mailstats
+.RB [ \-o "] [" \-p ]
+.RB [ \-C
+.IR cffile ]
+.RB [ \-f
+.IR stfile ]
+.SH DESCRIPTION
The
-.Nm mailstats
+.B mailstats
utility displays the current mail statistics.
-.Pp
+.PP
First, the time at which statistics started being kept is displayed,
-in the format specified by
-.Xr ctime 3 .
-Then,
-the statistics for each mailer are displayed on a single line,
-each with the following whitespace separated fields:
-.Pp
-.Bl -tag -width 10n -offset indent -compact
-.It Sy M
+in the format specified by
+ctime(3).
+Then,
+the statistics for each mailer are displayed on a single line,
+each with the following white space separated fields:
+.sp
+.RS
+.PD 0.2v
+.TP 1.2i
+.B M
The mailer number.
-.It Sy msgsfr
+.TP
+.B msgsfr
Number of messages from the mailer.
-.It Sy bytes_from
+.TP
+.B bytes_from
Kbytes from the mailer.
-.It Sy msgsto
+.TP
+.B msgsto
Number of messages to the mailer.
-.It Sy bytes_to
+.TP
+.B bytes_to
Kbytes to the mailer.
-.It Sy msgsrej
+.TP
+.B msgsrej
Number of messages rejected.
-.It Sy msgsdis
+.TP
+.B msgsdis
Number of messages discarded.
-.It Sy Mailer
+.TP
+.B Mailer
The name of the mailer.
-.El
-.Pp
-After this display, a line totaling the values for all of the mailers
-is displayed,
-separated from the previous information by a line containing only equals
-.Pq Dq \&=
+.PD
+.RE
+.PP
+After this display, a line totaling the values for all of the mailers
+is displayed (preceeded with a ``T''),
+separated from the previous information by a line containing only equals
+(``='')
characters.
-.Pp
+Another line preceeded with a ``C'' lists the number of connections.
+.PP
The options are as follows:
-.Bl -tag -width Ds
-.It Fl C
+.TP
+.B \-C
Read the specified file instead of the default
-.Nm sendmail
-.Dq cf
-file.
-.It Fl f
+.B sendmail
+``cf'' file.
+.TP
+.B \-f
Read the specified statistics file instead of the statistics file
specified in the
-.Nm sendmail
-.Dq cf
-file.
-.if \nP \
-\{
-.It Fl p
+.B sendmail
+``cf'' file.
+.TP
+.B \-p
Output information in program-readable mode and clear statistics.
-.\}
-.It Fl o
+.TP
+.B \-o
Don't display the name of the mailer in the output.
-.El
-.Pp
+.PP
The
-.Nm mailstats
+.B mailstats
utility exits 0 on success, and >0 if an error occurs.
-.Sh FILES
-.Bl -tag -width /var/log/sendmail.stXX -compact
-.ie \nP .It Pa /etc/mail/sendmail.cf
-.el .It Pa /etc/sendmail.cf
+.SH FILES
+.PD 0.2v
+.TP 2.5i
+/etc/mail/sendmail.cf
The default
-.Nm sendmail
-.Dq cf
-file.
-.ie \nP .It Pa /etc/mail/statistics
-.el .It Pa /var/log/sendmail.st
+.B sendmail
+``cf'' file.
+.TP
+/etc/mail/statistics
The default
-.Nm sendmail
+.B sendmail
statistics file.
-.El
-.Sh SEE ALSO
-.Xr mailq 1 ,
-.Xr sendmail 8
+.PD
+.SH SEE ALSO
+mailq(1),
+sendmail(8)
OpenPOWER on IntegriCloud