maemo-optify-runonce

by Gary Birkett, gary.birkett@collabora.co.uk
   Claudio Saavedra, csaavedra@igalia.com
   Leonid Moiseichuk, leonid.moiseichuk@nokia.com
   Karpov Denis, ext-denis.2.karpov@nokia.com

########################################################################
* Overview

set of scripts to perform /opt cleanup tasks at system startup.
gain additional space in the file system and allow lots of extra 
applications to be installed :)

principle tasks:
	clear dirty /home/opt after reflashing device
	move default data in rootfs /opt into /home/opt
	automatically optify a set of folders on each bootup

########################################################################
** maemo-optify-firstboot.sh optification process

runs at boot time before /opt is mountbound
runs only if /var/lib/maemo-optify-firstboot-do-not-clean-home-opt does not exist

	clear dirty /home/opt after reflashing device
	move default data in rootfs /opt into /home/opt
	create /var/lib/maemo-optify-firstboot-do-not-clean-home-opt
	
########################################################################
** maemo-optify-auto-opt.sh optification process

runs in postinst and also in boot sequence
works by testing each folder listed in the config file and if not already 
optified will proceed to optify the entire folder.

input: /etc/maemo-optify-auto-opt.conf

the process for optifying a single folder proceeds as such:

first, the script tests that the specified path is *not* already symlinked.
if a symlink is detected, this folder is ignored and will not be 
optified further.

	clean any existing data on the /opt/[item] folder
	move original data from /*/[item] into its /opt/[opt] folder
	create a symlink from /*/[item] to /opt/[item]

this is repeated for each valid path specified in the options file.


