简体   繁体   中英

How to uninstall ANDROID CAR EMULATOR Default app

I'm trying to uninstall default android car emulator app like Music,Radio,clock and calendar.i'm able to build and lunch the ANDROID CAR EMULATOR.(reference- http://www.embien.com/blog/building-android-car-emulator/ )

my question is how to uninstall above mention default app form the android car emulator.

I see the car emulator is built as a regular target, so the same rules should apply.

If you need to remove a system app from a target, you need to remove its package name from .mk files, which are sort of make files for AOSP. For example https://android.googlesource.com/device/generic/car/+/refs/tags/android-8.1.0_r65 which adds combos aosp_car_emu_x86-userdebug etc (see vendorsetup.sh there)

aosp_car_x86.mk includes other files:

$(call inherit-product, device/generic/car/common/car.mk)
$(call inherit-product, $(SRC_TARGET_DIR)/product/aosp_x86.mk)

common/car.mk is the main file adding/enabling car-specific things. Most likely the apps are specified in PRODUCT_PACKAGES , not in car.mk but in some other .mk files included via product/aosp_x86.mk - many levels of inclusions there, prepare to be patient.

As far as I know, there is no special feature in AOSP to exclude packages (only to include. there's a feature (I do not remember exactly) to specify in a module that it overrides some other modules (that you want to remove), but generally it may cause some other conflicts).

So you need to find package name to which the app belongs too, and remove it from .mk files (or use some bare/minimalistic target with inclusion of your own apps). Use mgrep command to find where a package is included.

To find package name of an app, you need to find its .mk file, and it is not easy too. resgrep or mangrep may help. See https://elinux.org/Android_Build_System

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM