简体   繁体   English

如何卸载ANDROID CAR EMULATOR默认应用

[英]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/ ) 我正在尝试卸载默认的Android汽车模拟器应用程序,例如Music,Radio,clock和calendar.i能够构建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. 我的问题是如何从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. 如果需要从目标中删除系统应用程序,则需要从.mk文件中删除其程序包名称, .mk文件是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) 例如https://android.googlesource.com/device/generic/car/+/refs/tags/android-8.1.0_r65 ,其中添加了组合aosp_car_emu_x86-userdebug等(请参见vendorsetup.sh

aosp_car_x86.mk includes other files: aosp_car_x86.mk包括其他文件:

$(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. common/car.mk是添加/启用汽车特定内容的主文件。 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. 应用很可能是在PRODUCT_PACKAGES中指定的,而不是在car.mk中指定的,而是在product/aosp_x86.mk包含的其他一些.mk文件中product/aosp_x86.mk -在其中包含许多级别的内容,请耐心等待。

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). 据我所知,AOSP中没有排除包的特殊功能(仅包括在内)。有一个功能(我不记得确切)可以在模块中指定它覆盖某些其他模块(您要删除),但通常可能会导致其他一些冲突)。

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). 因此,您还需要找到该应用程序所属的程序包名称,并将其从.mk文件中删除(或使用一些裸露/简约的目标(包括自己的应用程序))。 Use mgrep command to find where a package is included. 使用mgrep命令查找包含软件包的位置。

To find package name of an app, you need to find its .mk file, and it is not easy too. 要查找应用程序的程序包名称,您需要找到其.mk文件,这也不容易。 resgrep or mangrep may help. resgrepmangrep可能会有所帮助。 See https://elinux.org/Android_Build_System 参见https://elinux.org/Android_Build_System

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

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