From 51b0e8520c4ec4d246511f272b3764d6dbed0943 Mon Sep 17 00:00:00 2001 From: Christian Barcenas Date: Thu, 21 Aug 2025 14:46:45 -0500 Subject: [PATCH] Makefile: fix uninstall to remove filters Signed-off-by: Christian Barcenas Signed-off-by: Christian Hesse --- Makefile | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/Makefile b/Makefile index 1e2f551..b9dd501 100644 --- a/Makefile +++ b/Makefile @@ -108,6 +108,11 @@ install-pdf: doc-pdf $(INSTALL) -m 0755 -d $(DESTDIR)$(pdfdir) $(INSTALL) -m 0644 $(DOC_PDF) $(DESTDIR)$(pdfdir) +define rm_f +rm -f $(1) + +endef + uninstall: rm -f $(DESTDIR)$(CGIT_SCRIPT_PATH)/$(CGIT_SCRIPT_NAME) rm -f $(DESTDIR)$(CGIT_DATA_PATH)/cgit.css @@ -115,6 +120,8 @@ uninstall: rm -f $(DESTDIR)$(CGIT_DATA_PATH)/cgit.png rm -f $(DESTDIR)$(CGIT_DATA_PATH)/favicon.ico rm -f $(DESTDIR)$(CGIT_DATA_PATH)/robots.txt + $(foreach file,$(patsubst filters/%,%,$(shell find filters/ ! -type d)), \ + $(call rm_f,$(DESTDIR)$(filterdir)/$(file))) uninstall-doc: uninstall-man uninstall-html uninstall-pdf