135062Sbostic# Copyright (c) 1983 Eric P. Allman 248582Sbostic# Copyright (c) 1988 The Regents of the University of California. 333728Sbostic# All rights reserved. 433728Sbostic# 548582Sbostic# %sccs.include.redist.sh% 633728Sbostic# 7*63753Seric# @(#)READ_ME 8.2 (Berkeley) 07/11/93 833728Sbostic# 948582Sbostic 109881SericThis directory contains the source files for sendmail. 115369Seric 1260565SericFor detailed instructions, please read the document ../doc/op.me: 135369Seric 1460565Seric eqn ../doc/op.me | pic | ditroff -me 155369Seric 1657418SericThe Makefile is for the new Berkeley make, available from ftp.uu.net 1757418Sericin the directory /systems/unix/bsd-sources/usr.bin/make. There is 1857418Sericalso a Makefile.dist which is much less clever, but works on the old 1957418Serictraditional make. You can use this using: 2057418Seric 2157418Seric make -f Makefile.dist 2257418Seric 2360565SericThere are a couple of other Makefiles for other systems -- these are 2460584Sericthe ones that I use, they have "Berkeley quirks" in them, and I don't 2560584Sericguarantee that they will work in your environment. To make it worse, 2660584Sericsome are for the new Berkeley make, and some are for the old make. 2760584SericI provide them for information only. Still, they may help you get 2860584Sericstarted. They have names like "Makefile.HPUX". 2957943Seric 3060565SericWhereever possible, I try to make sendmail pull in the correct 3160584Sericcompilation options needed to compile on various environments based on 3260584Sericautomatically defined symbols. Some machines don't seem to have useful 3360584Sericsymbols availble, requiring the following compilation flags in the 3460584SericMakefile: 3560565Seric 3660565SericSOLARIS Define this if you are running Solaris 2.0 or higher. 37*63753Seric__NeXT__ Define this if you are on a NeXT box. (This one may 38*63753Seric be pre-defined for you.) 3960565Seric_AIX3 Define this if you are IBM AIX 3.x. 4060565Seric 4160584SericIf you are a system that sendmail has already been ported to, you 4260584Sericprobably won't have to touch these. But if you are porting, you may 4360584Serichave to tweak the following compilation flags in order to get 4460584Sericit to compile and link properly: 4560565Seric 4660565SericUNSETENV Define this if your system library does NOT include the 4760565Seric "unsetenv" subroutine. 4860565SericSYSTEM5 Adjust for System V. 4960565SericLOCKF Set this if you do not have the flock system call -- it 5060565Seric will revert to System V file locking. There are some 5160565Seric semantic gotchas, so flock is preferred. Implied by 5260565Seric SYSTEM5. 5360565SericSYS5TZ Use System V-style time zones. If not set, the TZ 5460565Seric environment variable is ignored. Implied by SYSTEM5. 5560565SericHASUNAME Set if you have the "uname" system call. Implied by 5660565Seric SYSTEM5. 5760584SericHASSTATFS Define this if you have the statfs(2) system call. It's 5860584Seric not a disaster to get this wrong -- but you do lose the 5960584Seric queue free space code. 6060584SericHASUSTAT Define this if you have the ustat(2) system call. It's 6160584Seric not a disaster to get this wrong -- but you do lose the 6260584Seric queue free space code. 6360565SericHASSETSID Define this if you have the setsid(2) system call. This 6460565Seric is implied if your system appears to be POSIX compliant. 6560565SericHASINITGROUPS Define this if you have the initgroups(3) routine. 66*63753SericHASSETVBUF Define this if you have the setvbuf(3) library call. 67*63753Seric If you don't, setlinebuf will be used instead. This 68*63753Seric defaults on if your compiler defines __STDC__. 6960584SericLA_TYPE The type of load average your kernel supports. These 7060584Seric can be LA_SUBR (4) if you have the getloadavg(3) routine, 7160584Seric LA_FLOAT (3) if you read kmem and interpret the value 7260584Seric as a floating point number, LA_INT (2) to interpret as 7360584Seric an integer. These last two have several other parameters 7460584Seric that they try to divine: the name of your kernel, the name 7560584Seric of the variable in the kernel to examine, the number of 7660584Seric bits of precision in a fixed point load average, and so 7760584Seric forth. In desparation, use LA_ZERO -- it always returns 7860584Seric the load average as "zero" (and does so on all architectures). 7960584Seric The actual code is in conf.c -- it can be tweaked if you 8060584Seric are brave. 8160565Seric 8260584SericThere are a bunch of features that you can decide to compile in, such 8360584Sericas selecting various database packages and special protocol support. 8460584SericSeveral are assumed based on other compilation flags -- if you want to 8560584Seric"un-assume" something, you probably need to edit conf.h. Compilation 8660584Sericflags that add support for special features include: 8760565Seric 8860565SericNDBM Include support for "new" DBM library for aliases and maps. 8960565SericNEWDB Include support for Berkeley "db" package (hash & btree) 9060565Seric for aliases and maps. 9160565SericNIS Define this to get NIS (YP) support for aliases and maps. 9260565SericYPCOMPAT Define this to force building of DBM versions of alias 9360565Seric files even if you have NEWDB defined; this will only 9460565Seric occur on NIS master machines. It is independent of NIS. 9560565SericUSERDB Include support for the User Information Database. Implied 9660584Seric by NEWDB conf.h. 9760565SericIDENTPROTO Define this to get IDENT (RFC 1413) protocol support. 9860565Seric This is assumed unless you are running on Ultrix or 9960565Seric HP-UX, both of which have a problem in the UDP 10060565Seric implementation. 10160565SericMIME Include support for MIME-encapsulated error messages. 10260565SericFROZENCONFIG Define this to get support for frozen configuration 10360584Seric files. Frozen configurations make sense if your I/O system 10460584Seric is fast relative to your processor. At this point this 10560584Seric is NOT recommended. 10660565SericLOG Set this to get syslog(3) support. Defined by default 10760584Seric in conf.h. You want this if at all possible. 10860565SericNETINET Set this to get TCP/IP support. Defined by default 10960584Seric in conf.h. You probably want this. 11060565SericNETISO Define this to get ISO networking support. 11160565SericSMTP Define this to get the SMTP code. Implied by NETINET 11260565Seric or NETISO. 11360565SericNAMED_BIND Define this to get DNS (name daemon) support, including 11460565Seric MX support. The specs you must use this if you run 11560565Seric SMTP. Defined by default in conf.h. 11660565SericQUEUE Define this to get queueing code. Implied by NETINET 11760584Seric or NETISO; required by SMTP. This gives you other good 11860584Seric stuff -- it should be on. 11960565SericDAEMON Define this to get general network support. Implied by 12060584Seric NETINET or NETISO. Defined by default in conf.h. You 12160584Seric almost certainly want it on. 12260565SericMATCHGECOS Permit fuzzy matching of user names against the full 12360565Seric name (GECOS) field in the /etc/passwd file. This should 12460565Seric probably be on, since you can disable it from the config 12560584Seric file if you want to. Defined by default in conf.h. 12660565SericSETPROCTITLE Try to set the string printed by "ps" to something 12760584Seric informative about what sendmail is doing. Defined by 12860584Seric default in conf.h. 12960565Seric 13060565SericIf you are compiling on SunOS and want to use frozen configuration 13160565Sericfiles, you must use -Bstatic -- if you do not, frozen configuration 13260565Sericfiles fail in bizarre ways and you will open up several security holes. 13360565Seric 13457977SericIf you are compiling on OSF/1 (DEC Alpha), you must use -lmld. 13557977Seric 136*63753SericIf you are compiling on NeXT, you will have to create an empty file 137*63753Seric"unistd.h". 138*63753Seric 13958709SericIf you use both -DNDBM and -DNEWDB, you must delete the module ndbm.o 14060172Sericfrom libdb.a and delete the file "ndbm.h" from the files that get 14160172Sericinstalled (that is, use the OLD ndbm.h, not the new ndbm.h). This 14260172Sericcompatibility module maps ndbm calls into DB calls, and breaks things 14360172Sericrather badly. 14457943Seric 14558709SericYou probably want to look over the compilation options in conf.h 14658709Sericbefore you compile. These are intended to be per-site information. 14758709Seric 1489881SericThe following list describes the files in this directory: 1495369Seric 15057418SericMakefile The makefile used here; this version only works with 15157418Seric the new Berkeley make. 15257418SericMakefile.dist A trimmed down version of the makefile that works with 15357418Seric the old make. 1545369SericREAD_ME This file. 15560565SericTRACEFLAGS My own personal list of the trace flags -- not guaranteed 15660565Seric to be particularly up to date. 1575369Sericalias.c Does name aliasing in all forms. 1589881Sericarpadate.c A subroutine which creates ARPANET standard dates. 1599881Sericclock.c Routines to implement real-time oriented functions 1609881Seric in sendmail -- e.g., timeouts. 1615369Sericcollect.c The routine that actually reads the mail into a temp 1625369Seric file. It also does a certain amount of parsing of 1635369Seric the header, etc. 1645369Sericconf.c The configuration file. This contains information 1655369Seric that is presumed to be quite static and non- 1665369Seric controversial, or code compiled in for efficiency 1675369Seric reasons. Most of the configuration is in sendmail.cf. 1689881Sericconf.h Configuration that must be known everywhere. 1695369Sericconvtime.c A routine to sanely process times. 1709881Sericdaemon.c Routines to implement daemon mode. This version is 1719881Seric specifically for Berkeley 4.1 IPC. 1725369Sericdeliver.c Routines to deliver mail. 17360565Sericdomain.c Routines that interface with DNS (the Domain Name 17460565Seric System). 1755369Sericerr.c Routines to print error messages. 1769881Sericenvelope.c Routines to manipulate the envelope structure. 1775369Sericheaders.c Routines to process message headers. 1785369Sericmacro.c The macro expander. This is used internally to 1795369Seric insert information from the configuration file. 1805369Sericmain.c The main routine to sendmail. This file also 1815369Seric contains some miscellaneous routines. 18260565Sericmap.c Support for database maps. 18360565Sericmci.c Routines that handle mail connection information caching. 1849881Sericparseaddr.c The routines which do address parsing. 1855369Sericqueue.c Routines to implement message queueing. 1865369Sericreadcf.c The routine that reads the configuration file and 1875369Seric translates it to internal form. 1889881Sericrecipient.c Routines that manipulate the recipient list. 1895369Sericsavemail.c Routines which save the letter on processing errors. 1905369Sericsendmail.h Main header file for sendmail. 1915369Sericsrvrsmtp.c Routines to implement server SMTP. 1925369Sericstab.c Routines to manage the symbol table. 1935369Sericstats.c Routines to collect and post the statistics. 1945369Sericsysexits.c List of error messages associated with error codes 1955369Seric in sysexits.h. 1969881Serictrace.c The trace package. These routines allow setting and 1979881Seric testing of trace flags with a high granularity. 19860565Sericudb.c The user database interface module. 1995369Sericusersmtp.c Routines to implement user SMTP. 2005369Sericutil.c Some general purpose routines used by sendmail. 20160565Sericversion.c The version number and information about this 20260565Seric version of sendmail. Theoretically, this gets 20360565Seric modified on every change. 2045369Seric 2055369SericEric Allman 2065369Seric 207*63753Seric(Version 8.2, last update 07/11/93 06:52:16) 208