Skip to content

Commit

Permalink
Workaround the fake-package symlink issue faced on Q
Browse files Browse the repository at this point in the history
* For some reason, the fake packages generating the standalone
  symlinks were never called. They're present in PRODUCT_PACKAGES
  yet building any of the normal targets
  (m or m vendorimage or m $OUT/vendor.img)
  did not build them. Building them manually worked, and so did
  (mmm vendor/google_devices/$device)
* Switch to REQUIRED_MODULES instead, as that does work.
* We copy the file_signatures.txt file right now, but it can be any
  other file too.

Signed-off-by: spezi77 <[email protected]>
  • Loading branch information
chirayudesai authored and spezi77 committed Sep 18, 2019
1 parent cf00bf4 commit a5e28e5
Showing 1 changed file with 16 additions and 2 deletions.
18 changes: 16 additions & 2 deletions scripts/generate-vendor.sh
Original file line number Diff line number Diff line change
Expand Up @@ -587,12 +587,26 @@ gen_standalone_symlinks() {

if [ ! -z "${pkgs_SSLinks-}" ]; then
{
echo "# Standalone symbolic links"
echo 'PRODUCT_PACKAGES += \'
echo -e "\ninclude \$(CLEAR_VARS)"
echo 'LOCAL_MODULE := apv_file_signatures'
echo 'LOCAL_MODULE_CLASS := ETC'
echo 'LOCAL_MODULE_TAGS := optional'
echo -e "LOCAL_MODULE_OWNER := $VENDOR"
echo 'LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_ETC)'
echo 'LOCAL_MODULE_STEM := file_signatures.txt'
echo 'LOCAL_SRC_FILES := file_signatures.txt'
echo 'LOCAL_REQUIRED_MODULES := \'
for module in "${pkgs_SSLinks[@]}"
do
echo " $module \\"
done
} >> "$ANDROID_MK"
strip_trail_slash_from_file "$ANDROID_MK"
echo 'include $(BUILD_PREBUILT)' >> "$ANDROID_MK"
{
echo "# Standalone symbolic links"
echo 'PRODUCT_PACKAGES += \'
echo -e " apv_file_signatures\n"
} >> "$DEVICE_VENDOR_MK"
fi
strip_trail_slash_from_file "$DEVICE_VENDOR_MK"
Expand Down

0 comments on commit a5e28e5

Please sign in to comment.