assert(getprop("ro.product.device") == "galaxys" || getprop("ro.build.product") == "galaxys" || 
       getprop("ro.product.device") == "galaxysmtd" || getprop("ro.build.product") == "galaxysmtd" || 
       getprop("ro.product.device") == "GT-I9000" || getprop("ro.build.product") == "GT-I9000" || 
       getprop("ro.product.device") == "GT-I9000M" || getprop("ro.build.product") == "GT-I9000M" || 
       getprop("ro.product.device") == "GT-I9000T" || getprop("ro.build.product") == "GT-I9000T");
	   
ui_print("-------------------------------");
ui_print(" Onecosmic ICS RC3.1 I9000 AOSP  ");
ui_print("-------------------------------");
ui_print("           INSTALLING          ");
ui_print("-------------------------------");
ui_print(" ");
show_progress(1.000000, 0);

ui_print("Preparing ROM...");
ui_print("-Extracting Installation Files...");
set_progress(0.050000);
package_extract_file("modem.bin", "/tmp/modem.bin");
set_perm(0, 0, 0777, "/tmp/modem.bin");
package_extract_file("updater.sh", "/tmp/updater.sh");
set_perm(0, 0, 0777, "/tmp/updater.sh");
package_extract_file("make_ext4fs", "/tmp/make_ext4fs");
set_perm(0, 0, 0777, "/tmp/make_ext4fs");
package_extract_file("busybox", "/tmp/busybox");
set_perm(0, 0, 0777, "/tmp/busybox");
package_extract_file("flash_image", "/tmp/flash_image");
set_perm(0, 0, 0777, "/tmp/flash_image");
package_extract_file("erase_image", "/tmp/erase_image");
set_perm(0, 0, 0777, "/tmp/erase_image");
package_extract_file("bml_over_mtd", "/tmp/bml_over_mtd");
set_perm(0, 0, 0777, "/tmp/bml_over_mtd");
package_extract_file("bml_over_mtd.sh", "/tmp/bml_over_mtd.sh");
set_perm(0, 0, 0777, "/tmp/bml_over_mtd.sh");
package_extract_file("boot.img", "/tmp/boot.img");
set_progress(0.090000);
ui_print("");
ui_print("-Running Updater...");
assert(run_program("/tmp/updater.sh") == 0);
set_progress(0.100000);


ui_print("");
ui_print("-Formatting Partitions");
ui_print("");
ui_print("");
set_progress(0.200000);
ui_print("-Formatting System...");
format("yaffs2", "MTD", "system", "0");
set_progress(0.300000);
ui_print("");
ui_print("");
ui_print("-Formatting /Cache...");
format("yaffs2", "MTD", "cache", "0");
set_progress(0.400000);

ui_print(" ");
ui_print("Installing ROM...");
mount("yaffs2", "MTD", "system", "/system");
package_extract_dir("system", "/system");
set_progress(0.500000);

