diff options
author | peter <peter@FreeBSD.org> | 1996-01-01 08:54:01 +0000 |
---|---|---|
committer | peter <peter@FreeBSD.org> | 1996-01-01 08:54:01 +0000 |
commit | 0fdeab8ba7f1d0ba770b68b3b9e0198ce6d06614 (patch) | |
tree | ada425fce45acbb7dacd3aa9105ab2276bdaf29a /usr.sbin | |
parent | 3b73747ada8402e2c58702e493b7b8c97604735e (diff) | |
download | FreeBSD-src-0fdeab8ba7f1d0ba770b68b3b9e0198ce6d06614.zip FreeBSD-src-0fdeab8ba7f1d0ba770b68b3b9e0198ce6d06614.tar.gz |
Get sendmail to detect when to use the setproctitle() in libutil
This uses osreldate.h and other stuff to determine whether it's on a
-current system. It should still compile cleanly on a -stable branch
system.
Diffstat (limited to 'usr.sbin')
-rw-r--r-- | usr.sbin/sendmail/src/Makefile | 4 | ||||
-rw-r--r-- | usr.sbin/sendmail/src/conf.h | 13 |
2 files changed, 13 insertions, 4 deletions
diff --git a/usr.sbin/sendmail/src/Makefile b/usr.sbin/sendmail/src/Makefile index c3919d2..d4ddbf9 100644 --- a/usr.sbin/sendmail/src/Makefile +++ b/usr.sbin/sendmail/src/Makefile @@ -24,8 +24,8 @@ SRCS= alias.c arpadate.c clock.c collect.c conf.c convtime.c daemon.c \ mci.c mime.c parseaddr.c queue.c readcf.c recipient.c savemail.c \ srvrsmtp.c stab.c stats.c sysexits.c trace.c udb.c usersmtp.c \ util.c version.c -DPADD= -LDADD= +DPADD= ${LIBUTIL} +LDADD= -lutil MAN1= mailq.1 newaliases.1 MAN5= aliases.5 MAN8= sendmail.8 diff --git a/usr.sbin/sendmail/src/conf.h b/usr.sbin/sendmail/src/conf.h index c1c24a0..a0a9426 100644 --- a/usr.sbin/sendmail/src/conf.h +++ b/usr.sbin/sendmail/src/conf.h @@ -596,8 +596,17 @@ typedef int pid_t; # endif # if defined(__FreeBSD__) # undef SPT_TYPE -# define SPT_TYPE SPT_REUSEARGV -# define SPT_PADCHAR '\0' /* pad process title with nulls */ +# if __FreeBSD__ == 2 +# include <osreldate.h> /* and this works */ +# if __FreeBSD_version >= 199512 /* 2.2-current right now */ +# define SPT_TYPE SPT_BUILTIN +# include <libutil.h> +# endif +# endif +# ifndef SPT_TYPE +# define SPT_TYPE SPT_REUSEARGV +# define SPT_PADCHAR '\0' /* pad process title with nulls */ +# endif # endif #endif |