Android P support
This commit is contained in:
28
AndroidProducts.mk
Normal file
28
AndroidProducts.mk
Normal file
@@ -0,0 +1,28 @@
|
||||
#
|
||||
# Copyright (C) 2011 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)/redroid_x86_64.mk \
|
||||
$(LOCAL_DIR)/redroid_arm64.mk \
|
||||
|
||||
COMMON_LUNCH_CHOICES := \
|
||||
redroid_x86_64-eng \
|
||||
redroid_x86_64-userdebug \
|
||||
redroid_x86_64-user \
|
||||
redroid_arm64-eng \
|
||||
redroid_arm64-userdebug \
|
||||
redroid_arm64-user
|
||||
|
||||
32
init.redroid.rc
Normal file
32
init.redroid.rc
Normal file
@@ -0,0 +1,32 @@
|
||||
on early-init
|
||||
mount none /system/etc /etc bind rec # docker fix
|
||||
mount sysfs sysfs /sys rw remount # ueventd fix
|
||||
|
||||
write /data/.empty 0
|
||||
mount none /data/.empty /proc/vmallocinfo bind # lxcfs?
|
||||
|
||||
# Mount binderfs
|
||||
mkdir /dev/binderfs
|
||||
mount binder binder /dev/binderfs stats=global
|
||||
chmod 0755 /dev/binderfs
|
||||
|
||||
symlink /dev/binderfs/binder /dev/binder
|
||||
symlink /dev/binderfs/hwbinder /dev/hwbinder
|
||||
symlink /dev/binderfs/vndbinder /dev/vndbinder
|
||||
|
||||
chmod 0666 /dev/binderfs/hwbinder
|
||||
chmod 0666 /dev/binderfs/binder
|
||||
chmod 0666 /dev/binderfs/vndbinder
|
||||
|
||||
# fix for WSL2
|
||||
mkdir /dev/input
|
||||
|
||||
setprop gralloc.gbm.device /dev/dri/renderD128
|
||||
|
||||
on post-fs-data
|
||||
# fix for static IP, must after post-fs-data and before netd
|
||||
exec - system system -- /vendor/bin/ipconfigstore
|
||||
|
||||
# no need to mount, and encryption not supported yet
|
||||
trigger nonencrypted
|
||||
|
||||
93
manifest.xml
Normal file
93
manifest.xml
Normal file
@@ -0,0 +1,93 @@
|
||||
<manifest version="1.0" type="device" target-level="2">
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.audio</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>2.0</version>
|
||||
<interface>
|
||||
<name>IDevicesFactory</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.audio.effect</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>2.0</version>
|
||||
<interface>
|
||||
<name>IEffectsFactory</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.configstore</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>1.1</version>
|
||||
<interface>
|
||||
<name>ISurfaceFlingerConfigs</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.drm</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>1.0</version>
|
||||
<interface>
|
||||
<name>ICryptoFactory</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<interface>
|
||||
<name>IDrmFactory</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<fqname>@1.1::ICryptoFactory/clearkey</fqname>
|
||||
<fqname>@1.1::IDrmFactory/clearkey</fqname>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.graphics.allocator</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>2.0</version>
|
||||
<interface>
|
||||
<name>IAllocator</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.graphics.mapper</name>
|
||||
<transport arch="32+64">passthrough</transport>
|
||||
<version>2.0</version>
|
||||
<interface>
|
||||
<name>IMapper</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.graphics.composer</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>2.1</version>
|
||||
<interface>
|
||||
<name>IComposer</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl" override="true">
|
||||
<name>android.hardware.keymaster</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>3.0</version>
|
||||
<interface>
|
||||
<name>IKeymasterDevice</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
<hal format="hidl">
|
||||
<name>android.hardware.media.omx</name>
|
||||
<transport>hwbinder</transport>
|
||||
<version>1.0</version>
|
||||
<interface>
|
||||
<name>IOmx</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
<interface>
|
||||
<name>IOmxStore</name>
|
||||
<instance>default</instance>
|
||||
</interface>
|
||||
</hal>
|
||||
</manifest>
|
||||
39
overlay/frameworks/base/core/res/res/values/config.xml
Normal file
39
overlay/frameworks/base/core/res/res/values/config.xml
Normal file
@@ -0,0 +1,39 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
/*
|
||||
** Copyright 2009, 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.
|
||||
*/
|
||||
-->
|
||||
|
||||
<!-- These resources are around just to allow their values to be customized
|
||||
for different hardware and product builds. Do not translate.
|
||||
|
||||
NOTE: The naming convention is "config_camelCaseValue". Some legacy
|
||||
entries do not follow the convention, but all new entries should. -->
|
||||
|
||||
<resources>
|
||||
|
||||
<!-- Whether a software navigation bar should be shown. NOTE: in the future this may be
|
||||
autodetected from the Configuration. -->
|
||||
<bool name="config_showNavigationBar">true</bool>
|
||||
|
||||
<!-- Is the lock-screen disabled for new users by default -->
|
||||
<bool name="config_disableLockscreenByDefault">true</bool>
|
||||
|
||||
<!-- True if the device requires AppWidgetService even if it does not have
|
||||
the PackageManager.FEATURE_APP_WIDGETS feature -->
|
||||
<bool name="config_enableAppWidgetService">true</bool>
|
||||
|
||||
</resources>
|
||||
26
overlay/frameworks/base/packages/SettingsProvider/res/values/defaults.xml
Executable file
26
overlay/frameworks/base/packages/SettingsProvider/res/values/defaults.xml
Executable file
@@ -0,0 +1,26 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
/**
|
||||
* Copyright (c) 2009, 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.
|
||||
*/
|
||||
-->
|
||||
<resources>
|
||||
<!-- Default for UI touch sounds enabled -->
|
||||
<bool name="def_sound_effects_enabled">false</bool>
|
||||
|
||||
<bool name="def_lockscreen_disabled">true</bool>
|
||||
|
||||
<bool name="def_package_verifier_enable">false</bool>
|
||||
</resources>
|
||||
92
redroid.mk
Normal file
92
redroid.mk
Normal file
@@ -0,0 +1,92 @@
|
||||
# Copyright (C) 2013 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_SOONG_NAMESPACES += external/mesa3d
|
||||
|
||||
# Arm64 linker failed, complain unsupported TLS DT entry
|
||||
# caused by libclang_rt.ubsan_standalone-aarch64-android.so ??
|
||||
# AUDIOSERVER_MULTILIB := first
|
||||
|
||||
# ?
|
||||
PRODUCT_PROPERTY_OVERRIDES += \
|
||||
ro.radio.noril=yes
|
||||
|
||||
PRODUCT_PROPERTY_OVERRIDES += \
|
||||
debug.sf.nobootanimation=1
|
||||
|
||||
# required by sync.sh script
|
||||
PRODUCT_PACKAGES += \
|
||||
fs_config
|
||||
|
||||
PRODUCT_PACKAGES += \
|
||||
hwcomposer.redroid \
|
||||
gralloc.redroid \
|
||||
gralloc.gbm \
|
||||
gatekeeper.ranchu \
|
||||
libEGL_swiftshader \
|
||||
libGLESv1_CM_swiftshader \
|
||||
libGLESv2_swiftshader \
|
||||
libGLES_mesa \
|
||||
ipconfigstore \
|
||||
|
||||
PRODUCT_PROPERTY_OVERRIDES += \
|
||||
ro.hardware=redroid \
|
||||
ro.hardware.gatekeeper=ranchu \
|
||||
ro.sf.lcd_density=320 \
|
||||
|
||||
# Phone App required
|
||||
PRODUCT_PACKAGES += \
|
||||
rild
|
||||
|
||||
# WiFi required by SystemUI
|
||||
PRODUCT_PACKAGES += \
|
||||
android.hardware.wifi@1.0-service
|
||||
|
||||
PRODUCT_COPY_FILES += \
|
||||
frameworks/native/data/etc/android.hardware.wifi.xml:system/etc/permissions/android.hardware.wifi.xml \
|
||||
|
||||
# required HIDL
|
||||
PRODUCT_PACKAGES += \
|
||||
audio.r_submix.default \
|
||||
android.hardware.audio@2.0-service \
|
||||
android.hardware.audio@2.0-impl \
|
||||
android.hardware.audio.effect@2.0-impl \
|
||||
android.hardware.configstore@1.1-service \
|
||||
android.hardware.drm@1.0-service \
|
||||
android.hardware.drm@1.0-impl \
|
||||
android.hardware.drm@1.1-service.clearkey \
|
||||
android.hardware.gatekeeper@1.0-service \
|
||||
android.hardware.gatekeeper@1.0-impl \
|
||||
android.hardware.graphics.allocator@2.0-service \
|
||||
android.hardware.graphics.allocator@2.0-impl \
|
||||
android.hardware.graphics.composer@2.1-service \
|
||||
android.hardware.graphics.composer@2.1-impl \
|
||||
android.hardware.graphics.mapper@2.0-impl \
|
||||
android.hardware.keymaster@3.0-service \
|
||||
android.hardware.keymaster@3.0-impl \
|
||||
|
||||
|
||||
PRODUCT_COPY_FILES += \
|
||||
device/generic/goldfish/camera/media_codecs.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_codecs.xml \
|
||||
frameworks/av/media/libstagefright/data/media_codecs_google_audio.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_codecs_google_audio.xml \
|
||||
frameworks/av/media/libstagefright/data/media_codecs_google_telephony.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_codecs_google_telephony.xml \
|
||||
frameworks/av/media/libstagefright/data/media_codecs_google_video.xml:$(TARGET_COPY_OUT_VENDOR)/etc/media_codecs_google_video.xml \
|
||||
frameworks/av/media/libeffects/data/audio_effects.conf:$(TARGET_COPY_OUT_VENDOR)/etc/audio_effects.conf \
|
||||
frameworks/native/data/etc/android.hardware.ethernet.xml:/system/etc/permissions/android.hardware.ethernet.xml \
|
||||
device/generic/goldfish/audio_policy.conf:$(TARGET_COPY_OUT_VENDOR)/etc/audio_policy.conf \
|
||||
|
||||
|
||||
# Extend heap size we use for dalvik/art runtime
|
||||
$(call inherit-product, frameworks/native/build/tablet-7in-hdpi-1024-dalvik-heap.mk)
|
||||
|
||||
30
redroid_arm64.mk
Normal file
30
redroid_arm64.mk
Normal file
@@ -0,0 +1,30 @@
|
||||
# Copyright (C) 2012 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.
|
||||
|
||||
$(call inherit-product, $(SRC_TARGET_DIR)/product/core_64_bit.mk)
|
||||
$(call inherit-product, $(SRC_TARGET_DIR)/product/aosp_base.mk)
|
||||
|
||||
$(call inherit-product, $(LOCAL_PATH)/redroid.mk)
|
||||
|
||||
# overrides
|
||||
PRODUCT_NAME := redroid_arm64
|
||||
PRODUCT_DEVICE := redroid_arm64
|
||||
PRODUCT_BRAND := ReDroid
|
||||
PRODUCT_MODEL := ReDroid
|
||||
|
||||
PRODUCT_PACKAGE_OVERLAYS := $(LOCAL_PATH)/overlay
|
||||
|
||||
PRODUCT_COPY_FILES += \
|
||||
$(LOCAL_PATH)/init.redroid.rc:$(TARGET_COPY_OUT_VENDOR)/etc/init/hw/init.redroid.rc \
|
||||
|
||||
21
redroid_arm64/BoardConfig.mk
Normal file
21
redroid_arm64/BoardConfig.mk
Normal file
@@ -0,0 +1,21 @@
|
||||
include device/generic/arm64/BoardConfig.mk
|
||||
|
||||
TARGET_USES_HWC2 := true
|
||||
|
||||
# want all fonts
|
||||
SMALLER_FONT_FOOTPRINT := false
|
||||
MINIMAL_FONT_FOOTPRINT := false
|
||||
|
||||
BUILD_EMULATOR_OPENGL := false
|
||||
|
||||
# use seperate vendor partition
|
||||
TARGET_COPY_OUT_VENDOR := vendor
|
||||
|
||||
# TODO add panfrost
|
||||
BOARD_GPU_DRIVERS := freedreno lima virgl radeonsi
|
||||
|
||||
DEVICE_MANIFEST_FILE := device/redroid/manifest.xml
|
||||
PRODUCT_ENFORCE_VINTF_MANIFEST := true
|
||||
|
||||
# ~ 1.3G
|
||||
BOARD_SYSTEMIMAGE_PARTITION_SIZE := 1388314624
|
||||
29
redroid_x86_64.mk
Normal file
29
redroid_x86_64.mk
Normal file
@@ -0,0 +1,29 @@
|
||||
# Copyright (C) 2012 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.
|
||||
|
||||
$(call inherit-product, $(SRC_TARGET_DIR)/product/core_64_bit.mk)
|
||||
$(call inherit-product, $(SRC_TARGET_DIR)/product/aosp_base.mk)
|
||||
|
||||
$(call inherit-product, $(LOCAL_PATH)/redroid.mk)
|
||||
|
||||
PRODUCT_NAME := redroid_x86_64
|
||||
PRODUCT_DEVICE := redroid_x86_64
|
||||
PRODUCT_BRAND := ReDroid
|
||||
PRODUCT_MODEL := ReDroid
|
||||
|
||||
PRODUCT_PACKAGE_OVERLAYS := $(LOCAL_PATH)/overlay
|
||||
|
||||
PRODUCT_COPY_FILES += \
|
||||
$(LOCAL_PATH)/init.redroid.rc:$(TARGET_COPY_OUT_VENDOR)/etc/init/hw/init.redroid.rc \
|
||||
|
||||
16
redroid_x86_64/BoardConfig.mk
Executable file
16
redroid_x86_64/BoardConfig.mk
Executable file
@@ -0,0 +1,16 @@
|
||||
include device/generic/x86_64/BoardConfig.mk
|
||||
|
||||
TARGET_USES_HWC2 := true
|
||||
|
||||
# want all fonts
|
||||
SMALLER_FONT_FOOTPRINT := false
|
||||
MINIMAL_FONT_FOOTPRINT := false
|
||||
|
||||
# use seperate vendor partition
|
||||
TARGET_COPY_OUT_VENDOR := vendor
|
||||
|
||||
# i915g soong build error
|
||||
BOARD_GPU_DRIVERS := i915 i965 nouveau kmsro r300g r600g virgl vmwgfx etnaviv iris tegra radeonsi
|
||||
|
||||
DEVICE_MANIFEST_FILE := device/redroid/manifest.xml
|
||||
PRODUCT_ENFORCE_VINTF_MANIFEST := true
|
||||
9
vendorsetup.sh
Executable file
9
vendorsetup.sh
Executable file
@@ -0,0 +1,9 @@
|
||||
# This file is executed by build/envsetup.sh, and can use anything
|
||||
# defined in envsetup.sh.
|
||||
|
||||
add_lunch_combo redroid_x86_64-eng
|
||||
add_lunch_combo redroid_x86_64-userdebug
|
||||
add_lunch_combo redroid_x86_64-user
|
||||
add_lunch_combo redroid_arm64-eng
|
||||
add_lunch_combo redroid_arm64-userdebug
|
||||
add_lunch_combo redroid_arm64-user
|
||||
Reference in New Issue
Block a user