X-Git-Url: http://git.maemo.org/git/?p=browser-switch;a=blobdiff_plain;f=debian%2Fpostrm;h=caeb3080136b16e697c20fb740a584a5da1a45e8;hp=18b7f8afcad652a53afad9a9e41f9587829bd3ee;hb=67fe09b08e609b4dcda2f29ca40dc0e6b8b77b67;hpb=10bb9f19ad2ce6a5d3de98479de2a909481b1d84 diff --git a/debian/postrm b/debian/postrm index 18b7f8a..caeb308 100644 --- a/debian/postrm +++ b/debian/postrm @@ -1,5 +1,5 @@ #!/bin/sh -# postrm script for browser-proxy +# postrm script for browser-switchboard # # see: dh_installdeb(1) @@ -19,8 +19,14 @@ set -e # the debian-policy package kill_old_proxies() { + # Kill off old python browser-switchboards, if any # This would be so much nicer with pgrep/pkill ... - proxy_pids=`busybox ps | fgrep "python /usr/bin/browser-proxy" | fgrep -v grep | awk '{ print $1 }'` + proxy_pids=`busybox ps | fgrep "python /usr/bin/browser-switchboard" | fgrep -v grep | awk '{ print $1 }'` + if [ ! -z "$proxy_pids" ]; then + kill $proxy_pids + fi + # Kill off C browser-switchboards + proxy_pids=`pidof browser-switchboard || true` if [ ! -z "$proxy_pids" ]; then kill $proxy_pids fi @@ -28,22 +34,28 @@ kill_old_proxies() { case "$1" in remove) - dpkg-divert --remove --package browser-proxy --rename \ + dpkg-divert --remove --package browser-switchboard --rename \ --divert /usr/bin/browser.tablet-browser-ui \ /usr/bin/browser - dpkg-divert --remove --package browser-proxy --rename \ + dpkg-divert --remove --package browser-switchboard --rename \ --divert /usr/share/dbus-1/services/com.nokia.osso_browser.tablet-browser-ui \ /usr/share/dbus-1/services/com.nokia.osso_browser.service # Try to make dbus-daemon pick up the change in services file kill -HUP `pidof dbus-daemon` - # Kill off any running browser-proxy to make sure that the default - # browser gets launched + # Kill off any running browser-switchboard to make sure that the + # default browser gets launched kill_old_proxies + + # Clear hildon-control-panel's cached screenshot of itself + # Workaround for https://bugs.maemo.org/show_bug.cgi?id=9512 + if [ -f /home/user/.cache/launch/com.nokia.controlpanel.pvr ]; then + rm -f /home/user/.cache/launch/com.nokia.controlpanel.pvr + fi ;; upgrade|disappear) - # Kill off any running browser-proxy to make sure that the new version - # gets launched the next time a D-Bus request is made + # Kill off any running browser-switchboard to make sure that the new + # version gets launched the next time a D-Bus request is made kill_old_proxies ;; purge|failed-upgrade|abort-install|abort-upgrade)