summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--share/mk/bsd.dep.mk4
-rw-r--r--share/mk/bsd.prog.mk8
2 files changed, 7 insertions, 5 deletions
diff --git a/share/mk/bsd.dep.mk b/share/mk/bsd.dep.mk
index 5dcaceeedab..f21fe7f3098 100644
--- a/share/mk/bsd.dep.mk
+++ b/share/mk/bsd.dep.mk
@@ -1,11 +1,11 @@
-# $OpenBSD: bsd.dep.mk,v 1.5 2003/08/07 11:24:03 espie Exp $
+# $OpenBSD: bsd.dep.mk,v 1.6 2006/06/30 19:00:29 otto Exp $
# $NetBSD: bsd.dep.mk,v 1.12 1995/09/27 01:15:09 christos Exp $
# some of the rules involve .h sources, so remove them from mkdep line
.if !target(depend)
depend: beforedepend .depend _SUBDIRUSE afterdepend
. if defined(SRCS)
-.depend: ${SRCS}
+.depend: ${SRCS} ${_LEXINTM} ${_YACCINTM}
@rm -f .depend
@files="${.ALLSRC:M*.s} ${.ALLSRC:M*.S}"; \
if [ "$$files" != " " ]; then \
diff --git a/share/mk/bsd.prog.mk b/share/mk/bsd.prog.mk
index db65970914d..38a9caa1a07 100644
--- a/share/mk/bsd.prog.mk
+++ b/share/mk/bsd.prog.mk
@@ -1,4 +1,4 @@
-# $OpenBSD: bsd.prog.mk,v 1.48 2006/06/26 03:12:37 brad Exp $
+# $OpenBSD: bsd.prog.mk,v 1.49 2006/06/30 19:00:29 otto Exp $
# $NetBSD: bsd.prog.mk,v 1.55 1996/04/08 21:19:26 jtc Exp $
# @(#)bsd.prog.mk 5.26 (Berkeley) 6/25/91
@@ -81,6 +81,8 @@ LIBRESOLV?= ${DESTDIR}/usr/lib/libresolv.a
SRCS?= ${PROG}.c
. if !empty(SRCS:N*.h:N*.sh)
OBJS+= ${SRCS:N*.h:N*.sh:R:S/$/.o/g}
+_LEXINTM+=${SRCS:M*.l:.l=.c}
+_YACCINTM+=${SRCS:M*.y:.y=.c}
LOBJS+= ${LSRCS:.c=.ln} ${SRCS:M*.c:.c=.ln} ${SRCS:M*.y:.y=.ln} ${SRCS:M*.l:.l=.ln}
. endif
@@ -104,8 +106,8 @@ all: ${PROG} _SUBDIRUSE
.if !target(clean)
clean: _SUBDIRUSE
- rm -f a.out [Ee]rrs mklog core *.core \
- ${PROG} ${OBJS} ${LOBJS} ${CLEANFILES}
+ rm -f a.out [Ee]rrs mklog core *.core y.tab.h \
+ ${PROG} ${OBJS} ${LOBJS} ${_LEXINTM} ${_YACCINTM} ${CLEANFILES}
.endif
cleandir: _SUBDIRUSE clean