From 965c4e578c2a4fa5120ccf284945a6a0d1fa6eba Mon Sep 17 00:00:00 2001 From: Leo Izen Date: Sun, 15 Oct 2017 14:24:50 -0400 Subject: Makefile: use "rm -f" upon cleaning and uninstalling The coreutil "rm" will by default exit with failure if it is instructed to remove a file that doesn't exist. Using "rm -f" will suppress this behavior, so "rm" will exit with success whether or not the file had existed before invoking "rm -f". --- Makefile | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/Makefile b/Makefile index c32e80c..fce9bfe 100644 --- a/Makefile +++ b/Makefile @@ -73,13 +73,12 @@ install: $(BIN) $(MAN1) cp -- LICENSE "$(DESTDIR)$(PREFIX)/share/licenses/sha3sum/" uninstall: - -cd -- "$(DESTDIR)$(PREFIX)/bin" && rm -- $(BIN) - -cd -- "$(DESTDIR)$(MANPREFIX)/man1" && rm -- $(MAN1) - -rm -- "$(DESTDIR)$(PREFIX)/share/licenses/sha3sum/LICENSE" - -rmdir -- "$(DESTDIR)$(PREFIX)/share/licenses/sha3sum" + -cd -- "$(DESTDIR)$(PREFIX)/bin" && rm -f -- $(BIN) + -cd -- "$(DESTDIR)$(MANPREFIX)/man1" && rm -f -- $(MAN1) + -rm -rf -- "$(DESTDIR)$(PREFIX)/share/licenses/sha3sum" clean: - -rm -r -- $(MAN1) $(BIN) keccak-*sum.c sha3-*sum.c rawshake*sum.c shake*sum.c .testdir + -rm -rf -- $(MAN1) $(BIN) keccak-*sum.c sha3-*sum.c rawshake*sum.c shake*sum.c .testdir .SUFFIXES: -- cgit v1.2.3-70-g09d2