When we need to build using the in-tree make,

switch at the earliest opportunity.
In the case of fmake vs bmake, this helps ensure correct load handling.

Reviewed by: obrien
This commit is contained in:
Simon J. Gerraty 2013-08-16 16:26:23 +00:00
parent aeb681d798
commit a6822ce859

View File

@ -242,6 +242,7 @@ cleanworld:
# skip this for -n to avoid changing previous behavior of # skip this for -n to avoid changing previous behavior of
# 'make -n buildworld' etc. # 'make -n buildworld' etc.
${TGTS}: .MAKE ${TGTS}: .MAKE
tinderbox toolchains kernel-toolchains: .MAKE
.endif .endif
${TGTS}: ${TGTS}:
@ -353,14 +354,16 @@ make bmake: .PHONY
${MMAKE} all && \ ${MMAKE} all && \
${MMAKE} install DESTDIR=${MYMAKE:H} BINDIR= PROGNAME=${MYMAKE:T} ${MMAKE} install DESTDIR=${MYMAKE:H} BINDIR= PROGNAME=${MYMAKE:T}
tinderbox toolchains kernel-toolchains: upgrade_checks
tinderbox: tinderbox:
@cd ${.CURDIR} && ${MAKE} DOING_TINDERBOX=YES universe @cd ${.CURDIR} && ${SUB_MAKE} DOING_TINDERBOX=YES universe
toolchains: toolchains:
@cd ${.CURDIR} && ${MAKE} UNIVERSE_TARGET=toolchain universe @cd ${.CURDIR} && ${SUB_MAKE} UNIVERSE_TARGET=toolchain universe
kernel-toolchains: kernel-toolchains:
@cd ${.CURDIR} && ${MAKE} UNIVERSE_TARGET=kernel-toolchain universe @cd ${.CURDIR} && ${SUB_MAKE} UNIVERSE_TARGET=kernel-toolchain universe
# #
# universe # universe
@ -419,7 +422,7 @@ universe_${target}_prologue: universe_prologue
.if !defined(MAKE_JUST_KERNELS) .if !defined(MAKE_JUST_KERNELS)
.for target_arch in ${TARGET_ARCHES_${target}} .for target_arch in ${TARGET_ARCHES_${target}}
universe_${target}: universe_${target}_${target_arch} universe_${target}: universe_${target}_${target_arch}
universe_${target}_${target_arch}: universe_${target}_prologue universe_${target}_${target_arch}: universe_${target}_prologue .MAKE
@echo ">> ${target}.${target_arch} ${UNIVERSE_TARGET} started on `LC_ALL=C date`" @echo ">> ${target}.${target_arch} ${UNIVERSE_TARGET} started on `LC_ALL=C date`"
@(cd ${.CURDIR} && env __MAKE_CONF=/dev/null \ @(cd ${.CURDIR} && env __MAKE_CONF=/dev/null \
${SUB_MAKE} ${JFLAG} ${UNIVERSE_TARGET} \ ${SUB_MAKE} ${JFLAG} ${UNIVERSE_TARGET} \
@ -440,7 +443,7 @@ universe_${target}_kernels: universe_${target}_${target_arch}
.endfor .endfor
.endif .endif
universe_${target}: universe_${target}_kernels universe_${target}: universe_${target}_kernels
universe_${target}_kernels: universe_${target}_prologue universe_${target}_kernels: universe_${target}_prologue .MAKE
.if exists(${KERNSRCDIR}/${target}/conf/NOTES) .if exists(${KERNSRCDIR}/${target}/conf/NOTES)
@(cd ${KERNSRCDIR}/${target}/conf && env __MAKE_CONF=/dev/null \ @(cd ${KERNSRCDIR}/${target}/conf && env __MAKE_CONF=/dev/null \
${SUB_MAKE} LINT > ${.CURDIR}/_.${target}.makeLINT 2>&1 || \ ${SUB_MAKE} LINT > ${.CURDIR}/_.${target}.makeLINT 2>&1 || \
@ -468,7 +471,7 @@ TARGET_ARCH_${kernel}!= cd ${KERNSRCDIR}/${TARGET}/conf && \
.error "Target architecture for ${TARGET}/conf/${kernel} unknown. config(8) likely too old." .error "Target architecture for ${TARGET}/conf/${kernel} unknown. config(8) likely too old."
.endif .endif
universe_kernconfs: universe_kernconf_${TARGET}_${kernel} universe_kernconfs: universe_kernconf_${TARGET}_${kernel}
universe_kernconf_${TARGET}_${kernel}: universe_kernconf_${TARGET}_${kernel}: .MAKE
@(cd ${.CURDIR} && env __MAKE_CONF=/dev/null \ @(cd ${.CURDIR} && env __MAKE_CONF=/dev/null \
${SUB_MAKE} ${JFLAG} buildkernel \ ${SUB_MAKE} ${JFLAG} buildkernel \
TARGET=${TARGET} \ TARGET=${TARGET} \