• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1#
2# Copyright (C) 2018 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# This file is to configure vendor/data partitions of emulator-related products
18#
19$(call inherit-product-if-exists, frameworks/native/build/phone-xhdpi-2048-dalvik-heap.mk)
20
21# Enable Scoped Storage related
22$(call inherit-product, $(SRC_TARGET_DIR)/product/emulated_storage.mk)
23
24PRODUCT_SOONG_NAMESPACES += \
25    device/generic/goldfish \
26    device/generic/goldfish-opengl
27
28PRODUCT_SYSTEM_EXT_PROPERTIES += ro.lockscreen.disable.default=1
29
30DISABLE_RILD_OEM_HOOK := true
31
32DEVICE_MANIFEST_FILE += device/generic/goldfish/64bitonly/manifest.xml
33
34ifneq ($(EMULATOR_DISABLE_RADIO),true)
35DEVICE_MANIFEST_FILE += device/generic/goldfish/64bitonly/manifest.radio.xml
36endif
37
38PRODUCT_SOONG_NAMESPACES += hardware/google/camera
39PRODUCT_SOONG_NAMESPACES += hardware/google/camera/devices/EmulatedCamera
40
41# Device modules
42PRODUCT_PACKAGES += \
43    vulkan.ranchu \
44    libandroidemu \
45    libOpenglCodecCommon \
46    libOpenglSystemCommon \
47    libcuttlefish-ril-2 \
48    libgoldfish-rild \
49    qemu-adb-keys \
50    qemu-device-state \
51    qemu-props \
52    stagefright \
53    android.hardware.graphics.composer@2.4-service \
54    android.hardware.graphics.allocator@3.0-service \
55    android.hardware.graphics.mapper@3.0-impl-ranchu \
56    hwcomposer.ranchu \
57    toybox_vendor \
58    android.hardware.wifi@1.0-service \
59    android.hardware.media.c2@1.0-service-goldfish \
60    libcodec2_goldfish_vp8dec \
61    libcodec2_goldfish_vp9dec \
62    libcodec2_goldfish_avcdec \
63    libcodec2_goldfish_hevcdec \
64    sh_vendor \
65    local_time.default \
66    SdkSetup \
67    EmulatorRadioConfig \
68    goldfish_overlay_connectivity_gsi \
69    EmulatorTetheringConfigOverlay \
70    MultiDisplayProvider \
71    libGoldfishProfiler \
72    dlkm_loader
73
74ifneq ($(EMULATOR_VENDOR_NO_FINGERPRINT), true)
75    PRODUCT_PACKAGES += \
76        fingerprint.ranchu \
77        android.hardware.biometrics.fingerprint@2.1-service
78endif
79
80ifneq ($(BUILD_EMULATOR_OPENGL),false)
81PRODUCT_PACKAGES += \
82    libGLESv1_CM_emulation \
83    lib_renderControl_enc \
84    libEGL_emulation \
85    libGLESv2_enc \
86    libvulkan_enc \
87    libGLESv2_emulation \
88    libGLESv1_enc \
89    libEGL_angle \
90    libGLESv1_CM_angle \
91    libGLESv2_angle
92endif
93
94#
95# Enable bluetooth
96PRODUCT_PACKAGES += \
97    bt_vhci_forwarder \
98    android.hardware.bluetooth@1.1-service.btlinux \
99    android.hardware.bluetooth.audio@2.1-impl
100
101# Bluetooth hardware properties.
102ifeq ($(TARGET_PRODUCT_PROP),)
103TARGET_PRODUCT_PROP := $(LOCAL_PATH)/../../bluetooth.prop
104endif
105
106# Bluetooth se policies
107BOARD_SEPOLICY_DIRS += system/bt/vendor_libs/linux/sepolicy
108
109PRODUCT_PACKAGES += \
110    android.hardware.health@2.1-service \
111    android.hardware.health@2.1-impl \
112    android.hardware.health.storage@1.0-service \
113
114PRODUCT_PACKAGES += \
115    android.hardware.neuralnetworks@1.3-service-sample-all \
116    android.hardware.neuralnetworks@1.3-service-sample-limited
117
118PRODUCT_PACKAGES += \
119    android.hardware.security.keymint-service
120PRODUCT_COPY_FILES += \
121    frameworks/native/data/etc/android.hardware.keystore.app_attest_key.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.keystore.app_attest_key.xml
122
123PRODUCT_PACKAGES += \
124    DisplayCutoutEmulationEmu01Overlay \
125    EmulationPixel5Overlay \
126    SystemUIEmulationPixel5Overlay \
127    EmulationPixel4XLOverlay 4\
128    SystemUIEmulationPixel4XLOverlay \
129    EmulationPixel4Overlay \
130    SystemUIEmulationPixel4Overlay \
131    EmulationPixel4aOverlay \
132    SystemUIEmulationPixel4aOverlay \
133    EmulationPixel3XLOverlay \
134    SystemUIEmulationPixel3XLOverlay \
135    EmulationPixel3Overlay \
136    SystemUIEmulationPixel3Overlay \
137    EmulationPixel3aOverlay \
138    SystemUIEmulationPixel3aOverlay \
139    EmulationPixel3aXLOverlay \
140    SystemUIEmulationPixel3aXLOverlay \
141    EmulationPixel2XLOverlay \
142    NavigationBarMode2ButtonOverlay \
143
144ifneq ($(EMULATOR_VENDOR_NO_GNSS),true)
145#disable the following as it does not support gnss yet
146#PRODUCT_PACKAGES += android.hardware.gnss-service.example
147PRODUCT_PACKAGES += android.hardware.gnss@2.0-service.ranchu
148endif
149
150ifneq ($(EMULATOR_VENDOR_NO_SENSORS),true)
151PRODUCT_PACKAGES += \
152    android.hardware.sensors@2.1-service.multihal \
153    android.hardware.sensors@2.1-impl.ranchu
154# TODO(rkir):
155# add a soong namespace and move this into a.h.sensors@2.1-impl.ranchu
156# as prebuilt_etc. For now soong_namespace causes a build break because the fw
157# refers to our wifi HAL in random places.
158PRODUCT_COPY_FILES += \
159    device/generic/goldfish/sensors/hals.conf:$(TARGET_COPY_OUT_VENDOR)/etc/sensors/hals.conf
160endif
161
162PRODUCT_PACKAGES += \
163    android.hardware.drm@1.0-service \
164    android.hardware.drm@1.0-impl \
165    android.hardware.drm@1.4-service.clearkey \
166
167PRODUCT_PACKAGES += \
168    android.hardware.power-service.example \
169
170PRODUCT_PROPERTY_OVERRIDES += ro.control_privapp_permissions=enforce
171PRODUCT_PROPERTY_OVERRIDES += ro.hardware.power=ranchu
172PRODUCT_PROPERTY_OVERRIDES += ro.crypto.volume.filenames_mode=aes-256-cts
173PRODUCT_VENDOR_PROPERTIES += graphics.gpu.profiler.support=true
174
175PRODUCT_PROPERTY_OVERRIDES += persist.sys.zram_enabled=1 \
176
177PRODUCT_PACKAGES += \
178    android.hardware.dumpstate@1.1-service.example \
179
180# Prevent logcat from getting canceled early on in boot
181PRODUCT_PROPERTY_OVERRIDES += ro.logd.size=1M \
182
183ifneq ($(EMULATOR_VENDOR_NO_CAMERA),true)
184PRODUCT_PACKAGES += \
185    android.hardware.camera.provider@2.4-service_64 \
186    android.hardware.camera.provider@2.4-impl \
187    camera.ranchu \
188    camera.ranchu.jpeg \
189    android.hardware.camera.provider@2.7-service-google \
190    libgooglecamerahwl_impl \
191    android.hardware.camera.provider@2.7-impl-google
192endif
193
194ifneq ($(EMULATOR_VENDOR_NO_SOUND),true)
195PRODUCT_PACKAGES += \
196    android.hardware.audio.service \
197    android.hardware.audio@7.1-impl.ranchu \
198    android.hardware.soundtrigger@2.2-impl.ranchu \
199    android.hardware.audio.effect@7.0-impl \
200
201DEVICE_MANIFEST_FILE += device/generic/goldfish/audio/android.hardware.audio.effects@7.0.xml
202
203PRODUCT_COPY_FILES += \
204    device/generic/goldfish/audio/policy/audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio_policy_configuration.xml \
205    device/generic/goldfish/audio/policy/primary_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/primary_audio_policy_configuration.xml \
206    frameworks/av/services/audiopolicy/config/a2dp_in_audio_policy_configuration_7_0.xml:$(TARGET_COPY_OUT_VENDOR)/etc/a2dp_in_audio_policy_configuration_7_0.xml \
207    frameworks/av/services/audiopolicy/config/bluetooth_audio_policy_configuration_7_0.xml:$(TARGET_COPY_OUT_VENDOR)/etc/bluetooth_audio_policy_configuration_7_0.xml \
208    frameworks/av/services/audiopolicy/config/r_submix_audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/r_submix_audio_policy_configuration.xml \
209    frameworks/av/services/audiopolicy/config/audio_policy_volumes.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio_policy_volumes.xml \
210    frameworks/av/services/audiopolicy/config/default_volume_tables.xml:$(TARGET_COPY_OUT_VENDOR)/etc/default_volume_tables.xml \
211    frameworks/av/media/libeffects/data/audio_effects.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio_effects.xml \
212
213endif
214
215PRODUCT_PACKAGES += \
216    android.hardware.gatekeeper@1.0-service.software
217
218# WiFi: vendor side
219PRODUCT_PACKAGES += \
220	mac80211_create_radios \
221	dhcpclient \
222	hostapd \
223	wpa_supplicant \
224
225PRODUCT_PACKAGES += \
226    android.hardware.usb@1.0-service
227
228# Thermal
229PRODUCT_PACKAGES += \
230	android.hardware.thermal@2.0-service.mock
231
232# Atrace
233PRODUCT_PACKAGES += \
234	android.hardware.atrace@1.0-service
235
236# Vibrator
237PRODUCT_PACKAGES += \
238	android.hardware.vibrator-service.example
239
240# Authsecret
241PRODUCT_PACKAGES += \
242    android.hardware.authsecret@1.0-service
243
244# Identity
245PRODUCT_PACKAGES += \
246    android.hardware.identity-service.example
247
248# lights
249PRODUCT_PACKAGES += \
250    android.hardware.lights-service.example
251
252# power stats
253PRODUCT_PACKAGES += \
254    android.hardware.power.stats@1.0-service.mock
255
256# Reboot escrow
257PRODUCT_PACKAGES += \
258    android.hardware.rebootescrow-service.default
259
260# Extension implementation for Jetpack WindowManager
261PRODUCT_PACKAGES += \
262    androidx.window.extensions \
263    androidx.window.sidecar \
264
265PRODUCT_PACKAGES += \
266    android.hardware.biometrics.face@1.0-service.example
267
268PRODUCT_PACKAGES += \
269    android.hardware.contexthub@1.1-service.mock
270
271
272PRODUCT_PROPERTY_OVERRIDES += \
273    debug.stagefright.c2inputsurface=-1 \
274    debug.stagefright.ccodec=4
275
276# Enable Incremental on the device via kernel driver
277PRODUCT_PROPERTY_OVERRIDES += ro.incremental.enable=yes
278
279
280PRODUCT_COPY_FILES += \
281    device/generic/goldfish/data/etc/dtb.img:dtb.img \
282    device/generic/goldfish/emulator-info.txt:data/misc/emulator/version.txt \
283    device/generic/goldfish/data/etc/apns-conf.xml:data/misc/apns/apns-conf.xml \
284    device/generic/goldfish/radio/RadioConfig/radioconfig.xml:data/misc/emulator/config/radioconfig.xml \
285    device/generic/goldfish/data/etc/iccprofile_for_sim0.xml:data/misc/modem_simulator/iccprofile_for_sim0.xml \
286    device/google/cuttlefish/host/commands/modem_simulator/files/iccprofile_for_sim0_for_CtsCarrierApiTestCases.xml:data/misc/modem_simulator/iccprofile_for_carrierapitests.xml \
287    device/generic/goldfish/data/etc/numeric_operator.xml:data/misc/modem_simulator/etc/modem_simulator/files/numeric_operator.xml \
288    device/generic/goldfish/data/etc/local.prop:data/local.prop \
289    device/generic/goldfish/init.qemu-adb-keys.sh:$(TARGET_COPY_OUT_SYSTEM_EXT)/bin/init.qemu-adb-keys.sh \
290    device/generic/goldfish/init.ranchu-core.sh:$(TARGET_COPY_OUT_VENDOR)/bin/init.ranchu-core.sh \
291    device/generic/goldfish/init.ranchu-net.sh:$(TARGET_COPY_OUT_VENDOR)/bin/init.ranchu-net.sh \
292    device/generic/goldfish/init.ranchu.rc:$(TARGET_COPY_OUT_VENDOR)/etc/init/hw/init.ranchu.rc \
293    device/generic/goldfish/init.system_ext.rc:$(TARGET_COPY_OUT_SYSTEM_EXT)/etc/init/init.system_ext.rc \
294    device/generic/goldfish/ueventd.ranchu.rc:$(TARGET_COPY_OUT_VENDOR)/etc/ueventd.rc \
295    device/generic/goldfish/input/virtio_input_rotary.idc:$(TARGET_COPY_OUT_VENDOR)/usr/idc/virtio_input_rotary.idc \
296    device/generic/goldfish/input/qwerty2.idc:$(TARGET_COPY_OUT_VENDOR)/usr/idc/qwerty2.idc \
297    device/generic/goldfish/input/qwerty.kl:$(TARGET_COPY_OUT_VENDOR)/usr/keylayout/qwerty.kl \
298    device/generic/goldfish/input/virtio_input_multi_touch_1.idc:$(TARGET_COPY_OUT_VENDOR)/usr/idc/virtio_input_multi_touch_1.idc \
299    device/generic/goldfish/input/virtio_input_multi_touch_2.idc:$(TARGET_COPY_OUT_VENDOR)/usr/idc/virtio_input_multi_touch_2.idc \
300    device/generic/goldfish/input/virtio_input_multi_touch_3.idc:$(TARGET_COPY_OUT_VENDOR)/usr/idc/virtio_input_multi_touch_3.idc \
301    device/generic/goldfish/input/virtio_input_multi_touch_4.idc:$(TARGET_COPY_OUT_VENDOR)/usr/idc/virtio_input_multi_touch_4.idc \
302    device/generic/goldfish/input/virtio_input_multi_touch_5.idc:$(TARGET_COPY_OUT_VENDOR)/usr/idc/virtio_input_multi_touch_5.idc \
303    device/generic/goldfish/input/virtio_input_multi_touch_6.idc:$(TARGET_COPY_OUT_VENDOR)/usr/idc/virtio_input_multi_touch_6.idc \
304    device/generic/goldfish/input/virtio_input_multi_touch_7.idc:$(TARGET_COPY_OUT_VENDOR)/usr/idc/virtio_input_multi_touch_7.idc \
305    device/generic/goldfish/input/virtio_input_multi_touch_8.idc:$(TARGET_COPY_OUT_VENDOR)/usr/idc/virtio_input_multi_touch_8.idc \
306    device/generic/goldfish/input/virtio_input_multi_touch_9.idc:$(TARGET_COPY_OUT_VENDOR)/usr/idc/virtio_input_multi_touch_9.idc \
307    device/generic/goldfish/input/virtio_input_multi_touch_10.idc:$(TARGET_COPY_OUT_VENDOR)/usr/idc/virtio_input_multi_touch_10.idc \
308    device/generic/goldfish/input/virtio_input_multi_touch_11.idc:$(TARGET_COPY_OUT_VENDOR)/usr/idc/virtio_input_multi_touch_11.idc \
309    device/generic/goldfish/display_settings_app_compat.xml:$(TARGET_COPY_OUT_VENDOR)/etc/display_settings_app_compat.xml \
310    device/generic/goldfish/display_settings_freeform.xml:$(TARGET_COPY_OUT_VENDOR)/etc/display_settings_freeform.xml \
311    device/generic/goldfish/display_settings.xml:$(TARGET_COPY_OUT_VENDOR)/etc/display_settings.xml \
312    device/generic/goldfish/data/etc/config.ini:config.ini \
313    device/generic/goldfish/wifi/simulated_hostapd.conf:$(TARGET_COPY_OUT_VENDOR)/etc/simulated_hostapd.conf \
314    device/generic/goldfish/wifi/wpa_supplicant.conf:$(TARGET_COPY_OUT_VENDOR)/etc/wifi/wpa_supplicant.conf \
315    frameworks/native/data/etc/android.hardware.bluetooth_le.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.bluetooth_le.xml \
316    frameworks/native/data/etc/android.hardware.bluetooth.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.bluetooth.xml \
317    frameworks/native/data/etc/android.hardware.wifi.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.wifi.xml \
318    frameworks/native/data/etc/android.hardware.wifi.passpoint.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.wifi.passpoint.xml \
319    frameworks/native/data/etc/android.hardware.wifi.direct.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.wifi.direct.xml \
320    device/generic/goldfish/data/etc/handheld_core_hardware.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/handheld_core_hardware.xml \
321    device/generic/goldfish/camera/media_profiles.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_profiles_V1_0.xml \
322    frameworks/av/media/libstagefright/data/media_codecs_google_audio.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_codecs_google_audio.xml \
323    frameworks/av/media/libstagefright/data/media_codecs_google_telephony.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_codecs_google_telephony.xml \
324    device/generic/goldfish/camera/media_codecs_google_video_default.xml:${TARGET_COPY_OUT_VENDOR}/etc/media_codecs_google_video.xml \
325    device/generic/goldfish/camera/media_codecs.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_codecs.xml \
326    device/generic/goldfish/camera/media_codecs_performance.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_codecs_performance.xml \
327    device/generic/goldfish/camera/media_codecs_performance_c2.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_codecs_performance_c2.xml \
328    frameworks/native/data/etc/android.hardware.touchscreen.multitouch.jazzhand.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.touchscreen.multitouch.jazzhand.xml \
329    frameworks/native/data/etc/android.hardware.camera.ar.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.camera.ar.xml \
330    frameworks/native/data/etc/android.hardware.camera.flash-autofocus.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.camera.flash-autofocus.xml \
331    frameworks/native/data/etc/android.hardware.camera.concurrent.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.camera.concurrent.xml \
332    frameworks/native/data/etc/android.hardware.camera.front.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.camera.front.xml \
333    frameworks/native/data/etc/android.hardware.camera.full.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.camera.full.xml \
334    frameworks/native/data/etc/android.hardware.camera.raw.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.camera.raw.xml \
335    frameworks/native/data/etc/android.hardware.vulkan.level-1.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.vulkan.level.xml \
336    frameworks/native/data/etc/android.hardware.vulkan.compute-0.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.vulkan.compute.xml \
337    frameworks/native/data/etc/android.hardware.vulkan.version-1_1.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.vulkan.version.xml \
338    frameworks/native/data/etc/android.software.vulkan.deqp.level-2022-03-01.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.software.vulkan.deqp.level.xml \
339    frameworks/native/data/etc/android.software.opengles.deqp.level-2022-03-01.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.software.opengles.deqp.level.xml \
340    frameworks/native/data/etc/android.software.autofill.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.software.autofill.xml \
341    frameworks/native/data/etc/android.software.verified_boot.xml:${TARGET_COPY_OUT_PRODUCT}/etc/permissions/android.software.verified_boot.xml \
342    device/generic/goldfish/data/etc/permissions/privapp-permissions-goldfish.xml:$(TARGET_COPY_OUT_PRODUCT)/etc/permissions/privapp-permissions-goldfish.xml \
343    hardware/google/camera/devices/EmulatedCamera/hwl/configs/emu_camera_back.json:$(TARGET_COPY_OUT_VENDOR)/etc/config/emu_camera_back.json \
344    hardware/google/camera/devices/EmulatedCamera/hwl/configs/emu_camera_front.json:$(TARGET_COPY_OUT_VENDOR)/etc/config/emu_camera_front.json \
345    hardware/google/camera/devices/EmulatedCamera/hwl/configs/emu_camera_depth.json:$(TARGET_COPY_OUT_VENDOR)/etc/config/emu_camera_depth.json \
346
347
348ifneq ($(EMULATOR_VENDOR_NO_FINGERPRINT), true)
349    PRODUCT_COPY_FILES += \
350        frameworks/native/data/etc/android.hardware.fingerprint.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.fingerprint.xml
351endif
352