From e306bce92756d5b0c83033359352eb476643d9ff Mon Sep 17 00:00:00 2001 From: Yifan Hong Date: Wed, 15 Jul 2020 17:08:59 -0700 Subject: [PATCH] rootdir: add odm_dlkm symlinks Test: builds and boots Bug: 156020364 Change-Id: I678b787cbf81ea6038936a4059e0bf5adfe3274f --- rootdir/Android.mk | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/rootdir/Android.mk b/rootdir/Android.mk index ac8e8478a..77fa94e73 100644 --- a/rootdir/Android.mk +++ b/rootdir/Android.mk @@ -131,6 +131,16 @@ LOCAL_POST_INSTALL_CMD += ; mkdir -p $(TARGET_ROOT_OUT)/vendor_dlkm # via /vendor/lib/modules directly. LOCAL_POST_INSTALL_CMD += ; ln -sf /vendor/vendor_dlkm/etc $(TARGET_ROOT_OUT)/vendor_dlkm/etc +# For /odm_dlkm partition. +LOCAL_POST_INSTALL_CMD += ; mkdir -p $(TARGET_ROOT_OUT)/odm_dlkm +# For Treble Generic System Image (GSI), system-as-root GSI needs to work on +# both devices with and without /odm_dlkm partition. Those symlinks are for +# devices without /odm_dlkm partition. For devices with /odm_dlkm +# partition, mount odm_dlkm.img under /odm_dlkm will hide those symlinks. +# Note that /odm_dlkm/lib is omitted because odm DLKMs should be accessed +# via /odm/lib/modules directly. +LOCAL_POST_INSTALL_CMD += ; ln -sf /odm/odm_dlkm/etc $(TARGET_ROOT_OUT)/odm_dlkm/etc + ifdef BOARD_CACHEIMAGE_FILE_SYSTEM_TYPE LOCAL_POST_INSTALL_CMD += ; mkdir -p $(TARGET_ROOT_OUT)/cache else