Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ui_print("");
- ui_print("--- Prerooted system installer ---");
- show_progress(0.7, 75);
- ui_print("");
- ui_print("--- Install image files ---");
- # rhine
- package_extract_file("kernel.elf", "/dev/block/platform/msm_sdcc.1/by-name/boot");
- package_extract_file("system.ext4", "/dev/block/platform/msm_sdcc.1/by-name/system");
- # blue
- #package_extract_file("kernel.elf", "/dev/block/platform/msm_sdcc.1/by-name/Kernel");
- #package_extract_file("system.ext4", "/dev/block/platform/msm_sdcc.1/by-name/System");
- # fuji
- #package_extract_file("kernel.elf", "/dev/block/mmcblk0p3");
- #package_extract_file("system.ext4", "/dev/block/mmcblk0p12");
- show_progress(0.3, 5);
- ui_print("");
- ui_print("--- Installing root files ---");
- run_program("/sbin/busybox", "mount", "/system");
- run_program("/sbin/busybox", "mount", "/data");
- delete_recursive("/data/dalvik-cache");
- # From UPDATE-SuperSU-v1.94
- #package_extract_file("Superuser.apk", "/system/app/Superuser.apk");
- #set_perm(0, 0, 0644, "/system/app/Superuser.apk");
- #run_program("/sbin/busybox", "mkdir", "/system/bin/.ext");
- #package_extrct_file(".su", "/system/bin/.ext/.su");
- #set_perm_recursive(0, 0, 0777, 06755, "/system/bin/.ext");
- #package_extract_file("daemonsu", "/system/xbin/daemonsu");
- #set_perm(0, 0, 0755, "/system/xbin/daemonsu");
- #package_extract_file("su", "/system/xbin/su");
- #set_perm(0, 0, 06755, "/system/xbin/su");
- #package_extract_file("busybox", "/system/xbin/busybox");
- #set_perm(0, 2000, 04755, "/system/xbin/busybox");
- #run_program("/system/xbin/busybox", "--install", "-s", "/system/xbin");
- #package_extract_file("installbusybox", "/tmp/installbusybox");
- #set_perm(0, 0, 0777, "/tmp/installbusybox");
- #run_program("/tmp/installbusybox");
- #package_extract_file("sqlite3", "/system/xbin/sqlite3");
- #set_perm(0, 2000, 04755, "/system/xbin/sqlite3");
- #package_extract_file("zipalign", "/system/xbin/zipalign");
- #set_perm(0, 2000, 04755, "/system/xbin/zipalign");
- #run_program("/sbin/busybox", "mkdir", "/system/etc/init.d");
- #package_extract_file("00stop_ric", "/system/etc/init.d/00stop_ric");
- #package_extract_file("97sqlite", "/system/etc/init.d/97sqlite");
- #package_extract_file("98zipalign", "/system/etc/init.d/98zipalign");
- #package_extract_file("99SuperSUDaemon", "/system/etc/init.d/99SuperSUDaemon");
- #set_perm_recursive(0, 0, 0755, 0755, "/system/etc/init.d");
- #package_extract_file("echo_runparts.sh", "/tmp/echo_rauparts.sh");
- #set_perm(0, 0, 0777, "/tmp/echo_runparts.sh");
- #run_program("/tmp/echo_runparts.sh");
- package_extract_dir("system", "/system");
- ui_print("");
- ui_print("--- Settings owner and permissions ---");
- set_perm(0, 0, 0644, "/system/app/Superuser.apk");
- set_perm_recursive(0, 0, 0777, 06755, "/system/bin/.ext");
- set_perm_recursive(0, 0, 0755, 0755, "/system/etc/init.d");
- set_perm(0, 2000, 04755, "/system/xbin/busybox");
- set_perm(0, 0, 0755, "/system/xbin/daemonsu");
- set_perm(0, 2000, 04755, "/system/xbin/sqlite3");
- set_perm(0, 0, 06755, "/system/xbin/su");
- set_perm(0, 2000, 04755, "/system/xbin/zipalign");
- ui_print("");
- ui_print("--- Install busybox 1.21.1 ---");
- # From FlashTool 0.9.15.0
- run_program("/system/xbin/busybox", "--install", "-s", "/system/xbin");
- package_extract_file("installbusybox", "/tmp/installbusybox");
- set_perm(0, 0, 0777, "/tmp/installbusybox");
- run_program("/tmp/installbusybox");
- ui_print("");
- ui_print("--- Enable init.d ---");
- package_extract_file("echo_runparts.sh", "/tmp/echo_rauparts.sh");
- set_perm(0, 0, 0777, "/tmp/echo_runparts.sh");
- run_program("/tmp/echo_runparts.sh");
- unmount("/system");
- unmount("/data");
- ui_print("");
- ui_print("--- Finish ---");
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement