om-settings: postinst script
authorJohn Lee <john_lee@openmoko.com>
Fri, 28 Nov 2008 17:23:05 +0000 (01:23 +0800)
committerJohn Lee <john_lee@openmoko.org>
Thu, 18 Dec 2008 15:59:07 +0000 (23:59 +0800)
for some interesting reason this small program is actually
client-server based, so give it a postinst script to restart
properly after upgrade.

packages/openmoko-projects/om-settings_svn.bb

index 56b8e1d..579dd3d 100644 (file)
@@ -2,7 +2,7 @@ DESCRIPTION = "Exposure all devices on neo1973"
 DEPENDS = "python-etk python-edbus"
 RDEPENDS = "python-etk python-re python-codecs python-edbus python-pyxdg"
 PV = "0.0.1+svnr${SRCREV}"
-PR = "r2.05"
+PR = "r3"
 PE = "1"
 
 S = "${WORKDIR}/trunk"
@@ -14,3 +14,12 @@ SRC_URI = "svn://svn.projects.openmoko.org/svnroot/exposure;module=trunk;proto=h
 
 PACKAGES = "${PN}"
 FILES_${PN} += "${prefix}/share/* ${sysconfdir}/X11/Xsession.d/*"
+
+pkg_postinst_${PN} () {
+#!/bin/sh
+if test "x$D" = "x"; then
+    killall exposure.py
+    sleep 1
+    exposure.py
+fi
+}