ui_print("-Setting Symlinks...");
symlink("Roboto-Bold.ttf", "/system/fonts/DroidSans-Bold.ttf");
symlink("Roboto-Regular.ttf", "/system/fonts/DroidSans.ttf");
symlink("busybox", "/system/xbin/[", "/system/xbin/[[",
        "/system/xbin/arp", "/system/xbin/ash", "/system/xbin/awk",
        "/system/xbin/base64", "/system/xbin/basename", "/system/xbin/bbconfig",
        "/system/xbin/blockdev", "/system/xbin/brctl", "/system/xbin/bunzip2",
        "/system/xbin/bzcat", "/system/xbin/bzip2", "/system/xbin/cal",
        "/system/xbin/cat", "/system/xbin/catv", "/system/xbin/chattr",
        "/system/xbin/chgrp", "/system/xbin/chmod", "/system/xbin/chown",
        "/system/xbin/chroot", "/system/xbin/clear", "/system/xbin/cmp",
        "/system/xbin/comm", "/system/xbin/cp", "/system/xbin/cpio",
        "/system/xbin/crond", "/system/xbin/crontab", "/system/xbin/cut",
        "/system/xbin/date", "/system/xbin/dc", "/system/xbin/dd",
        "/system/xbin/depmod", "/system/xbin/devmem", "/system/xbin/df",
        "/system/xbin/diff", "/system/xbin/dirname", "/system/xbin/dmesg",
        "/system/xbin/dnsd", "/system/xbin/dos2unix", "/system/xbin/du",
        "/system/xbin/echo", "/system/xbin/ed", "/system/xbin/egrep",
        "/system/xbin/env", "/system/xbin/expand", "/system/xbin/expr",
        "/system/xbin/false", "/system/xbin/fdisk", "/system/xbin/fgrep",
        "/system/xbin/find", "/system/xbin/flash_lock",
        "/system/xbin/flash_unlock", "/system/xbin/flashcp",
        "/system/xbin/flock", "/system/xbin/fold", "/system/xbin/free",
        "/system/xbin/freeramdisk", "/system/xbin/fsync", "/system/xbin/ftpget",
        "/system/xbin/ftpput", "/system/xbin/fuser", "/system/xbin/getopt",
        "/system/xbin/grep", "/system/xbin/groups", "/system/xbin/gunzip",
        "/system/xbin/gzip", "/system/xbin/halt", "/system/xbin/head",
        "/system/xbin/hexdump", "/system/xbin/id", "/system/xbin/ifconfig",
        "/system/xbin/insmod", "/system/xbin/install", "/system/xbin/iostat",
        "/system/xbin/ip", "/system/xbin/kill", "/system/xbin/killall",
        "/system/xbin/killall5", "/system/xbin/length", "/system/xbin/less",
        "/system/xbin/ln", "/system/xbin/losetup", "/system/xbin/ls",
        "/system/xbin/lsattr", "/system/xbin/lsmod", "/system/xbin/lsusb",
        "/system/xbin/lzcat", "/system/xbin/lzma", "/system/xbin/lzop",
        "/system/xbin/lzopcat", "/system/xbin/man", "/system/xbin/md5sum",
        "/system/xbin/mesg", "/system/xbin/mkdir", "/system/xbin/mke2fs",
        "/system/xbin/mkfifo", "/system/xbin/mkfs.ext2",
        "/system/xbin/mkfs.vfat", "/system/xbin/mknod", "/system/xbin/mkswap",
        "/system/xbin/mktemp", "/system/xbin/modinfo", "/system/xbin/modprobe",
        "/system/xbin/more", "/system/xbin/mount", "/system/xbin/mountpoint",
        "/system/xbin/mpstat", "/system/xbin/mv", "/system/xbin/nanddump",
        "/system/xbin/nandwrite", "/system/xbin/netstat", "/system/xbin/nice",
        "/system/xbin/nohup", "/system/xbin/nslookup", "/system/xbin/ntpd",
        "/system/xbin/od", "/system/xbin/patch", "/system/xbin/pgrep",
        "/system/xbin/pidof", "/system/xbin/ping", "/system/xbin/pkill",
        "/system/xbin/pmap", "/system/xbin/poweroff", "/system/xbin/printenv",
        "/system/xbin/printf", "/system/xbin/ps", "/system/xbin/pstree",
        "/system/xbin/pwd", "/system/xbin/pwdx", "/system/xbin/rdev",
        "/system/xbin/readlink", "/system/xbin/realpath", "/system/xbin/renice",
        "/system/xbin/reset", "/system/xbin/resize", "/system/xbin/rev",
        "/system/xbin/rm", "/system/xbin/rmdir", "/system/xbin/rmmod",
        "/system/xbin/route", "/system/xbin/run-parts", "/system/xbin/rx",
        "/system/xbin/sed", "/system/xbin/seq", "/system/xbin/setconsole",
        "/system/xbin/setserial", "/system/xbin/setsid", "/system/xbin/sh",
        "/system/xbin/sha1sum", "/system/xbin/sha256sum",
        "/system/xbin/sha512sum", "/system/xbin/sleep", "/system/xbin/sort",
        "/system/xbin/split", "/system/xbin/stat", "/system/xbin/strings",
        "/system/xbin/stty", "/system/xbin/sum", "/system/xbin/swapoff",
        "/system/xbin/swapon", "/system/xbin/sync", "/system/xbin/sysctl",
        "/system/xbin/tac", "/system/xbin/tail", "/system/xbin/tar",
        "/system/xbin/tee", "/system/xbin/telnet", "/system/xbin/telnetd",
        "/system/xbin/test", "/system/xbin/tftp", "/system/xbin/tftpd",
        "/system/xbin/time", "/system/xbin/timeout", "/system/xbin/top",
        "/system/xbin/touch", "/system/xbin/tr", "/system/xbin/traceroute",
        "/system/xbin/true", "/system/xbin/ttysize", "/system/xbin/tune2fs",
        "/system/xbin/umount", "/system/xbin/uname", "/system/xbin/uncompress",
        "/system/xbin/unexpand", "/system/xbin/uniq", "/system/xbin/unix2dos",
        "/system/xbin/unlzma", "/system/xbin/unlzop", "/system/xbin/unxz",
        "/system/xbin/unzip", "/system/xbin/uptime", "/system/xbin/usleep",
        "/system/xbin/uudecode", "/system/xbin/uuencode", "/system/xbin/vi",
        "/system/xbin/watch", "/system/xbin/wc", "/system/xbin/wget",
        "/system/xbin/which", "/system/xbin/whoami", "/system/xbin/xargs",
        "/system/xbin/xz", "/system/xbin/xzcat", "/system/xbin/yes",
        "/system/xbin/zcat");
