From e4cf28f04441dd374a2c475f4d7fc2f3af832ea4 Mon Sep 17 00:00:00 2001 From: matusita Date: Thu, 15 Nov 2001 07:04:23 +0000 Subject: [PATCH] Run "make cleandir" if NO_MODULES are set, or there is no sys/modules directory. Previous commit breaks buildkernel if NO_MODULES was set. Sorry... Noticed by: mike --- Makefile.inc1 | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Makefile.inc1 b/Makefile.inc1 index c516f2495fa8..28bcaa2eae14 100644 --- a/Makefile.inc1 +++ b/Makefile.inc1 @@ -431,8 +431,13 @@ buildkernel: ${KERNCONFDIR}/${_kernel} .endif .if !defined(NOCLEAN) && !defined(NO_KERNELCLEAN) +.if defined(NO_MODULES) || !exists(${KRNLSRCDIR}/modules) + cd ${KRNLOBJDIR}/${_kernel}; \ + ${KMAKEENV} ${MAKE} KERNEL=${INSTKERNNAME} clean +.else` cd ${KRNLOBJDIR}/${_kernel}; \ ${KMAKEENV} ${MAKE} KERNEL=${INSTKERNNAME} clean cleandir +.endif .endif cd ${KRNLOBJDIR}/${_kernel}; \ MAKESRCPATH=${KRNLSRCDIR}/dev/aic7xxx/aicasm \