divert busybox binary to /opt/busybox-power/
[busybox-power] / debian / busybox-power.prerm
index 66c3c34..4e23d46 100644 (file)
@@ -13,7 +13,7 @@
 
 INSTALLDIR="/opt/busybox-power"
 EXECPWR="$INSTALLDIR/busybox.power"
-DISTBIN="/bin/busybox.distrib"
+DISTBIN="$INSTALLDIR/busybox.distrib"
 
 VERBOSE="0"
 MODIFIEDBIN="0"
@@ -85,15 +85,16 @@ CHECK_INSTALLEDBIN() {
             return
           fi
         fi
-        echo -e "Warning: /bin/busybox has been modified since installing" \
-          "busybox-power. This can be the result of a BusyBox upgrade (e.g." \
-          "by a Meego update). Your current /bin/busybox won't be touched." \
-          "Our backup of the original BusyBox binary will be left at" \
-          "$DISTBIN.\n" >> /tmp/busybox-power-error
+        echo -e "Warning: /bin/busybox does not match busybox-power's binary" \
+          "This can be the result of a BusyBox upgrade (e.g. by a MeeGo" \
+          "update), an unsuccessful busybox-power installation, or a manual" \
+          "replacement of it. Your current /bin/busybox won't be touched. Our" \
+          "backup of the original BusyBox binary will be left at $DISTBIN.\n" \
+          >> /tmp/busybox-power-error
       else
-        echo -e "Warning: /bin/busybox has been modified since installing" \
-          "busybox-power. Your current /bin/busybox won't be touched and the" \
-          "diversion of /bin/busybox to $DISTBIN will not be removed.\n" \
+        echo -e "Warning: /bin/busybox does not match busybox-power's binary." \
+          "Your current /bin/busybox won't be touched and the diversion of" \
+          "/bin/busybox to $DISTBIN will not be removed.\n" \
           >> /tmp/busybox-power-error
       fi
     fi
@@ -110,7 +111,7 @@ DISPLAY_ERRORS() {
         echo "   Hit [ctrl-c] to break"
         read 
         ;;
-      FREMANTLE)
+      DIABLO|FREMANTLE)
         echo "Click \"I Agree\" to ignore the above errors/warnings. Ask for" \
           "help if you don't know what to do." >> /tmp/busybox-power-error
         echo "Please confirm the text on the screen of your device"
@@ -152,7 +153,7 @@ UNINSTALL() {
     fi
 
     case $ENVIRONMENT in
-      SDK|FREMANTLE)
+      SDK|DIABLO|FREMANTLE)
         if test -e $DISTBIN; then
           cp -af $DISTBIN /bin/busybox
           if test -e /bin/busybox; then