symlink("mksh", "/system/bin/sh");
symlink("toolbox", "/system/bin/cat", "/system/bin/chmod",
        "/system/bin/chown", "/system/bin/cmp", "/system/bin/date",
        "/system/bin/dd", "/system/bin/df", "/system/bin/dmesg",
        "/system/bin/getevent", "/system/bin/getprop", "/system/bin/hd",
        "/system/bin/id", "/system/bin/ifconfig", "/system/bin/iftop",
        "/system/bin/insmod", "/system/bin/ioctl", "/system/bin/ionice",
        "/system/bin/kill", "/system/bin/ln", "/system/bin/log",
        "/system/bin/ls", "/system/bin/lsmod", "/system/bin/lsof",
        "/system/bin/mkdir", "/system/bin/mount", "/system/bin/mv",
        "/system/bin/nandread", "/system/bin/netstat",
        "/system/bin/newfs_msdos", "/system/bin/notify", "/system/bin/printenv",
        "/system/bin/ps", "/system/bin/r", "/system/bin/reboot",
        "/system/bin/renice", "/system/bin/rm", "/system/bin/rmdir",
        "/system/bin/rmmod", "/system/bin/route", "/system/bin/schedtop",
        "/system/bin/sendevent", "/system/bin/setconsole",
        "/system/bin/setprop", "/system/bin/sleep", "/system/bin/smd",
        "/system/bin/start", "/system/bin/stop", "/system/bin/sync",
        "/system/bin/top", "/system/bin/touch", "/system/bin/umount",
        "/system/bin/uptime", "/system/bin/vmstat", "/system/bin/watchprops",
        "/system/bin/wipe");
