Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 56bee1f7 authored by Jooyung Han's avatar Jooyung Han
Browse files

Skip system/bin/bootstrap/linkerconfig

Early processes can't rely on APEXes anyway. We don't need to run
linkerconfig.

This helps to reduce the storage usage (no
/system/bin/bootstrap/linkerconfig) and the boottime (not running
linkerconfig).

If we need more complicated linker config even for early processes, then
we could generate it at build-time and use it like recovery version.

Bug: 262330207
Bug: 260982509
Test: MicrodroidAppTest
Test: device boots
Change-Id: Iceca5ffdb1655fd94e90b0091f439bd22130185e
parent 95cfb31b
Loading
Loading
Loading
Loading
+4 −3
Original line number Original line Diff line number Diff line
@@ -55,10 +55,11 @@ on early-init
    # Read more in b/136247322
    # Read more in b/136247322
    write /sys/module/dm_verity/parameters/prefetch_cluster 0
    write /sys/module/dm_verity/parameters/prefetch_cluster 0


    # Generate ld.config.txt for early executed processes
    # Generate empty ld.config.txt for early executed processes which rely on
    exec -- /system/bin/bootstrap/linkerconfig --target /linkerconfig/bootstrap
    # /system/lib libraries.
    write /linkerconfig/bootstrap/ld.config.txt \#
    write /linkerconfig/default/ld.config.txt \#
    chmod 644 /linkerconfig/bootstrap/ld.config.txt
    chmod 644 /linkerconfig/bootstrap/ld.config.txt
    copy /linkerconfig/bootstrap/ld.config.txt /linkerconfig/default/ld.config.txt
    chmod 644 /linkerconfig/default/ld.config.txt
    chmod 644 /linkerconfig/default/ld.config.txt


    # Mount bootstrap linker configuration as current
    # Mount bootstrap linker configuration as current