diff --git a/share/mk/bsd.subdir.mk b/share/mk/bsd.subdir.mk index cc66c9a36166..293b017e2259 100644 --- a/share/mk/bsd.subdir.mk +++ b/share/mk/bsd.subdir.mk @@ -25,14 +25,17 @@ # This is a variant of install, which will # put the stuff into the right "distribution". # -# afterinstall, all, all-man, beforeinstall, checkdpadd, clean, -# cleandepend, cleandir, cleanilinks depend, install, lint, -# maninstall, manlint, obj, objlink, realinstall, regress, tags +# See ALL_SUBDIR_TARGETS for list of targets that will recurse. +# Custom targets can be added to SUBDIR_TARGETS in src.conf. # .if !target(____) ____: +ALL_SUBDIR_TARGETS= all all-man checkdpadd clean cleandepend cleandir \ + cleanilinks cleanobj depend distribute lint maninstall manlint obj \ + objlink realinstall regress tags ${SUBDIR_TARGETS} + .include .if !defined(NEED_SUBDIR) @@ -85,9 +88,7 @@ ${SUBDIR:N.WAIT}: .PHONY .MAKE # Work around parsing of .if nested in .for by putting .WAIT string into a var. __wait= .WAIT -.for __target in all all-man checkdpadd clean cleandepend cleandir \ - cleanilinks cleanobj depend distribute lint maninstall manlint obj objlink \ - realinstall regress tags ${SUBDIR_TARGETS} +.for __target in ${ALL_SUBDIR_TARGETS} .ifdef SUBDIR_PARALLEL __subdir_targets= .for __dir in ${SUBDIR}