diff options
| author | Nicholas Sauer <nicksauer@google.com> | 2017-05-08 13:03:31 -0700 |
|---|---|---|
| committer | Nicholas Sauer <nicksauer@google.com> | 2017-05-08 18:10:10 -0700 |
| commit | 4741444e99315d1532399ee6719bd23de4717d64 (patch) | |
| tree | 86059a8e056a221dd6f45d8ba2c0ce849fdeb353 | |
| parent | d016850f60113608faec76a1751176499fd34372 (diff) | |
| download | device_generic_car-oreo-dev.tar.gz device_generic_car-oreo-dev.tar.bz2 device_generic_car-oreo-dev.zip | |
x86 car emulatorandroid-vts-8.0_r2android-vts-8.0_r1oreo-dev
bug: 38129403
Test: lunch car_emu_x86 and make. run emulator
Change-Id: Ib0ffbd77a7c2925d386c17a4a875d4fe2f3ec3c3
| -rw-r--r-- | car-x86/AndroidProducts.mk | 18 | ||||
| -rw-r--r-- | car-x86/BoardConfig.mk | 31 | ||||
| -rw-r--r-- | car-x86/car_emu_x86.mk | 50 | ||||
| -rw-r--r-- | car-x86/vendorsetup.sh | 23 | ||||
| -rw-r--r-- | common/product/aosp_x86.mk | 49 |
5 files changed, 171 insertions, 0 deletions
diff --git a/car-x86/AndroidProducts.mk b/car-x86/AndroidProducts.mk new file mode 100644 index 0000000..8113bfa --- /dev/null +++ b/car-x86/AndroidProducts.mk @@ -0,0 +1,18 @@ +# +# Copyright (C) 2017 The Android Open-Source Project +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +PRODUCT_MAKEFILES := \ + $(LOCAL_DIR)/car_emu_x86.mk diff --git a/car-x86/BoardConfig.mk b/car-x86/BoardConfig.mk new file mode 100644 index 0000000..0c3d3b4 --- /dev/null +++ b/car-x86/BoardConfig.mk @@ -0,0 +1,31 @@ +# BoardConfig.mk +# +# Product-specific compile-time definitions. +# + +# The generic product target doesn't have any hardware-specific pieces. +TARGET_NO_BOOTLOADER := true +TARGET_NO_KERNEL := true + +TARGET_ARCH := x86 +TARGET_CPU_ABI := x86 +TARGET_CPU_SMP := true + +SMALLER_FONT_FOOTPRINT := true +MINIMAL_FONT_FOOTPRINT := true + +# Build OpenGLES emulation libraries +BUILD_EMULATOR_OPENGL := true +BUILD_EMULATOR_OPENGL_DRIVER := true + +TARGET_USERIMAGES_USE_EXT4 := true +BOARD_SYSTEMIMAGE_PARTITION_SIZE := 3221225472 +BOARD_USERDATAIMAGE_PARTITION_SIZE := 576716800 +BOARD_CACHEIMAGE_PARTITION_SIZE := 69206016 +BOARD_CACHEIMAGE_FILE_SYSTEM_TYPE := ext4 +BOARD_FLASH_BLOCK_SIZE := 512 +TARGET_USERIMAGES_SPARSE_EXT_DISABLED := true + +BOARD_SEPOLICY_DIRS += \ + packages/services/Car/car_product/sepolicy \ + device/generic/car/common/sepolicy diff --git a/car-x86/car_emu_x86.mk b/car-x86/car_emu_x86.mk new file mode 100644 index 0000000..e396b2e --- /dev/null +++ b/car-x86/car_emu_x86.mk @@ -0,0 +1,50 @@ +# +#Copyright (C) 2017 The Android Open Source Project +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +PRODUCT_COPY_FILES += \ + device/generic/car/common/bootanimations/bootanimation-832.zip:system/media/bootanimation.zip \ + device/generic/car/common/init.car-emulator.rc:root/init.goldfish.rc + +$(call inherit-product, device/generic/car/common/product/aosp_x86.mk) +$(call inherit-product, packages/services/Car/car_product/build/car.mk) +PRODUCT_PACKAGE_OVERLAYS := packages/services/Car/car_product/overlay + +# Overrides +PRODUCT_BRAND := google +PRODUCT_MODEL := Car on x86 emulator +PRODUCT_NAME := car_emu_x86 +PRODUCT_DEVICE := car-x86 + +PRODUCT_RESTRICT_VENDOR_FILES := false + +PRODUCT_PACKAGES += \ + vehicle.default +# Replace framework versions with dummy one, which is essentially +# the same as removing the xml. Needs this as there is no easy +# way to remove PRODUCT_COPY_FILES from inherited products. +PRODUCT_COPY_FILES += \ + device/generic/car/common/android.hardware.dummy.xml:system/etc/permissions/handheld_core_hardware.xml \ + packages/services/Car/car_product/init/init.car.rc:root/init.car.rc \ + packages/services/Car/car_product/init/init.bootstat.rc:root/init.bootstat.rc + +PRODUCT_COPY_FILES += \ + frameworks/native/data/etc/android.hardware.type.automotive.xml:system/etc/permissions/android.hardware.type.automotive.xml \ + frameworks/native/data/etc/android.hardware.screen.landscape.xml:system/etc/permissions/android.hardware.screen.landscape.xml + +PRODUCT_PROPERTY_OVERRIDES += \ + android.car.drawer.unlimited=true \ + android.car.hvac.demo=true \ + com.android.car.radio.demo=true \ + com.android.car.radio.demo.dual=true diff --git a/car-x86/vendorsetup.sh b/car-x86/vendorsetup.sh new file mode 100644 index 0000000..e838bec --- /dev/null +++ b/car-x86/vendorsetup.sh @@ -0,0 +1,23 @@ +# +# Copyright (C) 2017 The Android Open Source Project +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +# This file is executed by build/envsetup.sh, and can use anything +# defined in envsetup.sh. +# +# In particular, you can add lunch options with the add_lunch_combo +# function: add_lunch_combo generic-eng + +add_lunch_combo car_emu_x86-userdebug diff --git a/common/product/aosp_x86.mk b/common/product/aosp_x86.mk new file mode 100644 index 0000000..be0585a --- /dev/null +++ b/common/product/aosp_x86.mk @@ -0,0 +1,49 @@ +# +# Copyright 2017 The Android Open-Source Project +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +# This is a build configuration for a full-featured build of the +# Open-Source part of the tree. It's geared toward a US-centric +# build quite specifically for the emulator, and might not be +# entirely appropriate to inherit from for on-device configurations. + +# If running on an emulator or some other device that has a LAN connection +# that isn't a wifi connection. This will instruct init.rc to enable the +# network connection so that you can use it with ADB + +# This is for enabling ethernet support for ranchu. +# Consider removing this after RIL support is provided in ranchu. +PRODUCT_COPY_FILES += frameworks/native/data/etc/android.hardware.ethernet.xml:system/etc/permissions/android.hardware.ethernet.xml + +$(call inherit-product, $(SRC_TARGET_DIR)/product/core.mk) +$(call inherit-product, device/generic/car/common/product/aosp_base_telephony.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/board/generic_x86/device.mk) + +include device/generic/car/common/product/emulator.mk + +ifdef NET_ETH0_STARTONBOOT + PRODUCT_PROPERTY_OVERRIDES += net.eth0.startonboot=1 +endif + +# Ensure we package the BIOS files too. +PRODUCT_PACKAGES += \ + bios.bin \ + vgabios-cirrus.bin \ + +# Overrides +PRODUCT_NAME := aosp_x86 +PRODUCT_DEVICE := generic_x86 +PRODUCT_BRAND := Android +PRODUCT_MODEL := AOSP on IA x86 Emulator |
