aboutsummaryrefslogtreecommitdiff
path: root/usr.bin/vacation/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'usr.bin/vacation/Makefile')
-rw-r--r--usr.bin/vacation/Makefile20
1 files changed, 17 insertions, 3 deletions
diff --git a/usr.bin/vacation/Makefile b/usr.bin/vacation/Makefile
index 9ac29e06fc8b..fcaf946eb6b4 100644
--- a/usr.bin/vacation/Makefile
+++ b/usr.bin/vacation/Makefile
@@ -6,10 +6,18 @@ SENDMAIL_DIR=${.CURDIR}/../../contrib/sendmail
.PATH: ${SENDMAIL_DIR}/vacation
PROG= vacation
-CFLAGS+=-I${SENDMAIL_DIR}/src -I${SENDMAIL_DIR}/include
+SRCS= vacation.c
+CFLAGS+=-I${SENDMAIL_DIR}/src -I${SENDMAIL_DIR}/include -I.
CFLAGS+=-DNEWDB -DNOT_SENDMAIL
CFLAGS+=-D_FFR_LISTDB -D_FFR_DEBUG
+.if exists(${.OBJDIR}/../../lib/libsm)
+LIBSMDIR:= ${.OBJDIR}/../../lib/libsm
+.else
+LIBSMDIR!= cd ${.CURDIR}/../../lib/libsm; make -V .OBJDIR
+.endif
+LIBSM:= ${LIBSMDIR}/libsm.a
+
.if exists(${.OBJDIR}/../../lib/libsmdb)
LIBSMDBDIR:= ${.OBJDIR}/../../lib/libsmdb
.else
@@ -24,8 +32,11 @@ LIBSMUTILDIR!= cd ${.CURDIR}/../../lib/libsmutil; make -V .OBJDIR
.endif
LIBSMUTIL:= ${LIBSMUTILDIR}/libsmutil.a
-DPADD= ${LIBSMDB} ${LIBSMUTIL}
-LDADD= ${LIBSMDB} ${LIBSMUTIL}
+DPADD= ${LIBSMDB} ${LIBSMUTIL} ${LIBSM}
+LDADD= ${LIBSMDB} ${LIBSMUTIL} ${LIBSM}
+
+SRCS+= sm_os.h
+CLEANFILES+=sm_os.h
# User customizations to the sendmail build environment
CFLAGS+=${SENDMAIL_CFLAGS}
@@ -33,4 +44,7 @@ DPADD+=${SENDMAIL_DPADD}
LDADD+=${SENDMAIL_LDADD}
LDFLAGS+=${SENDMAIL_LDFLAGS}
+sm_os.h:
+ ln -sf ${SENDMAIL_DIR}/include/sm/os/sm_os_freebsd.h sm_os.h
+
.include <bsd.prog.mk>