Fix 'install*' and many other missing targets with DIRDEPS_BUILD.
My changes in r291635 broke 'make install*' for DIRDEPS_BUILD but also revealed that some other targets were not guaranteed to be created if there was a SUBDIR defined. One example is 'installfiles' was never defined if SUBDIR was not empty. Sponsored by: EMC / Isilon Storage Division
This commit is contained in:
parent
184f96813c
commit
d290e8743a
@ -56,12 +56,6 @@ STANDALONE_SUBDIR_TARGETS?= obj checkdpadd clean cleandepend cleandir \
|
||||
_SUBDIR:
|
||||
.endif
|
||||
.endif
|
||||
.if !target(_SUBDIR)
|
||||
|
||||
.if defined(SUBDIR)
|
||||
SUBDIR:=${SUBDIR} ${SUBDIR.yes}
|
||||
SUBDIR:=${SUBDIR:u}
|
||||
.endif
|
||||
|
||||
DISTRIBUTION?= base
|
||||
.if !target(distribute)
|
||||
@ -93,6 +87,14 @@ install: beforeinstall realinstall afterinstall
|
||||
.ORDER: beforeinstall realinstall afterinstall
|
||||
.endif
|
||||
|
||||
# SUBDIR recursing may be disabled for MK_DIRDEPS_BUILD
|
||||
.if !target(_SUBDIR)
|
||||
|
||||
.if defined(SUBDIR)
|
||||
SUBDIR:=${SUBDIR} ${SUBDIR.yes}
|
||||
SUBDIR:=${SUBDIR:u}
|
||||
.endif
|
||||
|
||||
# Subdir code shared among 'make <subdir>', 'make <target>' and SUBDIR_PARALLEL.
|
||||
_SUBDIR_SH= \
|
||||
if test -d ${.CURDIR}/$${dir}.${MACHINE_ARCH}; then \
|
||||
@ -151,11 +153,16 @@ ${__target}: ${__subdir_targets}
|
||||
.else
|
||||
${__target}: _SUBDIR
|
||||
.endif # SUBDIR_PARALLEL || _is_standalone_target
|
||||
.elif !target(${__target})
|
||||
${__target}:
|
||||
.endif # make(${__target})
|
||||
.endfor # __target in ${ALL_SUBDIR_TARGETS}
|
||||
|
||||
.endif # !target(_SUBDIR)
|
||||
|
||||
# Ensure all targets exist
|
||||
.for __target in ${ALL_SUBDIR_TARGETS}
|
||||
.if !target(${__target})
|
||||
${__target}:
|
||||
.endif
|
||||
.endfor
|
||||
|
||||
.endif
|
||||
|
Loading…
Reference in New Issue
Block a user