Quote pattern in 'find' command used to generate modules.load
When a kernel module archive is specified via BOARD_*_KERNEL_MODULES_ARCHIVE an unquoted wildcard pattern in the 'find' command used to find modules to add to modules.load can result in a build failure due to shell expansion. Fix this by quoting the pattern so that kernel modules in $ANDROID_BUILD_TOP don't cause unexpected build failures. Bug: 289887845 Test: Define BOARD_VENDOR_KERNEL_MODULES_ARCHIVE for aosp_cf_x86_64_phone, touch foo.ko && lunch aosp_cf_x86_64_phone-userdebug && m succeeds. Change-Id: I8122afc6bbbb5df6e3b11922b2be38129addeda0 Signed-off-by: Rashid Zaman <rashidz@meta.com>
This commit is contained in:
@@ -412,7 +412,7 @@ $(3)/$(DEPMOD_STAGING_SUBDIR)/modules.dep: $(1) $(6)
|
||||
unzip -qoDD -d $$(PRIVATE_MODULE_DIR) $$(PRIVATE_MODULE_ARCHIVE); \
|
||||
mkdir -p $$(PRIVATE_OUTPUT_DIR)/lib; \
|
||||
cp -r $(3)/$(DEPMOD_STAGING_SUBDIR)/$(2)/lib/modules $$(PRIVATE_OUTPUT_DIR)/lib/; \
|
||||
find $$(PRIVATE_MODULE_DIR) -type f -name *.ko | xargs basename -a > $$(PRIVATE_LOAD_FILE); \
|
||||
find $$(PRIVATE_MODULE_DIR) -type f -name '*.ko' | xargs basename -a > $$(PRIVATE_LOAD_FILE); \
|
||||
)
|
||||
$(if $(1),\
|
||||
cp $$(PRIVATE_MODULES) $$(PRIVATE_MODULE_DIR)/; \
|
||||
|
Reference in New Issue
Block a user