166271Seric#
266271Seric#  This Makefile is designed to work on the old "make" program.  It does
366271Seric#  not use the obj subdirectory.  It also does not install documentation
466271Seric#  automatically -- think of it as a quick start for sites that have the
566271Seric#  old make program (I recommend that you get and port the new make if you
666271Seric#  are going to be doing any signficant work on sendmail).
766271Seric#
866271Seric#  This has been tested on SCO.
966271Seric#
10*69943Seric#	@(#)Makefile.SCO	8.7 (Berkeley) 06/20/95
1166271Seric#
1266271Seric
1366271Seric# use O=-O (usual) or O=-g (debugging)
1466271SericO=	-O
1566271Seric
1666271Seric# define the database mechanisms available for map & alias lookups:
1766271Seric#	-DNDBM -- use new DBM
1866271Seric#	-DNEWDB -- use new Berkeley DB
1966271Seric#	-DNIS -- include NIS support
2066271Seric# The really old (V7) DBM library is no longer supported.
2166271Seric# See READ_ME for a description of how these flags interact.
2266271Seric#
2366271SericDBMDEF=
2466271Seric
2566271Seric# environment definitions (e.g., -D_AIX3)
2666271SericENVDEF=	-D_SCO_unix_
2766271Seric
2866271Seric# see also conf.h for additional compilation flags
2966271Seric
3066271Seric# include directories
3166271SericINCDIRS=
3266271Seric
3366271Seric# library directories
3466271SericLIBDIRS=
3566271Seric
3666271Seric# libraries required on your system
3766271SericLIBS=	-lsocket
3866271Seric
3966271Seric# location of sendmail binary (usually /usr/sbin or /usr/lib)
4066271SericBINDIR=	${DESTDIR}/usr/lib
4166271Seric
4266271Seric# location of sendmail.st file (usually /var/log or /usr/lib)
4366271SericSTDIR=	${DESTDIR}/usr/lib
4466271Seric
4566271Seric# location of sendmail.hf file (usually /usr/share/misc or /usr/lib)
4666271SericHFDIR=	${DESTDIR}/usr/lib
4766271Seric
4866271Seric# additional .o files needed
4966757SericOBJADD=
5066271Seric
5166271Seric###################  end of user configuration flags  ######################
5266271Seric
5366271SericCFLAGS=	-I. $O ${INCDIRS} ${DBMDEF} ${ENVDEF}
5466271Seric
5566271SericOBJS=	alias.o arpadate.o clock.o collect.o conf.o convtime.o daemon.o \
5666271Seric	deliver.o domain.o envelope.o err.o headers.o macro.o main.o \
5767546Seric	map.o mci.o mime.o parseaddr.o queue.o readcf.o recipient.o \
5866271Seric	savemail.o srvrsmtp.o stab.o stats.o sysexits.o \
5966271Seric	trace.o udb.o usersmtp.o util.o version.o ${OBJADD}
6066271Seric
6166271SericLINKS=	${DESTDIR}/usr/ucb/newaliases ${DESTDIR}/usr/ucb/mailq
6266271SericBINOWN=	root
6366271SericBINGRP=	kmem
6466271SericBINMODE=6555
6566271Seric
6666271SericALL=	sendmail aliases.0 mailq.0 newaliases.0 sendmail.0
6766271Seric
6866271Sericall: ${ALL}
6966271Seric
7066271Sericsendmail: ${BEFORE} ${OBJS}
7166271Seric	${CC} -o sendmail ${OBJS} ${LIBDIRS} ${LIBS}
7266271Seric
7368774Seric#NROFF=	nroff -h
7468774SericNROFF=	groff -Tascii
7568774SericMANDOC=	-mandoc
7666741Seric
7766271Sericaliases.0: aliases.5
7868774Seric	${NROFF} ${MANDOC} aliases.5 > aliases.0
7966271Seric
8066271Sericmailq.0: mailq.1
8168774Seric	${NROFF} ${MANDOC} mailq.1 > mailq.0
8266271Seric
8366271Sericnewaliases.0: newaliases.1
8468774Seric	${NROFF} ${MANDOC} newaliases.1 > newaliases.0
8566271Seric
8666271Sericsendmail.0: sendmail.8
8768774Seric	${NROFF} ${MANDOC} sendmail.8 > sendmail.0
8866271Seric
8966271Sericinstall: install-sendmail install-docs
9066271Seric
9166271Sericinstall-sendmail: sendmail
9266271Seric	install -o ${BINOWN} -g ${BINGRP} -m ${BINMODE} sendmail ${BINDIR}
9366271Seric	for i in ${LINKS}; do rm -f $$i; ln -s ${BINDIR}/sendmail $$i; done
9466271Seric	install -c -o ${BINOWN} -g ${BINGRP} -m 644 /dev/null \
9566271Seric	    ${STDIR}/sendmail.st
9666271Seric	install -c -o ${BINOWN} -g ${BINGRP} -m 444 sendmail.hf ${HFDIR}
9766271Seric
9866271Seric# doesn't actually install them -- you may want to install pre-nroff versions
9966314Sericinstall-docs: aliases.0 mailq.0 newaliases.0 sendmail.0
10066271Seric
10166271Sericclean:
10266314Seric	rm -f ${OBJS} sendmail aliases.0 mailq.0 newaliases.0 sendmail.0
10366271Seric
10466271Seric# dependencies
10566271Seric#   gross overkill, and yet still not quite enough....
10666271Seric${OBJS}: sendmail.h conf.h
107*69943Seric
108*69943Sericdepend:
109