Resolve symlinks when checking class loader context.
There is some inconsistency in the build system. When /system_ext is
a symlink to /system/system_ext and there is a shared library in
/system_ext, the oat file generated by dexpreopt has the dex location
starting with /system/system_ext, while the metadata in
/system_ext/etc/permissions has the dex location starting with
/system_ext. This inconsitency causes the class loader context to fail.
This CL works around the inconsistency by resolving symlinks when
checking class loader context.
Bug: 247914536
Test: m test-art-host-gtest-art_runtime_tests
Change-Id: I7a177bda08e179c3d5417108be6411a84fdd5c40
(cherry picked from commit 742160318a3de2c10622b97dfe37473ef2b1985b)
Merged-In: I7a177bda08e179c3d5417108be6411a84fdd5c40
3 files changed