最終更新:2016-01-04 (月) 18:28:17 (3028d)  

SuperSU 2.56
Top / SuperSU 2.56

Ramdisk modifications

  • - include (post above this one)
    - init.rc (devs: please open file for reference)
    --- on init
    ------ mkdir /su ...
    --- on post-fs-data
    ------ copy image from cache to data (for rooting without access to /data in custom recovery)
    ------ mount image to /su
    --- service daemonsu
    - init.environ.rc
    --- export PATH, prepended with /su/bin
    - file_contexts
    --- /su(/.*)? ubject_r:system_file:s0

ramdiskの変更点

Android/file_contexts?

  • # SuperSU 
    /su(/.*)? u:object_r:system_file:s0 

Android/init.environ.rc?

  • export PATH /su/bin:/sbin:/vendor/bin:/system/sbin:/system/bin:/system/xbin

Android/init.rc

  • on init
        mkdir /su 0755 root root # create mount point for SuperSU
    
    on post-fs-data
        # mount SuperSU image
        cp /cache/su.img /data/su.img
        rm /cache/su.img
        chmod 0600 /data/su.img
        mount ext4 loop@/data/su.img /su noatime
    
    service daemonsu /su/bin/daemonsu --auto-daemon 
        class late_start 
        user root 
        oneshot