From 34bd547866db6fbfb3d4e73c82e2eee1654a463c Mon Sep 17 00:00:00 2001 From: Richard Bradley Date: Tue, 30 Jan 2024 18:49:01 +0900 Subject: [PATCH] fixes for 'clobber' target --- build/Makefile | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/build/Makefile b/build/Makefile index c1656ab..f0c9dc9 100644 --- a/build/Makefile +++ b/build/Makefile @@ -13,15 +13,17 @@ format: $(foreach var,$(DIRS), (cd $(var); sh $(TOP)/build/tidy_source.sh do) ;) $(foreach var,$(DIRS), (cd $(var); sh $(TOP)/build/format.sh do) ;) -clean: - $(foreach var,$(DIRS), $(MAKE) -C $(var) $@; ) +clean_files: /bin/rm -rf data/sounds/ /bin/rm -rf data/gfx/ /bin/rm -f build.log -clobber: +clean: clean_files + $(foreach var,$(DIRS), $(MAKE) -C $(var) $@; ) + +clobber: clean_files $(foreach var,$(DIRS), $(MAKE) -C $(var) $@; ) -.PHONY: all clean clobber format pre +.PHONY: all clean_files clean clobber format pre .DEFAULT_GOAL := all