1# Copyright (c) 1983 Eric P. Allman 2# Copyright (c) 1988 The Regents of the University of California. 3# All rights reserved. 4# 5# %sccs.include.redist.sh% 6# 7# @(#)READ_ME 8.3 (Berkeley) 07/13/93 8# 9 10This directory contains the source files for sendmail. 11 12For detailed instructions, please read the document ../doc/op.me: 13 14 eqn ../doc/op.me | pic | ditroff -me 15 16The Makefile is for the new Berkeley make, available from ftp.uu.net 17in the directory /systems/unix/bsd-sources/usr.bin/make. There is 18also a Makefile.dist which is much less clever, but works on the old 19traditional make. You can use this using: 20 21 make -f Makefile.dist 22 23There are a couple of other Makefiles for other systems -- these are 24the ones that I use, they have "Berkeley quirks" in them, and I don't 25guarantee that they will work in your environment. To make it worse, 26some are for the new Berkeley make, and some are for the old make. 27I provide them for information only. Still, they may help you get 28started. They have names like "Makefile.HPUX". 29 30Whereever possible, I try to make sendmail pull in the correct 31compilation options needed to compile on various environments based on 32automatically defined symbols. Some machines don't seem to have useful 33symbols availble, requiring the following compilation flags in the 34Makefile: 35 36SOLARIS Define this if you are running Solaris 2.0 or higher. 37__NeXT__ Define this if you are on a NeXT box. (This one may 38 be pre-defined for you.) 39_AIX3 Define this if you are IBM AIX 3.x. 40 41If you are a system that sendmail has already been ported to, you 42probably won't have to touch these. But if you are porting, you may 43have to tweak the following compilation flags in order to get 44it to compile and link properly: 45 46UNSETENV Define this if your system library does NOT include the 47 "unsetenv" subroutine. 48SYSTEM5 Adjust for System V. 49LOCKF Set this if you do not have the flock system call -- it 50 will revert to System V file locking. There are some 51 semantic gotchas, so flock is preferred. Implied by 52 SYSTEM5. 53SYS5TZ Use System V-style time zones. If not set, the TZ 54 environment variable is ignored. Implied by SYSTEM5. 55HASUNAME Set if you have the "uname" system call. Implied by 56 SYSTEM5. 57HASSTATFS Define this if you have the statfs(2) system call. It's 58 not a disaster to get this wrong -- but you do lose the 59 queue free space code. 60HASUSTAT Define this if you have the ustat(2) system call. It's 61 not a disaster to get this wrong -- but you do lose the 62 queue free space code. 63HASSETSID Define this if you have the setsid(2) system call. This 64 is implied if your system appears to be POSIX compliant. 65HASINITGROUPS Define this if you have the initgroups(3) routine. 66HASSETVBUF Define this if you have the setvbuf(3) library call. 67 If you don't, setlinebuf will be used instead. This 68 defaults on if your compiler defines __STDC__. 69HASSETEUID Define this if you have seteuid(2) ***AND*** root can use 70 it to change to an arbitrary user. This second condition 71 is not satisfied on AIX 3.x. You may find that 72 your system has setreuid(2) or setresuid(2), in which 73 case you will also have to #define seteuid(uid) to be 74 the appropriate call. The important thing is that you 75 have a call that will set the effective uid and NOT 76 set the real or saved uid. Setting this improves the 77 security somewhat, since sendmail doesn't have to read 78 .forward and :include: files as root. 79LA_TYPE The type of load average your kernel supports. These 80 can be LA_SUBR (4) if you have the getloadavg(3) routine, 81 LA_FLOAT (3) if you read kmem and interpret the value 82 as a floating point number, LA_INT (2) to interpret as 83 an integer. These last two have several other parameters 84 that they try to divine: the name of your kernel, the name 85 of the variable in the kernel to examine, the number of 86 bits of precision in a fixed point load average, and so 87 forth. In desparation, use LA_ZERO -- it always returns 88 the load average as "zero" (and does so on all architectures). 89 The actual code is in conf.c -- it can be tweaked if you 90 are brave. 91 92There are a bunch of features that you can decide to compile in, such 93as selecting various database packages and special protocol support. 94Several are assumed based on other compilation flags -- if you want to 95"un-assume" something, you probably need to edit conf.h. Compilation 96flags that add support for special features include: 97 98NDBM Include support for "new" DBM library for aliases and maps. 99NEWDB Include support for Berkeley "db" package (hash & btree) 100 for aliases and maps. 101NIS Define this to get NIS (YP) support for aliases and maps. 102YPCOMPAT Define this to force building of DBM versions of alias 103 files even if you have NEWDB defined; this will only 104 occur on NIS master machines. It is independent of NIS. 105USERDB Include support for the User Information Database. Implied 106 by NEWDB conf.h. 107IDENTPROTO Define this to get IDENT (RFC 1413) protocol support. 108 This is assumed unless you are running on Ultrix or 109 HP-UX, both of which have a problem in the UDP 110 implementation. 111MIME Include support for MIME-encapsulated error messages. 112FROZENCONFIG Define this to get support for frozen configuration 113 files. Frozen configurations make sense if your I/O system 114 is fast relative to your processor. At this point this 115 is NOT recommended. 116LOG Set this to get syslog(3) support. Defined by default 117 in conf.h. You want this if at all possible. 118NETINET Set this to get TCP/IP support. Defined by default 119 in conf.h. You probably want this. 120NETISO Define this to get ISO networking support. 121SMTP Define this to get the SMTP code. Implied by NETINET 122 or NETISO. 123NAMED_BIND Define this to get DNS (name daemon) support, including 124 MX support. The specs you must use this if you run 125 SMTP. Defined by default in conf.h. 126QUEUE Define this to get queueing code. Implied by NETINET 127 or NETISO; required by SMTP. This gives you other good 128 stuff -- it should be on. 129DAEMON Define this to get general network support. Implied by 130 NETINET or NETISO. Defined by default in conf.h. You 131 almost certainly want it on. 132MATCHGECOS Permit fuzzy matching of user names against the full 133 name (GECOS) field in the /etc/passwd file. This should 134 probably be on, since you can disable it from the config 135 file if you want to. Defined by default in conf.h. 136SETPROCTITLE Try to set the string printed by "ps" to something 137 informative about what sendmail is doing. Defined by 138 default in conf.h. 139 140If you are compiling on SunOS and want to use frozen configuration 141files, you must use -Bstatic -- if you do not, frozen configuration 142files fail in bizarre ways and you will open up several security holes. 143 144If you are compiling on OSF/1 (DEC Alpha), you must use -lmld. 145 146If you are compiling on NeXT, you will have to create an empty file 147"unistd.h". 148 149If you use both -DNDBM and -DNEWDB, you must delete the module ndbm.o 150from libdb.a and delete the file "ndbm.h" from the files that get 151installed (that is, use the OLD ndbm.h, not the new ndbm.h). This 152compatibility module maps ndbm calls into DB calls, and breaks things 153rather badly. 154 155You probably want to look over the compilation options in conf.h 156before you compile. These are intended to be per-site information. 157 158The following list describes the files in this directory: 159 160Makefile The makefile used here; this version only works with 161 the new Berkeley make. 162Makefile.dist A trimmed down version of the makefile that works with 163 the old make. 164READ_ME This file. 165TRACEFLAGS My own personal list of the trace flags -- not guaranteed 166 to be particularly up to date. 167alias.c Does name aliasing in all forms. 168arpadate.c A subroutine which creates ARPANET standard dates. 169clock.c Routines to implement real-time oriented functions 170 in sendmail -- e.g., timeouts. 171collect.c The routine that actually reads the mail into a temp 172 file. It also does a certain amount of parsing of 173 the header, etc. 174conf.c The configuration file. This contains information 175 that is presumed to be quite static and non- 176 controversial, or code compiled in for efficiency 177 reasons. Most of the configuration is in sendmail.cf. 178conf.h Configuration that must be known everywhere. 179convtime.c A routine to sanely process times. 180daemon.c Routines to implement daemon mode. This version is 181 specifically for Berkeley 4.1 IPC. 182deliver.c Routines to deliver mail. 183domain.c Routines that interface with DNS (the Domain Name 184 System). 185err.c Routines to print error messages. 186envelope.c Routines to manipulate the envelope structure. 187headers.c Routines to process message headers. 188macro.c The macro expander. This is used internally to 189 insert information from the configuration file. 190main.c The main routine to sendmail. This file also 191 contains some miscellaneous routines. 192map.c Support for database maps. 193mci.c Routines that handle mail connection information caching. 194parseaddr.c The routines which do address parsing. 195queue.c Routines to implement message queueing. 196readcf.c The routine that reads the configuration file and 197 translates it to internal form. 198recipient.c Routines that manipulate the recipient list. 199savemail.c Routines which save the letter on processing errors. 200sendmail.h Main header file for sendmail. 201srvrsmtp.c Routines to implement server SMTP. 202stab.c Routines to manage the symbol table. 203stats.c Routines to collect and post the statistics. 204sysexits.c List of error messages associated with error codes 205 in sysexits.h. 206trace.c The trace package. These routines allow setting and 207 testing of trace flags with a high granularity. 208udb.c The user database interface module. 209usersmtp.c Routines to implement user SMTP. 210util.c Some general purpose routines used by sendmail. 211version.c The version number and information about this 212 version of sendmail. Theoretically, this gets 213 modified on every change. 214 215Eric Allman 216 217(Version 8.3, last update 07/13/93 12:58:13) 218