summaryrefslogtreecommitdiffstats
path: root/busybox.pkg/prerm
diff options
context:
space:
mode:
Diffstat (limited to 'busybox.pkg/prerm')
-rwxr-xr-xbusybox.pkg/prerm18
1 files changed, 12 insertions, 6 deletions
diff --git a/busybox.pkg/prerm b/busybox.pkg/prerm
index 63b465e..5e7cf79 100755
--- a/busybox.pkg/prerm
+++ b/busybox.pkg/prerm
@@ -1,10 +1,16 @@
#!/bin/sh
if [ "${1}" = remove ]; then
- update-alternatives --remove awk /usr/bin/awk.busybox
- update-alternatives --remove ar /usr/bin/ar.busybox
- update-alternatives --remove strings /usr/bin/strings.busybox
- update-alternatives --remove clear /usr/bin/clear.busybox
- update-alternatives --remove reset /usr/bin/reset.busybox
- update-alternatives --remove mkpasswd /usr/bin/mkpasswd.busybox
+ while read link name prio; do
+ if [ -e "${link}.busybox" ]; then
+ update-alternatives --remove "${name}" "${link}.busybox"
+ fi
+ done <<-EOF
+ /usr/bin/awk awk 10
+ /usr/bin/ar ar 10
+ /usr/bin/strings strings 10
+ /usr/bin/clear clear 10
+ /usr/bin/reset reset 10
+ /usr/bin/mkpasswd mkpasswd 10
+ EOF
fi