From 79c9d8a6d4c52b430112b82ad6ff98be7c3ca40f Mon Sep 17 00:00:00 2001 From: eric Date: Sun, 11 Apr 2021 07:18:08 +0000 Subject: [PATCH] do not build unused code and remove uneeded dependency on libm. ok tb@ --- usr.sbin/smtpd/smtpd.h | 7 +------ usr.sbin/smtpd/smtpd/Makefile | 8 +++----- usr.sbin/smtpd/ssl.h | 8 +------- 3 files changed, 5 insertions(+), 18 deletions(-) diff --git a/usr.sbin/smtpd/smtpd.h b/usr.sbin/smtpd/smtpd.h index a64c11e29c36..7e73194dc0be 100644 --- a/usr.sbin/smtpd/smtpd.h +++ b/usr.sbin/smtpd/smtpd.h @@ -1,4 +1,4 @@ -/* $OpenBSD: smtpd.h,v 1.666 2021/04/10 06:44:18 eric Exp $ */ +/* $OpenBSD: smtpd.h,v 1.667 2021/04/11 07:18:08 eric Exp $ */ /* * Copyright (c) 2008 Gilles Chehade @@ -1638,11 +1638,6 @@ const char *srs_encode(const char *, const char *); const char *srs_decode(const char *); -/* ssl_smtpd.c */ -void *ssl_mta_init(void *, char *, off_t, const char *); -void *ssl_smtp_init(void *, int); - - /* stat_backend.c */ struct stat_backend *stat_backend_lookup(const char *); void stat_increment(const char *, size_t); diff --git a/usr.sbin/smtpd/smtpd/Makefile b/usr.sbin/smtpd/smtpd/Makefile index 704078f2ce57..694ece96a6ba 100644 --- a/usr.sbin/smtpd/smtpd/Makefile +++ b/usr.sbin/smtpd/smtpd/Makefile @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile,v 1.111 2021/03/05 12:37:32 eric Exp $ +# $OpenBSD: Makefile,v 1.112 2021/04/11 07:18:08 eric Exp $ .PATH: ${.CURDIR}/.. @@ -51,8 +51,6 @@ SRCS+= smtp_session.c SRCS+= smtpd.c SRCS+= srs.c SRCS+= ssl.c -SRCS+= ssl_smtpd.c -SRCS+= ssl_verify.c SRCS+= stat_backend.c SRCS+= table.c SRCS+= to.c @@ -82,8 +80,8 @@ SRCS+= stat_ramstat.c MAN= sendmail.8 smtpd.8 smtpd.conf.5 table.5 BINDIR= /usr/sbin -LDADD+= -levent -lutil -ltls -lssl -lcrypto -lm -lz -DPADD+= ${LIBEVENT} ${LIBUTIL} ${LIBTLS} ${LIBSSL} ${LIBCRYPTO} ${LIBM} ${LIBZ} +LDADD+= -levent -lutil -ltls -lssl -lcrypto -lz +DPADD+= ${LIBEVENT} ${LIBUTIL} ${LIBTLS} ${LIBSSL} ${LIBCRYPTO} ${LIBZ} CFLAGS+= -fstack-protector-all CFLAGS+= -I${.CURDIR}/.. diff --git a/usr.sbin/smtpd/ssl.h b/usr.sbin/smtpd/ssl.h index 9ee1b8499992..1702ae8d3ce1 100644 --- a/usr.sbin/smtpd/ssl.h +++ b/usr.sbin/smtpd/ssl.h @@ -1,4 +1,4 @@ -/* $OpenBSD: ssl.h,v 1.22 2021/03/05 12:37:32 eric Exp $ */ +/* $OpenBSD: ssl.h,v 1.23 2021/04/11 07:18:08 eric Exp $ */ /* * Copyright (c) 2013 Gilles Chehade * @@ -65,9 +65,3 @@ int ssl_load_pkey(const void *, size_t, char *, off_t, int ssl_ctx_fake_private_key(SSL_CTX *, const void *, size_t, char *, off_t, X509 **, EVP_PKEY **); char *ssl_pubkey_hash(const char *, off_t); - -/* ssl_privsep.c */ -int ssl_by_mem_ctrl(X509_LOOKUP *, int, const char *, long, char **); - -/* ssl_verify.c */ -int ssl_check_name(X509 *, const char *, int *);