From 14481f92c4fa8b8a93883b6d4547c6bbf9505ff3 Mon Sep 17 00:00:00 2001 From: Ed Maste Date: Tue, 17 Oct 2017 19:11:29 +0000 Subject: [PATCH] loader.mk: clean md.o even if MD_IMAGE_SIZE not defined We don't normally provide special handling for optionally-included src files, but md.o depends on both md.c and the value of ${MD_IMAGE_SIZE}. Previously if one built with MD_IMAGE_SIZE, executed "make clean", and then built with a different MD_IMAGE_SIZE md.o would not be rebuilt. Reported by: Zakary Nafziger Sponsored by: The FreeBSD Foundation --- sys/boot/loader.mk | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sys/boot/loader.mk b/sys/boot/loader.mk index 814cef256c81..a501d69a7ade 100644 --- a/sys/boot/loader.mk +++ b/sys/boot/loader.mk @@ -43,6 +43,8 @@ SRCS+= bcache.c .if defined(MD_IMAGE_SIZE) CFLAGS+= -DMD_IMAGE_SIZE=${MD_IMAGE_SIZE} SRCS+= md.c +.else +CLEANFILES+= md.o .endif # Machine-independant ISA PnP