• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
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
32PRODUCT_SHIPPING_API_LEVEL := 33
33
34PRODUCT_USE_DYNAMIC_PARTITIONS := true
35
36PRODUCT_BUILD_VENDOR_IMAGE := true
37TARGET_COPY_OUT_VENDOR := vendor
38
39PRODUCT_BRAND := generic
40
41# Stolen from microdroid/Android.bp
42PRODUCT_PACKAGES += \
43    init_second_stage \
44    libbinder \
45    libbinder_ndk \
46    libstdc++ \
47    secilc \
48    libadbd_auth \
49    libadbd_fs \
50    heapprofd_client_api \
51    libartpalette-system \
52    apexd \
53    atrace \
54    debuggerd \
55    linker \
56    servicemanager \
57    service \
58    tombstoned \
59    tombstone_transmit.microdroid \
60    cgroups.json \
61    task_profiles.json \
62    public.libraries.android.txt \
63    logcat \
64    logd \
65
66# Packages included only for eng or userdebug builds
67# su needed for logpersist.* commands
68PRODUCT_PACKAGES_DEBUG += \
69    logpersist.start \
70    su \
71
72# Start logcatd by default and keep up to 30 rotated files around in userdebug/eng builds
73ifneq (,$(filter userdebug eng, $(TARGET_BUILD_VARIANT)))
74PRODUCT_PROPERTY_OVERRIDES += \
75  logd.logpersistd=logcatd \
76  logd.logpersistd.size=30
77endif
78
79# Shell and utilities
80PRODUCT_PACKAGES += \
81    reboot \
82    sh \
83    strace \
84    toolbox \
85    toybox \
86
87# Test Binder RPC services
88PRODUCT_PACKAGES += \
89    minidroid_sd \
90    server_minidroid \
91    client_minidroid \
92    client_minidroid_rust \
93    vsock-test
94
95# Additional packages
96PRODUCT_PACKAGES += \
97    com.android.runtime \
98    libc.bootstrap \
99    libdl.bootstrap \
100    libdl_android.bootstrap \
101    libm.bootstrap \
102    selinux_policy \
103    com.android.adbd \
104    mdnsd \
105
106PRODUCT_COPY_FILES += \
107    device/google/cuttlefish/shared/minidroid/fstab.minidroid:$(TARGET_COPY_OUT_VENDOR_RAMDISK)/first_stage_ramdisk/fstab.minidroid \
108    device/google/cuttlefish/shared/minidroid/fstab.minidroid:$(TARGET_COPY_OUT_VENDOR)/etc/fstab.minidroid \
109
110# FIXME: Hack to get some rootdirs created
111PRODUCT_PACKAGES += \
112    init.environ.rc
113
114PRODUCT_COPY_FILES += \
115    device/google/cuttlefish/shared/minidroid/init.rc:system/etc/init/hw/init.minidroid.rc \
116    packages/modules/Virtualization/build/microdroid/ueventd.rc:vendor/etc/ueventd.rc \
117    device/google/cuttlefish/shared/config/seriallogging.rc:vendor/etc/init/seriallogging.rc \
118
119DEVICE_MANIFEST_FILE := \
120    device/google/cuttlefish/shared/minidroid/minidroid_vendor_manifest.xml
121PRODUCT_PACKAGES += \
122    vendor_compatibility_matrix.xml \
123    vendor_manifest.xml \
124
125TARGET_BOARD_INFO_FILE ?= device/google/cuttlefish/shared/minidroid/android-info.txt
126