From 6ffbf4be86ac0b0e613d5034e77579dc5dbf5ed6 Mon Sep 17 00:00:00 2001 From: Matthias Fischmann Date: Fri, 2 Jan 2026 15:34:13 +0100 Subject: [PATCH] Make `make clean` honor $(package). --- Makefile | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Makefile b/Makefile index ecf4201345..10cb677a95 100644 --- a/Makefile +++ b/Makefile @@ -69,7 +69,12 @@ full-clean: clean .PHONY: clean clean: +ifeq ("$(package)", "all") cabal clean +else + -if ( test -e dist || test -e dist-newstyle ); then find dist* -type d -name '$(package)-*' -exec rm -rf {}; fi +endif + # `/dist` shouldn't be created or used by anybody any more, we're just making sure here. -rm -rf dist -rm -f "bill-of-materials.$(HELM_SEMVER).json"