1 1.31 tv # $NetBSD: bsd.subdir.mk,v 1.31 1999/02/11 05:01:39 tv Exp $ 2 1.14 mikel # @(#)bsd.subdir.mk 8.1 (Berkeley) 6/8/93 3 1.1 cgd 4 1.27 mycroft .if !target(__initialized__) 5 1.27 mycroft __initialized__: 6 1.27 mycroft .if exists(${.CURDIR}/../Makefile.inc) 7 1.27 mycroft .include "${.CURDIR}/../Makefile.inc" 8 1.27 mycroft .endif 9 1.13 christos .include <bsd.own.mk> 10 1.27 mycroft .MAIN: all 11 1.3 mycroft .endif 12 1.1 cgd 13 1.25 mycroft .for dir in ${SUBDIR} 14 1.25 mycroft .if exists(${dir}.${MACHINE}) 15 1.25 mycroft __REALSUBDIR+=${dir}.${MACHINE} 16 1.25 mycroft .else 17 1.25 mycroft __REALSUBDIR+=${dir} 18 1.25 mycroft .endif 19 1.25 mycroft .endfor 20 1.1 cgd 21 1.25 mycroft .for dir in ${__REALSUBDIR} 22 1.17 mycroft .for targ in ${TARGETS} 23 1.17 mycroft .PHONY: ${targ}-${dir} 24 1.25 mycroft ${targ}-${dir}: .MAKE 25 1.30 thorpej @echo "${targ} ===> ${_THISDIR_}${dir}" 26 1.25 mycroft @cd ${.CURDIR}/${dir}; \ 27 1.25 mycroft ${MAKE} "_THISDIR_=${_THISDIR_}${dir}/" ${targ} 28 1.29 drochner subdir-${targ}: ${targ}-${dir} 29 1.29 drochner ${targ}: subdir-${targ} 30 1.17 mycroft .endfor 31 1.12 cgd .endfor 32 1.21 christos 33 1.26 mycroft # Make sure all of the standard targets are defined, even if they do nothing. 34 1.26 mycroft ${TARGETS}: 35