Our chipset vendor gives a drop of the Android platform with hundreds of useless modules. Some are included using LOCAL_MODULE_TAGS := optional debug
but I don't want this module to show up in any build at all. Some are included by doing PRODUCT_PACKAGES += junk-app
. I could go through all the Android.mk files one at a time cleaning this stuff up but that is tiresome and problematic for merging if the vendor gives us a new drop.
I can use LOCAL_OVERRIDES_PACKAGES
to get rid of the PRODUCT_PACKAGES
but that doesn't work on shared libraries saved to /system/vendor/bin
or prebuilt files that are copied in /system/etc/
.
The ones with LOCAL_MODULE_TAGS
set to values that include eng
or debug
are the most annoying.
So there doesn't seem to be any silver bullet, here was my strategy:
debug
and eng
tags from the LOCAL_MODULE_TAGS
in a bunch of makefiles (tedious but no other obvious choice)ifneq ($(TARGET_VENDOR), mycompany)
to get rid of things added to PRODUCT_PACKAGES