commit 259e833dd07b70c15c820b948a75d04d3d1fe9cc Author: Ramii Ahmed Date: Sat Feb 18 21:35:07 2023 +0000 venus: inherit from sm8350-common diff --git a/Android.bp b/Android.bp new file mode 100644 index 0000000..548f4a6 --- /dev/null +++ b/Android.bp @@ -0,0 +1,5 @@ +soong_namespace { + imports: [ + "device/xiaomi/sm8350-common", + ], +} diff --git a/Android.mk b/Android.mk new file mode 100644 index 0000000..4f6d11c --- /dev/null +++ b/Android.mk @@ -0,0 +1,13 @@ +# +# Copyright (C) 2023 The LineageOS Project +# +# SPDX-License-Identifier: Apache-2.0 +# + +LOCAL_PATH := $(call my-dir) + +ifeq ($(TARGET_DEVICE),venus) + +include $(call all-makefiles-under,$(LOCAL_PATH)) + +endif diff --git a/AndroidProducts.mk b/AndroidProducts.mk new file mode 100644 index 0000000..56dde6d --- /dev/null +++ b/AndroidProducts.mk @@ -0,0 +1,13 @@ +# +# Copyright (C) 2023 The LineageOS Project +# +# SPDX-License-Identifier: Apache-2.0 +# + +PRODUCT_MAKEFILES := \ + $(LOCAL_DIR)/lineage_venus.mk + +COMMON_LUNCH_CHOICES := \ + lineage_venus-user \ + lineage_venus-userdebug \ + lineage_venus-eng diff --git a/BoardConfig.mk b/BoardConfig.mk new file mode 100644 index 0000000..1fdfa8c --- /dev/null +++ b/BoardConfig.mk @@ -0,0 +1,13 @@ +# +# Copyright (C) 2023 The LineageOS Project +# +# SPDX-License-Identifier: Apache-2.0 +# + +DEVICE_PATH := device/xiaomi/venus + +# Inherit from sm8350-common +include device/xiaomi/sm8350-common/BoardConfigCommon.mk + +# Include proprietary files +include vendor/xiaomi/venus/BoardConfigVendor.mk diff --git a/README.md b/README.md new file mode 100644 index 0000000..689ef48 --- /dev/null +++ b/README.md @@ -0,0 +1,26 @@ +Copyright (C) 2023 The LineageOS Project + +Device configuration for Xiaomi Mi 11 +========================================= + +The Xiaomi Mi 11 (codenamed _"venus"_) is a flagship smartphone from Xiaomi. + +It was released in December 2020. + +## Device specifications + +Basic | Spec Sheet +-------:|:------------------------- +CPU | Octa-core (1x2.84 GHz Kryo 680 & 3x2.42 GHz Kryo 680 & 4x1.80 GHz Kryo 680) +Chipset | Qualcomm SM8350 Snapdragon 888 5G (5 nm) +GPU | Adreno 660 +Memory | 8/12 GB, LPDDR5 +Storage | 128/256 GB, UFS 3.1 +Shipped Android Version | 11 +Battery | Li-Po 4600 mAh, non-removable +Display | 1440 x 3200 pixels, 6.81 inches (~515 ppi density) +Camera | 108 MP main, 13 MP ultrawide, 5 MP macro, 20 MP front + +## Device picture + +![Xiaomi Mi 11](https://i01.appmifile.com/webfile/globalimg/products/pc/mi11/specs-01.png "Xiaomi Mi 11") diff --git a/device.mk b/device.mk new file mode 100644 index 0000000..14cc3fa --- /dev/null +++ b/device.mk @@ -0,0 +1,15 @@ +# +# Copyright (C) 2023 The LineageOS Project +# +# SPDX-License-Identifier: Apache-2.0 +# + +# Inherit from sm8350-common +$(call inherit-product, device/xiaomi/sm8350-common/common.mk) + +# Soong namespaces +PRODUCT_SOONG_NAMESPACES += \ + $(LOCAL_PATH) + +# Call the proprietary setup +$(call inherit-product, vendor/xiaomi/venus/venus-vendor.mk) diff --git a/extract-files.sh b/extract-files.sh new file mode 100755 index 0000000..a58f3ed --- /dev/null +++ b/extract-files.sh @@ -0,0 +1,21 @@ +#!/bin/bash +# +# Copyright (C) 2020 The LineageOS Project +# +# SPDX-License-Identifier: Apache-2.0 +# + +# If we're being sourced by the common script that we called, +# stop right here. No need to go down the rabbit hole. +if [ "${BASH_SOURCE[0]}" != "${0}" ]; then + return +fi + +set -e + +# Required! +export DEVICE=venus +export DEVICE_COMMON=sm8350-common +export VENDOR=xiaomi + +"./../../${VENDOR}/${DEVICE_COMMON}/extract-files.sh" "$@" diff --git a/lineage_venus.mk b/lineage_venus.mk new file mode 100644 index 0000000..9ae7f92 --- /dev/null +++ b/lineage_venus.mk @@ -0,0 +1,29 @@ +# +# Copyright (C) 2023 The LineageOS Project +# +# SPDX-License-Identifier: Apache-2.0 +# + +# Inherit from those products. Most specific first. +$(call inherit-product, $(SRC_TARGET_DIR)/product/core_64_bit.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/full_base_telephony.mk) + +# Inherit from venus device +$(call inherit-product, device/xiaomi/venus/device.mk) + +# Inherit some common Lineage stuff. +$(call inherit-product, vendor/lineage/config/common_full_phone.mk) + +PRODUCT_BRAND := Xiaomi +PRODUCT_DEVICE := venus +PRODUCT_MANUFACTURER := Xiaomi +PRODUCT_MODEL := M2011K2G +PRODUCT_NAME := lineage_venus + +PRODUCT_GMS_CLIENTID_BASE := android-xiaomi + +PRODUCT_BUILD_PROP_OVERRIDES += \ + PRIVATE_BUILD_DESC="venus_global-user 13 SKQ1.211006.001 V14.0.8.0.TKBMIXM release-keys" + +# Set BUILD_FINGERPRINT variable to be picked up by both system and vendor build.prop +BUILD_FINGERPRINT := Xiaomi/venus_global/venus:13/SKQ1.211006.001/V14.0.8.0.TKBMIXM:user/release-keys diff --git a/setup-makefiles.sh b/setup-makefiles.sh new file mode 100755 index 0000000..bc052bf --- /dev/null +++ b/setup-makefiles.sh @@ -0,0 +1,15 @@ +#!/bin/bash +# +# Copyright (C) 2020 The LineageOS Project +# +# SPDX-License-Identifier: Apache-2.0 +# + +set -e + +# Required! +export DEVICE=venus +export DEVICE_COMMON=sm8350-common +export VENDOR=xiaomi + +"./../../${VENDOR}/${DEVICE_COMMON}/setup-makefiles.sh" "$@"