-
Notifications
You must be signed in to change notification settings - Fork 1
/
pmPostInstall.script
34 lines (24 loc) · 1.01 KB
/
pmPostInstall.script
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
#!/bin/sh
ID=com.wordpress.touchcontrol.touchvol
APP_PATH=/media/cryptofs/apps/usr/palm/applications/$ID
SERVICES_PATH=/media/cryptofs/apps/usr/palm/services/$ID
if [ -z "$IPKG_OFFLINE_ROOT" ]; then
/usr/sbin/rootfs_open -w
fi
#make directories in the rare event they don't exist
/bin/mkdir -p /var/palm/ls2/services/prv
/bin/mkdir -p /var/palm/ls2/services/pub
#clean up any existing or misnamed service entries
#/bin/rm -rf /var/palm/ls2/services/prv/$ID*
#/bin/rm -rf /var/palm/ls2/services/pub/$ID*
#copy dbus service file
/bin/cp -f $SERVICES_PATH/dbus /var/palm/ls2/services/prv/$ID.service
/bin/cp -f $SERVICES_PATH/dbus /var/palm/ls2/services/pub/$ID.service
/bin/mkdir -p /var/palm/event.d
/sbin/initctl stop $ID
/bin/rm -f /var/palm/event.d/$ID
/bin/echo description \"TouchVol Service\" > /var/palm/event.d/$ID
/bin/echo start on stopped finish >> /var/palm/event.d/$ID
/bin/echo exec /usr/bin/amixer -s \< $APP_PATH/scripts/amixer-restore.state >> /var/palm/event.d/$ID
/bin/chmod 755 /var/palm/event.d/$ID
exit 0