symlink("/system/bin/su", "/system/xbin/su");
set_progress(0.700000);
ui_print("");
ui_print("-Retouching binaries...");
retouch_binaries("/system/lib/bluez-plugin/audio.so", "70256f0eb524f0396964ea3fa9099320bcbba525", "/system/lib/bluez-plugin/bluetooth-health.so", "76eb5ab08976da0c6d9776d2eee04bf4216e967e", "/system/lib/bluez-plugin/input.so", "afb0104ac03d5acf13a0914ae8d58a773c0425cb", "/system/lib/bluez-plugin/network.so", "dc7387933041d9c7c638755e972019060f8ceb26", "/system/lib/drm/libfwdlockengine.so", "45897faa40e60441b6b9785490db2c3d7900abdc", "/system/lib/egl/egl.cfg", "4e15b5998fb2f237bb2d4cadf3efff147d50c9b3", "/system/lib/egl/libGLES_android.so", "36c64e1bf8348e5efb13ef95960a4ab439bedbff", "/system/lib/hw/audio.a2dp.default.so", "ff3d1d37e477d778ce311b0bb3bac4883cd79353", "/system/lib/hw/audio.primary.aries.so", "d1560c464892376a7f3d5d03a22520c0f3cefb88", "/system/lib/hw/audio.primary.default.so", "2a49c5e010f6a727eebe83d387241a9076f4355f", "/system/lib/hw/audio.primary.goldfish.so", "a3ea901acebd72e506a0548d21cee924360346e3", "/system/lib/hw/audio_policy.aries.so", "22107654b5e73c6218748d850cca1c1e3fe90908", "/system/lib/hw/audio_policy.default.so", "8f26c31664d1a50bbfe47afbd19f305e3bb82f71", "/system/lib/hw/camera.aries.so", "aaf8a8604d66907f6a2947b16074f7bc61de8c0d", "/system/lib/hw/camera.goldfish.so", "6d2875d51a1fc1e2de9b0ff8423482bcc2dea499", "/system/lib/hw/gps.goldfish.so", "8a5b84daf789f8660a2112d944fd9e16c01cd495", "/system/lib/hw/gralloc.default.so", "c7a776e6c435c45374432ce08093b9394a838e02", "/system/lib/hw/hwcomposer.aries.so", "6f4d8c0eb65a81efb3a77d7f0d86a331a5d65217", "/system/lib/hw/lights.aries.so", "1dc931623dc86805ac9d771eb51d25cd9e4a0c1b", "/system/lib/hw/lights.goldfish.so", "e0d700509dd80c9b0121d61303e7e7896cd74419", "/system/lib/hw/sensors.aries.so", "e3a7664327686fdd61649194b3de001fab280f61", "/system/lib/hw/sensors.goldfish.so", "220d37bcde6324f80fce158bae0fb7c9ae5aded3", "/system/lib/libEGL.so", "fc6117b33c90cf66bdcfd5a96bf751592e504f4e", "/system/lib/libETC1.so", "d521b0376af9925a3c1f68039c88c969cf4dbe4f", "/system/lib/libFFTEm.so", "5a354a894b5900eeee14fb5ff41a05d9cbddc23b", "/system/lib/libGLESv1_CM.so", "a3b749d216a6a87ec532c6b4bd8a0810303810cf", "/system/lib/libGLESv2.so", "4c804b6d28b22e8c2d9e4b7891a0101b318609c6", "/system/lib/libGLESv2_dbg.so", "103541102c65fae1e6d4dd62f7145f9d8d998c91", "/system/lib/libOMX.SEC.AVC.Decoder.aries.so", "34c13f100071c77fb22968de73f4eee55ec2893b", "/system/lib/libOMX.SEC.AVC.Encoder.aries.so", "d4661ccebb81ff8bb10600e2d07cf9fcbeaa76ee", "/system/lib/libOMX.SEC.M4V.Decoder.aries.so", "2f4e859ce723a5641bc4ab44dceadca44597d1ce", "/system/lib/libOMX.SEC.M4V.Encoder.aries.so", "dfbbefb4098376cb8cb282aeea4034acd9b6335a", "/system/lib/libOpenMAXAL.so", "826eb07c5b7d303adfef5a1abe6af3cb8b78144c", "/system/lib/libOpenSLES.so", "c29da4888a4463538c7663723fc6d3a0a18437a9", "/system/lib/libQmageDecoder.so", "f6d1c64f7879f840dabfaaae5b28eeffc0c2757d", "/system/lib/libRS.so", "2aad5fc8843c02d6b86cc7752ac4f2686853718a", "/system/lib/libSEC_OMX_Core.aries.so", "fe0005736cfd807288e3f78bb49d71ed930832f5", "/system/lib/libSR_AudioIn.so", "163cb664ffc1995d7aec4d605ac9e017ad36a25f", "/system/lib/lib_tvoutengine.so", "5d08edb2fc8ab397e072460b819da619d686ab7d", "/system/lib/libandroid.so", "67ce3e226963951bbd8180ad206045ef773fdc97", "/system/lib/libandroid_runtime.so", "7bed64ffd9cafd37bf04fefa57320148c0a599fe", "/system/lib/libandroid_servers.so", "a1ed4e74090a0ecd1f502e598639397b2c980acf", "/system/lib/libaudioeffect_jni.so", "6843a8f69b2e658f31c5a7dd3999abf7c3d21785", "/system/lib/libaudioflinger.so", "b5c206eb92fe63a71f502dc7c8fb36855e392a3a", "/system/lib/libaudioutils.so", "687dfa098c3bf913f90dea3b6023f7373f81b3d0", "/system/lib/libbcc.so", "30c9d284c81a306307fb062e83b3237d86b5e39a", "/system/lib/libbcc.so.sha1", "af1f7d372d8b3c099323bb7428b184ee3e361aad", "/system/lib/libbcinfo.so", "5542be829146303c788ad6b2ec58e007f284b0a5", "/system/lib/libbinder.so", "0acaaaaaf7a1dcd2e4e2e6415eb8b6d863535824", "/system/lib/libbluedroid.so", "6cd951dd5058fcc8d6b0727c564cd5499623d4fa", "/system/lib/libbluetooth.so", "7fecf7302a3f1f75e1cecc19443fd4fdfe8cd421", "/system/lib/libbluetoothd.so", "4861f40026234a6318e162a407b8596e6c30e5f2", "/system/lib/libbtio.so", "a69a4597ca402bbcf3c26ba55c50b9012918abca", "/system/lib/libc.so", "e3d303eaf07abd4c9dbf03e60a8817132fb14ef0", "/system/lib/libc_malloc_debug_leak.so", "d3463cd876838b390edc786871f2e5a50834b166", "/system/lib/libc_malloc_debug_qemu.so", "6f9de6d575a422cf85f8400996bb6fb79877afa8", "/system/lib/libcamera_client.so", "f6c459716ce4eeff8d15bec23b34a5d7a0ed8c88", "/system/lib/libcameraservice.so", "18e152234da9bb1602157923b2d52b21027ee643", "/system/lib/libchromium_net.so", "42126ceca1ef72bf20dc6c77ca6f4c938978a5a6", "/system/lib/libclcore.bc", "a1e2610fdc0c2ef151248092fa32be807d1b983d", "/system/lib/libcrypto.so", "cbb81fa4dce652d1ab3b575a9688719f59a3174c", "/system/lib/libctest.so", "55573773f5bc6af64fb597a3f291eca947a80515", "/system/lib/libcutils.so", "c21d9c631c945b81df9a96d97bf0c9c4fedc5b32", "/system/lib/libdbus.so", "602c05dbe5d86495b783ee67497d8a3f4014c320", "/system/lib/libdefcontainer_jni.so", "7ccd140c23dfb4bd10f299c53f5b57f3d10cc74d", "/system/lib/libdiskconfig.so", "d0418fc41532e99355dae92104e12e91cbaf1517", "/system/lib/libdl.so", "f9b9cf627a566ce28396831f1614cb0670f6fb01", "/system/lib/libdrm1.so", "f53bd91bcaa089e2fd8e8af694aedb4c777dd6eb", "/system/lib/libdrm1_jni.so", "9ad939fd7a710311dbeaf39694027e5189630d0a", "/system/lib/libdrmframework.so", "91c229c7c38219efaeb2e71aae0d8dc230db8e19", "/system/lib/libdrmframework_jni.so", "5eb6a2515be9fc78c6302b1cb25632f3a4d05728", "/system/lib/libdvm.so", "2efd58605e1bfd2961583ba39c99a7a4246b8ef3", "/system/lib/libeffects.so", "0b7109fbc753333ee37638411f3a71f475ee10ac", "/system/lib/libemoji.so", "fc1efd5fc28d07f198b660081755e73f9cd7ccea", "/system/lib/libexif.so", "84532c71d93c5c6610669ff1095e302b55ba2581", "/system/lib/libexpat.so", "3da2819e85d8a1f581160a2b415ac0a2ac036cf9", "/system/lib/libext2_blkid.so", "9361e7643d3d40b243f2d0c0e97f995c7f6c3d12", "/system/lib/libext2_com_err.so", "cef282c1a1caf2dbac98f688f33cbf4507372013", "/system/lib/libext2_e2p.so", "9cac3a12c9a89bd420cf79a28f7770b57e976a17", "/system/lib/libext2_profile.so", "c077c171e21df18a83737b4b76d75f4893ff08f4", "/system/lib/libext2_uuid.so", "c0f4d1e44c74486536b4a146fb7e7be320115cbb", "/system/lib/libext2fs.so", "8850bfd7e493aef1665afb93bc96c82fed77c255", "/system/lib/libext4_utils.so", "2f4146e2cbf1c751878592f2aa1b4171accc3f03", "/system/lib/libfilterfw.so", "c9af7d161262db2e97740092aa88b98475a9286e", "/system/lib/libfilterpack_imageproc.so", "479519ec2b56f58ed2e5ef6df535f1281485412b", "/system/lib/libgabi++.so", "bfe1d58fba12152e6467a4e2d99eeed05feaa6ff", "/system/lib/libglib.so", "d1c255930b63f0501168b09c2ce3f58ca1409c8d", "/system/lib/libgui.so", "be054864a489cfb1b638ca1cfe3ef090db6252d6", "/system/lib/libhardware.so", "f28deb878479847c572d58bf4d760a3d32a743e6", "/system/lib/libhardware_legacy.so", "2a25ef881afc98d61ec51e9d9a7fb23b920ab98d", "/system/lib/libharfbuzz.so", "dffa60217ecc89b7ca3f6a45f143082c3f21f159", "/system/lib/libhwui.so", "80ff4471396198e83ad4301a93b43c0205b2eb43", "/system/lib/libicui18n.so", "74f1194e03d7a66b66b7b8dc8f28ccfb8cd28fa1", "/system/lib/libicuuc.so", "3758ead9315bf1590bb7af1b74d5002bafa90dd9", "/system/lib/libinput.so", "8a64515a90c34639beecc63b8bf1e8471ed2bb79", "/system/lib/libiprouteutil.so", "442a765ae61521f375fe94e0a63150aee22fce66", "/system/lib/libjni_latinime.so", "cff93f0567c8f99a097e412d4aab46ab749a3492", "/system/lib/libjni_mosaic.so", "e4283a9663e1b1624f91c4d6c37b3d83b65b7ec5", "/system/lib/libjnigraphics.so", "6a14d35dbb64cc6120a8a29b6581452afee9a62f", "/system/lib/libjpeg.so", "5e23835104c9f10b1c0765598daee80ca7a2a194", "/system/lib/liblog.so", "b56ccba02a37a0009b6aa34ae966f890ec7d9e07", "/system/lib/libm.so", "4872e8207d7503b54292658dbe810836f0e603a7", "/system/lib/libmedia.so", "9219a8bf01b63722f40ea52cb3d0aa5a667400a3", "/system/lib/libmedia_jni.so", "396a946dbf769d0d078b3705c7c81136bd419bab", "/system/lib/libmediaplayerservice.so", "c852e7ef553d212deaf01447add483d56356ef64", "/system/lib/libmtp.so", "a0935d90ceeb234410c5ae347a6925b7b1c0e5d3", "/system/lib/libnativehelper.so", "ad9d728ec1c627856d10ad76a7f8b686b5b820f1", "/system/lib/libncurses.so", "b8f1c38e3f9923dd8a6855b48bdb86c324549d6a", "/system/lib/libnetlink.so", "3d7765c470397a34affba5b2c8be1a14187cde50", "/system/lib/libnetutils.so", "eb379e3230b1974d93dd6ec58ad82d08bc50cde5", "/system/lib/libnfc_ndef.so", "4efd7ebef553d151e08906573151d2d38e52d909", "/system/lib/libpagemap.so", "44afdf97e000d7243b694e1d863a77bf719c18da", "/system/lib/libpixelflinger.so", "d9d0f1d7ef1ea49866ec8a325975e4b42a316b4f", "/system/lib/libpng.so", "e1f4730a2178a298683ed496bc6c27879f91a10a", "/system/lib/libpower.so", "4f6135137d3e4187674883509a6945ab7193e16f", "/system/lib/libpowermanager.so", "80bb9ee795e5c9b72851c8a2bd3771bcbe632f66", "/system/lib/libreference-ril.so", "c9a95a9fa5e1890572b5f1fef637a8ae53e70316", "/system/lib/libril.so", "3cb210eec49d341098db06a540a72c1cf6c531a4", "/system/lib/librs_jni.so", "26453e562bc063158ad974ad00674a73083088d9", "/system/lib/librtp_jni.so", "df77e2ed2a2b9c19a405c012962a0c26eed96e2f", "/system/lib/libs3cjpeg.so", "6206bf8e138b25cc7da8de02954388f604284ec6", "/system/lib/libsec-ril.so", "cd1cdc4f922c1a37b0e4f72245d958a4ca10e65d", "/system/lib/libsecril-client.so", "a4cb7e1bcd5f17d053d6d7dc79a3e15ba76c3535", "/system/lib/libsensorservice.so", "f5121915a6156c314360de88d9af834ef9e71f23", "/system/lib/libskia.so", "1b9a34d4298f34751f1c6f9930701ee51fff3e34", "/system/lib/libsonivox.so", "ad48dacee06bc604294445e27ca062d55d1c47eb", "/system/lib/libsoundpool.so", "b1f320bd308f698cf82b3b4d5f262ec1f186afae", "/system/lib/libspeexresampler.so", "42455b735800d34422289db6ee7783e90d71a095", "/system/lib/libsqlite.so", "80a4c111cdaafb3456f8f9f81faaf31110b4173a", "/system/lib/libsqlite_jni.so", "ae050d3f36eff9d6b5c5851f453139d607283f48", "/system/lib/libsrec_jni.so", "d573e7c304bcfb7488f1612b4c3e9d40c5c57a67", "/system/lib/libssl.so", "c379cbce769d322f30fabb35a06ab527fb755133", "/system/lib/libstagefright.so", "65d8665ea606b8f93bfadafc28908a5afd0ccc62", "/system/lib/libstagefright_amrnb_common.so", "a9be4e0e97688ec238dddb1365587c0e7831413d", "/system/lib/libstagefright_avc_common.so", "fad2100a93b27fccacc445d05691c722e2b161f6", "/system/lib/libstagefright_enc_common.so", "a4342677bc91d3088ca58e7643c902a57e8f5e9a", "/system/lib/libstagefright_foundation.so", "7f38ea78f5caac14f179f89b53f8db9ca181992b", "/system/lib/libstagefright_omx.so", "0cec769a6503e0aa024838939da87bc959922b80", "/system/lib/libstagefright_soft_aacdec.so", "36b0b2326a05ae66fdcc86ccd31f6f6ebda0876b", "/system/lib/libstagefright_soft_amrdec.so", "673f8b502c50d7f8977bc2ffcef0534b130fead0", "/system/lib/libstagefright_soft_g711dec.so", "59a5fa5c6b67f18251dd14dc50d67af2ad3f0953", "/system/lib/libstagefright_soft_h264dec.so", "9b1cc1a3100263c49da0b4bde3bf38cbdebb2578", "/system/lib/libstagefright_soft_mp3dec.so", "2a5974d98123a2a92ddaa1409e2323dd1d1a4101", "/system/lib/libstagefright_soft_mpeg4dec.so", "0af594cfda41fe3a50ecf7634890845f6087ebab", "/system/lib/libstagefright_soft_vorbisdec.so", "330f8f3e32332b25ce39e9fa2d7593a3ed204221", "/system/lib/libstagefright_soft_vpxdec.so", "cbbf0e4339d339b378a069aac4b8400a1b5ea83a", "/system/lib/libstagefright_yuv.so", "790021357483d6e77503702afecb8237726fd206", "/system/lib/libstagefrighthw.so", "57b0027e23d1145160f6092e7b0151949fa8f85c", "/system/lib/libstdc++.so", "fc6dd5916a22afd724a6649cf833249d99b9767c", "/system/lib/libstlport.so", "6b66c0a95c9782fac80a6394c50941b8346fbc7d", "/system/lib/libsurfaceflinger.so", "6caf7ae06ded2b76eb7c28b2f1bcdd10d73caa3b", "/system/lib/libsurfaceflinger_client.so", "12ba180d276b44d96e23f91c3d328f6ffdeed0eb", "/system/lib/libsystem_server.so", "2ecab72d253313aae314c9f1861c42e929cae3c6", "/system/lib/libsysutils.so", "7c39be75f3e0553b1daa85bb34878b50c9294ebb", "/system/lib/libthread_db.so", "adf668c740a099fa79b35734d40f05615153895b", "/system/lib/libtinyalsa.so", "401629cb55a2c86c458ec79479e50bf3fd41101f", "/system/lib/libttscompat.so", "65037bcd4b76383325fde00797277861322ecdac", "/system/lib/libttspico.so", "2ff6124539a06c16644f83b27b282f2d0d56114f", "/system/lib/libtvout.so", "fb0c11cc431a83f5de90e549e613f9a873cde563", "/system/lib/libtvout_jni.so", "6e9b240e39afcc1e22adeae208fd2901ab585df6", "/system/lib/libtvoutfimc.so", "c481ae58b1f2307e4ab44bd86f43fcaf15cfa9bf", "/system/lib/libtvouthdmi.so", "7d1b5390047bc8f6d59b614e60c6756ea21d3d48", "/system/lib/libtvoutservice.so", "c625aa3c07476f83c391cb4e0ce1d2b9a9a79e37", "/system/lib/libui.so", "e44784a79a39b8741b03f1a7d5e4d090bb5db515", "/system/lib/libusbhost.so", "3c1acf043823239b08e3a598b962d074ab18e5e2", "/system/lib/libutils.so", "d01574f50c6ed643914f40e70cc0db728fa381b0", "/system/lib/libvariablespeed.so", "19e37c747f4c498ffa38bb6667a94dc2ea9d7a75", "/system/lib/libvideoeditor_jni.so", "7d632e285a53223285ad9cb5d4eef883d35ee70c", "/system/lib/libvideoeditorplayer.so", "3b44697f8c7aba0f7eb0570e63485c72ed778ee9", "/system/lib/libvorbisidec.so", "75281cf6de4678843b6cb17061fb8f33c4abcc3f", "/system/lib/libwebcore.so", "a531f1efa40a1cdd2ce60913167f8a9f0d62c5b4", "/system/lib/libwebrtc_audio_preprocessing.so", "38f00139dd70b8bc5fd8080e0fc81e60a3a60010", "/system/lib/libwilhelm.so", "d5ee4f1357aa280a49abff04778af0f8a63fbe96", "/system/lib/libwpa_client.so", "faa813ff759b52db39c1e6002b9e8f61b3f92b88", "/system/lib/libz.so", "a533a779bbd38818b28347cf1b246e3987323db2", "/system/lib/modules/cifs.ko", "d5ea850798aca6e929ffc9cb8c27ccaf45c3b482", "/system/lib/modules/fuse.ko", "2e882a394a365f57330bdab513fa94c85fd1e42f", "/system/lib/modules/nls_utf8.ko", "17ea0e0481f38c92a70cb689b649a2713657856b", "/system/lib/modules/tun.ko", "f9061377f411a776f07cf8862ff6232ece9d8a4d", "/system/lib/soundfx/libaudiopreprocessing.so", "6194b0963ad0bbdbd9e80d1b0dfb92dcaee39397", "/system/lib/soundfx/libbundlewrapper.so", "d317a4e49a851642f67e3b378ffbdf7c3c890a57", "/system/lib/soundfx/libcyanogen-dsp.so", "7845a741f8dbcf3e7800df191f0cf91bbabacbae", "/system/lib/soundfx/libreverbwrapper.so", "8f4ad44eec7c226eee3d451a026cc0a8c867e7ae", "/system/lib/soundfx/libvisualizer.so", "1b464cb186166b5a3b72834b8488fe52b509b0f7");
ui_print("");
set_progress(0.800000);
ui_print("-Setting Permissions...");
set_perm_recursive(0, 0, 0755, 0644, "/system");
set_perm_recursive(0, 2000, 0755, 0755, "/system/bin");
set_perm(0, 3003, 02750, "/system/bin/netcfg");
set_perm(0, 3004, 02755, "/system/bin/ping");
set_perm(0, 2000, 06750, "/system/bin/run-as");
set_perm_recursive(1002, 1002, 0755, 0440, "/system/etc/bluetooth");
set_perm(0, 0, 0755, "/system/etc/bluetooth");
set_perm(1000, 1000, 0640, "/system/etc/bluetooth/auto_pairing.conf");
set_perm(3002, 3002, 0444, "/system/etc/bluetooth/blacklist.conf");
set_perm(1002, 1002, 0440, "/system/etc/dbus.conf");
set_perm(1014, 2000, 0550, "/system/etc/dhcpcd/dhcpcd-run-hooks");
set_perm(0, 2000, 0550, "/system/etc/init.goldfish.sh");
set_perm_recursive(0, 0, 0755, 0555, "/system/etc/ppp");
set_perm(0, 2000, 0755, "/system/vendor");
set_perm_recursive(0, 2000, 0755, 0755, "/system/vendor/bin");
set_perm_recursive(0, 2000, 0755, 0644, "/system/vendor/etc");
set_perm(0, 0, 0644, "/system/vendor/etc/gps.xml");
set_perm(0, 2000, 0755, "/system/vendor/firmware");
set_perm(0, 2000, 0755, "/system/vendor/lib");
set_perm(0, 2000, 0755, "/system/vendor/lib/egl");
set_perm(0, 2000, 0755, "/system/vendor/lib/hw");
set_perm_recursive(0, 2000, 0755, 0644, "/system/vendor/pittpatt");
set_perm(0, 0, 0644, "/system/vendor/pittpatt/models/detection/multi_pose_face_landmark_detectors.3/left_eye-y0-yi45-p0-pi45-r0-ri20.2d_n2/full_model.bin");
set_perm(0, 0, 0644, "/system/vendor/pittpatt/models/detection/multi_pose_face_landmark_detectors.3/left_eye-y0-yi45-p0-pi45-rn7-ri20.2d_n2/full_model.bin");
set_perm(0, 0, 0644, "/system/vendor/pittpatt/models/detection/multi_pose_face_landmark_detectors.3/left_eye-y0-yi45-p0-pi45-rp7-ri20.2d_n2/full_model.bin");
set_perm(0, 0, 0644, "/system/vendor/pittpatt/models/detection/multi_pose_face_landmark_detectors.3/nose_base-y0-yi45-p0-pi45-r0-ri20.2d_n2/full_model.bin");
set_perm(0, 0, 0644, "/system/vendor/pittpatt/models/detection/multi_pose_face_landmark_detectors.3/nose_base-y0-yi45-p0-pi45-rn7-ri20.2d_n2/full_model.bin");
set_perm(0, 0, 0644, "/system/vendor/pittpatt/models/detection/multi_pose_face_landmark_detectors.3/nose_base-y0-yi45-p0-pi45-rp7-ri20.2d_n2/full_model.bin");
set_perm(0, 0, 0644, "/system/vendor/pittpatt/models/detection/multi_pose_face_landmark_detectors.3/right_eye-y0-yi45-p0-pi45-r0-ri20.2d_n2/full_model.bin");
set_perm(0, 0, 0644, "/system/vendor/pittpatt/models/detection/multi_pose_face_landmark_detectors.3/right_eye-y0-yi45-p0-pi45-rn7-ri20.2d_n2/full_model.bin");
set_perm(0, 0, 0644, "/system/vendor/pittpatt/models/detection/multi_pose_face_landmark_detectors.3/right_eye-y0-yi45-p0-pi45-rp7-ri20.2d_n2/full_model.bin");
set_perm(0, 0, 0644, "/system/vendor/pittpatt/models/detection/yaw_roll_face_detectors.3/head-y0-yi45-p0-pi45-r0-ri30.4a/full_model.bin");
set_perm(0, 0, 0644, "/system/vendor/pittpatt/models/detection/yaw_roll_face_detectors.3/head-y0-yi45-p0-pi45-rn30-ri30.5/full_model.bin");
set_perm(0, 0, 0644, "/system/vendor/pittpatt/models/detection/yaw_roll_face_detectors.3/head-y0-yi45-p0-pi45-rp30-ri30.5/full_model.bin");
set_perm(0, 0, 0644, "/system/vendor/pittpatt/models/recognition/face.face.y0-y0-22-b-N/full_model.bin");
set_perm_recursive(0, 2000, 0755, 0755, "/system/xbin");
set_perm_recursive(1002, 1002, 0755, 0440, "/system/etc/bluetooth");
set_perm(0, 0, 0755, "/system/etc/bluetooth");
set_perm(1000, 1000, 0640, "/system/etc/bluetooth/auto_pairing.conf");
set_perm(3002, 3002, 0444, "/system/etc/bluetooth/blacklist.conf");
set_perm(1002, 1002, 0440, "/system/etc/dbus.conf");
set_perm(1014, 2000, 0550, "/system/etc/dhcpcd/dhcpcd-run-hooks");
set_perm_recursive(0, 2000, 0755, 0750, "/system/etc/init.d");
set_perm(0, 0, 0755, "/system/etc/init.d");
set_perm(0, 0, 06755, "/system/xbin/librank");
set_perm(0, 0, 06755, "/system/xbin/procmem");
set_perm(0, 0, 06755, "/system/xbin/procrank");
set_perm(0, 0, 06755, "/system/bin/su");
set_perm(0, 0, 06755, "/system/xbin/tcpdump");
set_progress(0.800000);
ui_print("");
ui_print("Writing boot image...");
assert(run_program("/tmp/bml_over_mtd.sh", "boot", "72", "reservoir", "2004", "/tmp/boot.img"), delete("/tmp/boot.img"));
set_progress(0.900000);

ui_print("");
ui_print("-Done...");
set_progress(1.000000);
ui_print(" ");
ui_print(" ");
ui_print(" ");
ui_print(" ");
ui_print(" ");
ui_print(" ");
ui_print(" ");
ui_print(" ");
ui_print(" ");
ui_print(" ");
ui_print(" ");
ui_print(" ");
ui_print(" *********************************************** ");
ui_print(" *             Installation complete.          * ");
ui_print(" +---------------------------------------------+ ");
ui_print(" *********************************************** ");
unmount("/system");