adblock-fast: improve Makefile's prerm 23872/head
authorStan Grishin <stangri@melmac.ca>
Wed, 10 Apr 2024 23:56:43 +0000 (23:56 +0000)
committerStan Grishin <stangri@melmac.ca>
Wed, 10 Apr 2024 23:57:03 +0000 (23:57 +0000)
* improve output of Makefile's prerm routines

Signed-off-by: Stan Grishin <stangri@melmac.ca>
net/adblock-fast/Makefile

index c15f114e24d5c5e828f059430c34f262693d97a7..29aed1873542f1e8734b2f76a9dcfb6b850b27f9 100644 (file)
@@ -6,7 +6,7 @@ include $(TOPDIR)/rules.mk
 
 PKG_NAME:=adblock-fast
 PKG_VERSION:=1.1.1
-PKG_RELEASE:=r7
+PKG_RELEASE:=r8
 PKG_MAINTAINER:=Stan Grishin <stangri@melmac.ca>
 PKG_LICENSE:=GPL-3.0-or-later
 
@@ -69,10 +69,11 @@ define Package/adblock-fast/prerm
        #!/bin/sh
        # check if we are on real system
        if [ -z "$${IPKG_INSTROOT}" ]; then
-               echo "Stopping service and removing rc.d symlink for adblock-fast"
-               /etc/init.d/adblock-fast stop || true
-               /etc/init.d/adblock-fast killcache || true
-               /etc/init.d/adblock-fast disable || true
+               echo -n "Stopping adblock-fast service... "
+               { /etc/init.d/adblock-fast stop && \
+                 /etc/init.d/adblock-fast killcache; } >/dev/null 2>&1 && echo "OK" || echo "FAIL"
+               echo -n "Removing rc.d symlink for adblock-fast... "
+               /etc/init.d/adblock-fast disable >/dev/null 2>&1 && echo "OK" || echo "FAIL"
        fi
        exit 0
 endef