More complete implementation of SUBDIR for programs, libraries and kmods.

`depend' wasn't supported.  This seems to have only broken `make depend'
in gnu/usr.bin/ld.

bsd.prog.mk:
Build the man pages in ${MANDEPEND} at build time.
This commit is contained in:
Bruce Evans 1995-02-08 21:35:31 +00:00
parent 7111dc5ac1
commit cdaec7b1a1
5 changed files with 16 additions and 8 deletions

View File

@ -1,8 +1,8 @@
# $Id: bsd.dep.mk,v 1.4 1994/02/27 19:28:44 nate Exp $
# $Id: bsd.dep.mk,v 1.1 1994/08/04 21:10:07 wollman Exp $
# some of the rules involve .h sources, so remove them from mkdep line
.if !target(depend)
depend: beforedepend .depend afterdepend
depend: beforedepend .depend afterdepend ${_DEPSUBDIR}
.if defined(SRCS)
.depend: ${SRCS}
rm -f .depend
@ -19,7 +19,7 @@ depend: beforedepend .depend afterdepend
mkdep -a ${MKDEP} ${CXXFLAGS:M-nostd*} ${CXXFLAGS:M-[ID]*} $$files; \
fi
.else
.depend:
.depend: ${_DEPSUBDIR}
.endif
.if !target(beforedepend)
beforedepend:

View File

@ -1,5 +1,5 @@
# From: @(#)bsd.prog.mk 5.26 (Berkeley) 6/25/91
# $Id: bsd.kmod.mk,v 1.7 1995/01/14 07:51:06 jkh Exp $
# $Id: bsd.kmod.mk,v 1.8 1995/01/30 07:22:00 jkh Exp $
.if exists(${.CURDIR}/../Makefile.inc)
.include "${.CURDIR}/../Makefile.inc"
@ -154,4 +154,5 @@ vnode_if.h: ${KERN}/vnode_if.sh ${KERN}/vnode_if.src
./vnode_if.h: vnode_if.h
_DEPSUBDIR= _PROGSUBDIR
.include <bsd.dep.mk>

View File

@ -1,5 +1,5 @@
# from: @(#)bsd.lib.mk 5.26 (Berkeley) 5/2/91
# $Id: bsd.lib.mk,v 1.20 1995/01/14 22:18:15 wollman Exp $
# $Id: bsd.lib.mk,v 1.21 1995/01/30 07:22:02 jkh Exp $
#
.if exists(${.CURDIR}/../Makefile.inc)
@ -330,4 +330,5 @@ obj: _LIBSUBDIR
.endif
.endif
_DEPSUBDIR= _LIBSUBDIR
.include <bsd.dep.mk>

View File

@ -1,5 +1,5 @@
# from: @(#)bsd.prog.mk 5.26 (Berkeley) 6/25/91
# $Id: bsd.prog.mk,v 1.20 1995/01/25 20:24:01 ache Exp $
# $Id: bsd.prog.mk,v 1.21 1995/01/30 07:20:01 jkh Exp $
.if exists(${.CURDIR}/../Makefile.inc)
.include "${.CURDIR}/../Makefile.inc"
@ -127,8 +127,12 @@ _PROGSUBDIR: .USE
done
.endif
# XXX I think MANDEPEND is only used for groff. It should be named more
# generally and perhaps not be in the maninstall dependencies now it is
# here (or does maninstall always work when nothing is made?),
.MAIN: all
all: ${PROG} _PROGSUBDIR
all: ${PROG} ${MANDEPEND} _PROGSUBDIR
.if !target(clean)
clean: _PROGSUBDIR
@ -224,4 +228,5 @@ tags: ${SRCS} _PROGSUBDIR
maninstall:
.endif
_DEPSUBDIR= _PROGSUBDIR
.include <bsd.dep.mk>

View File

@ -1,5 +1,5 @@
# From: @(#)bsd.prog.mk 5.26 (Berkeley) 6/25/91
# $Id: bsd.kmod.mk,v 1.7 1995/01/14 07:51:06 jkh Exp $
# $Id: bsd.kmod.mk,v 1.8 1995/01/30 07:22:00 jkh Exp $
.if exists(${.CURDIR}/../Makefile.inc)
.include "${.CURDIR}/../Makefile.inc"
@ -154,4 +154,5 @@ vnode_if.h: ${KERN}/vnode_if.sh ${KERN}/vnode_if.src
./vnode_if.h: vnode_if.h
_DEPSUBDIR= _PROGSUBDIR
.include <bsd.dep.mk>