1# 2# Copyright (C) 2022 The Android Open Source Project 3# 4# Licensed under the Apache License, Version 2.0 (the "License"); 5# you may not use this file except in compliance with the License. 6# You may obtain a copy of the License at 7# 8# http://www.apache.org/licenses/LICENSE-2.0 9# 10# Unless required by applicable law or agreed to in writing, software 11# distributed under the License is distributed on an "AS IS" BASIS, 12# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13# See the License for the specific language governing permissions and 14# limitations under the License. 15# 16 17$(call inherit-product, $(SRC_TARGET_DIR)/product/generic_ramdisk.mk) 18 19PRODUCT_COMPRESSED_APEX := false 20$(call inherit-product, $(SRC_TARGET_DIR)/product/updatable_apex.mk) 21 22$(call soong_config_append,cvd,launch_configs,cvd_config_minidroid.json) 23 24PRODUCT_SYSTEM_PROPERTIES += \ 25 service.adb.listen_addrs=vsock:5555 \ 26 27VENDOR_SECURITY_PATCH := $(PLATFORM_SECURITY_PATCH) 28BOOT_SECURITY_PATCH := $(PLATFORM_SECURITY_PATCH) 29PRODUCT_VENDOR_PROPERTIES += \ 30 ro.vendor.boot_security_patch=$(BOOT_SECURITY_PATCH) 31 32# Disable Treble and the VNDK 33PRODUCT_FULL_TREBLE_OVERRIDE := false 34PRODUCT_USE_VNDK_OVERRIDE := false 35PRODUCT_USE_PRODUCT_VNDK_OVERRIDE := false 36 37PRODUCT_SHIPPING_API_LEVEL := 33 38 39PRODUCT_USE_DYNAMIC_PARTITIONS := true 40 41PRODUCT_BUILD_VENDOR_IMAGE := true 42TARGET_COPY_OUT_VENDOR := vendor 43 44PRODUCT_BRAND := generic 45 46# Stolen from microdroid/Android.bp 47PRODUCT_PACKAGES += \ 48 init_second_stage \ 49 libbinder \ 50 libbinder_ndk \ 51 libstdc++ \ 52 secilc \ 53 libadbd_auth \ 54 libadbd_fs \ 55 heapprofd_client_api \ 56 libartpalette-system \ 57 apexd \ 58 atrace \ 59 debuggerd \ 60 linker \ 61 servicemanager \ 62 service \ 63 tombstoned \ 64 tombstone_transmit.microdroid \ 65 cgroups.json \ 66 task_profiles.json \ 67 public.libraries.android.txt \ 68 logcat \ 69 logd \ 70 71# Packages included only for eng or userdebug builds 72# su needed for logpersist.* commands 73PRODUCT_PACKAGES_DEBUG += \ 74 logpersist.start \ 75 su \ 76 77# Start logcatd by default and keep up to 30 rotated files around in userdebug/eng builds 78ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT))) 79PRODUCT_PROPERTY_OVERRIDES += \ 80 logd.logpersistd=logcatd \ 81 logd.logpersistd.size=30 82endif 83 84# Shell and utilities 85PRODUCT_PACKAGES += \ 86 reboot \ 87 sh \ 88 strace \ 89 toolbox \ 90 toybox \ 91 92# Test Binder RPC services 93PRODUCT_PACKAGES += \ 94 minidroid_sd \ 95 server_minidroid \ 96 client_minidroid \ 97 client_minidroid_rust \ 98 vsock-test 99 100# Additional packages 101PRODUCT_PACKAGES += \ 102 com.android.runtime \ 103 libc.bootstrap \ 104 libdl.bootstrap \ 105 libdl_android.bootstrap \ 106 libm.bootstrap \ 107 selinux_policy \ 108 com.android.adbd \ 109 mdnsd \ 110 111PRODUCT_COPY_FILES += \ 112 device/google/cuttlefish/shared/minidroid/fstab.minidroid:$(TARGET_COPY_OUT_VENDOR_RAMDISK)/first_stage_ramdisk/fstab.minidroid \ 113 device/google/cuttlefish/shared/minidroid/fstab.minidroid:$(TARGET_COPY_OUT_VENDOR)/etc/fstab.minidroid \ 114 115# FIXME: Hack to get some rootdirs created 116PRODUCT_PACKAGES += \ 117 init.environ.rc 118 119PRODUCT_COPY_FILES += \ 120 device/google/cuttlefish/shared/minidroid/init.rc:system/etc/init/hw/init.minidroid.rc \ 121 packages/modules/Virtualization/microdroid/ueventd.rc:vendor/etc/ueventd.rc \ 122 device/google/cuttlefish/shared/config/seriallogging.rc:vendor/etc/init/seriallogging.rc \ 123 124DEVICE_MANIFEST_FILE := \ 125 device/google/cuttlefish/shared/minidroid/minidroid_vendor_manifest.xml 126PRODUCT_PACKAGES += vendor_compatibility_matrix.xml 127 128TARGET_BOARD_INFO_FILE ?= device/google/cuttlefish/shared/minidroid/android-info.txt 129