diff options
author | Steve Kondik <shade@chemlab.org> | 2010-07-05 23:09:35 -0400 |
---|---|---|
committer | Steve Kondik <shade@chemlab.org> | 2010-07-05 23:09:52 -0400 |
commit | 8794d1afc95e3cf3d5e15db26890620bed9c0fe9 (patch) | |
tree | ea89bca2eff44026500e2963d4518e8c7de92001 /prebuilt/common/etc/init.d/20userinit | |
parent | f32d926b54e8e5b5e66330be7bfefe6f47607bf0 (diff) | |
download | vendor_replicant-8794d1afc95e3cf3d5e15db26890620bed9c0fe9.zip vendor_replicant-8794d1afc95e3cf3d5e15db26890620bed9c0fe9.tar.gz vendor_replicant-8794d1afc95e3cf3d5e15db26890620bed9c0fe9.tar.bz2 |
Add init.d stuff.
Diffstat (limited to 'prebuilt/common/etc/init.d/20userinit')
-rwxr-xr-x | prebuilt/common/etc/init.d/20userinit | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/prebuilt/common/etc/init.d/20userinit b/prebuilt/common/etc/init.d/20userinit new file mode 100755 index 0000000..ca88f83 --- /dev/null +++ b/prebuilt/common/etc/init.d/20userinit @@ -0,0 +1,21 @@ +#!/system/bin/sh +# call a userinit.sh script if it's present on the sdcard + +if [ "$SD_EXT_DIRECTORY" = "" ]; +then + SD_EXT_DIRECTORY=/sd-ext; +fi; + +if [ -e $SD_EXT_DIRECTORY/userinit.sh ]; +then + log -p i -t userinit "Executing $SD_EXT_DIRECTORY/userinit.sh"; + busybox chmod +x $SD_EXT_DIRECTORY/userinit.sh; + logwrapper /system/bin/sh $SD_EXT_DIRECTORY/userinit.sh; + setprop cm.userinit.active 1; +fi; + +if [ -d $SD_EXT_DIRECTORY/userinit.d ]; +then + logwrapper busybox run-parts $SD_EXT_DIRECTORY/userinit.d; + setprop cm.userinit.active 1; +fi; |