From 1900d7810cd7329c6cc2d663ca82d1fee2cfc259 Mon Sep 17 00:00:00 2001 From: Thomas Lamprecht Date: Sun, 11 Jul 2021 13:25:39 +0200 Subject: [PATCH] buildsys: mark clean targets phony and split out deb pkg-clean Signed-off-by: Thomas Lamprecht --- Makefile | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index e83b46dc..690f7664 100644 --- a/Makefile +++ b/Makefile @@ -128,15 +128,18 @@ $(DSC): build cd build; dpkg-buildpackage -S -us -uc -d -nc lintian $(DSC) +.PHONY: clean distclean deb clean distclean: clean - -clean: +clean: clean-debs $(foreach i,$(SUBDIRS), \ $(MAKE) -C $(i) clean ;) $(CARGO) clean - rm -rf *.deb *.dsc *.tar.gz *.buildinfo *.changes build find . -name '*~' -exec rm {} ';' +# allows one to avoid running cargo clean when one just wants to tidy up after a packgae build +clean-deb: + rm -rf *.deb *.dsc *.tar.gz *.buildinfo *.changes build/ + .PHONY: dinstall dinstall: ${SERVER_DEB} ${SERVER_DBG_DEB} ${CLIENT_DEB} ${CLIENT_DBG_DEB} dpkg -i $^