From: Jan Altensen Date: Wed, 22 Apr 2020 14:16:01 +0000 (+0200) Subject: initial kane tree X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=21f5f94104de729168a94953d977c6aee5e18209;p=GitHub%2Fmoto-9609%2Fandroid_device_motorola_kane.git initial kane tree Change-Id: I0ab94de494057f2a8ceedec8f100e6af3b983a46 --- 21f5f94104de729168a94953d977c6aee5e18209 diff --git a/Android.mk b/Android.mk new file mode 100644 index 0000000..322d4fd --- /dev/null +++ b/Android.mk @@ -0,0 +1,28 @@ +# +# Copyright (C) 2020 The LineageOS 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. + +# WARNING: Everything listed here will be built on ALL platforms, +# including x86, the emulator, and the SDK. Modules must be uniquely +# named (liblights.tuna), and must build everywhere, or limit themselves +# to only building on ARM if they include assembly. Individual makefiles +# are responsible for having their own logic, for fine-grained control. + +LOCAL_PATH := $(call my-dir) + +ifeq ($(TARGET_DEVICE),kane) + +include $(call all-makefiles-under,$(LOCAL_PATH)) + +endif diff --git a/AndroidProducts.mk b/AndroidProducts.mk new file mode 100644 index 0000000..1eb2b91 --- /dev/null +++ b/AndroidProducts.mk @@ -0,0 +1,17 @@ +# +# Copyright (C) 2020 The LineageOS 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)/lineage_kane.mk diff --git a/BoardConfig.mk b/BoardConfig.mk new file mode 100644 index 0000000..6a34e04 --- /dev/null +++ b/BoardConfig.mk @@ -0,0 +1,28 @@ +# +# Copyright (C) 2020 The LineageOS 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. + +# inherit from common +-include device/motorola/exynos9610-common/BoardConfigCommon.mk + +DEVICE_PATH := device/motorola/kane + +# Assert +TARGET_OTA_ASSERT_DEVICE := kane,one_vision + +# Kernel +TARGET_KERNEL_CONFIG := kane_defconfig + +# inherit from the proprietary version +-include vendor/motorola/kane/BoardConfigVendor.mk diff --git a/device.mk b/device.mk new file mode 100644 index 0000000..9f21c22 --- /dev/null +++ b/device.mk @@ -0,0 +1,20 @@ +# +# Copyright (C) 2020 The LineageOS 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. +# + +# Inherit from common +$(call inherit-product, device/motorola/exynos9610-common/common.mk) + +$(call inherit-product-if-exists, vendor/motorola/kane/kane-vendor.mk) diff --git a/extract-files.sh b/extract-files.sh new file mode 100755 index 0000000..5c03380 --- /dev/null +++ b/extract-files.sh @@ -0,0 +1,68 @@ +#!/bin/bash +# +# Copyright (C) 2018-2020 The LineageOS 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. +# + +set -e + +VENDOR=motorola +DEVICE=kane + +# Load extract_utils and do some sanity checks +MY_DIR="${BASH_SOURCE%/*}" +if [[ ! -d "${MY_DIR}" ]]; then MY_DIR="${PWD}"; fi + +LINEAGE_ROOT="${MY_DIR}"/../../.. + +HELPER="${LINEAGE_ROOT}/vendor/lineage/build/tools/extract_utils.sh" +if [ ! -f "${HELPER}" ]; then + echo "Unable to find helper script at ${HELPER}" + exit 1 +fi +source "${HELPER}" + +SECTION= +KANG= + +while [ "${#}" -gt 0 ]; do + case "${1}" in + -n | --no-cleanup ) + CLEAN_VENDOR=false + ;; + -k | --kang ) + KANG="--kang" + ;; + -s | --section ) + SECTION="${2}"; shift + CLEAN_VENDOR=false + ;; + * ) + SRC="${1}" + ;; + esac + shift +done + +if [ -z "${SRC}" ]; then + SRC="adb" +fi + +# Initialize the helper +setup_vendor "${DEVICE}" "${VENDOR}" "${LINEAGE_ROOT}" true "${CLEAN_VENDOR}" + +extract "${MY_DIR}/proprietary-files.txt" "${SRC}" \ + "${KANG}" --section "${SECTION}" + +"${MY_DIR}/setup-makefiles.sh" diff --git a/lineage.dependencies b/lineage.dependencies new file mode 100644 index 0000000..280ffaa --- /dev/null +++ b/lineage.dependencies @@ -0,0 +1,6 @@ +[ + { + "repository": "android_device_motorola_exynos9610-common", + "target_path": "device/motorola/exynos9610-common" + } +] diff --git a/lineage_kane.mk b/lineage_kane.mk new file mode 100644 index 0000000..7a2a608 --- /dev/null +++ b/lineage_kane.mk @@ -0,0 +1,42 @@ +# +# Copyright (C) 2020 The LineageOS 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. +# + +# 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.mk) + +# Inherit from kane device +$(call inherit-product, device/motorola/kane/device.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/full_base_telephony.mk) + +# Inherit some common Lineage stuff. +$(call inherit-product, vendor/lineage/config/common_full_phone.mk) + +# Device identifier. This must come after all inclusions +PRODUCT_DEVICE := kane +PRODUCT_NAME := lineage_kane +PRODUCT_BRAND := Motorola +PRODUCT_MODEL := One Vision +PRODUCT_MANUFACTURER := Motorola + +PRODUCT_GMS_CLIENTID_BASE := android-motorola + +# Use the latest approved GMS identifiers +PRODUCT_BUILD_PROP_OVERRIDES += \ + PRODUCT_NAME=kane_sprout \ + PRIVATE_BUILD_DESC="10/QSAS30.62-24-3/c27e84:user/release-keys" + +BUILD_FINGERPRINT := motorola/kane_retail/kane_sprout:10/QSAS30.62-24-3/c27e84:user/release-keys diff --git a/proprietary-files.txt b/proprietary-files.txt new file mode 100644 index 0000000..e69de29 diff --git a/setup-makefiles.sh b/setup-makefiles.sh new file mode 100755 index 0000000..b799251 --- /dev/null +++ b/setup-makefiles.sh @@ -0,0 +1,48 @@ +#!/bin/bash +# +# Copyright (C) 2017-2020 The LineageOS 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. +# + +set -e + +VENDOR=motorola +DEVICE=kane + +export INITIAL_COPYRIGHT_YEAR=2020 + +# Load extract_utils and do some sanity checks +MY_DIR="${BASH_SOURCE%/*}" +if [[ ! -d "${MY_DIR}" ]]; then MY_DIR="${PWD}"; fi + +LINEAGE_ROOT="${MY_DIR}/../../.." + +HELPER="${LINEAGE_ROOT}/vendor/lineage/build/tools/extract_utils.sh" +if [ ! -f "${HELPER}" ]; then + echo "Unable to find helper script at ${HELPER}" + exit 1 +fi +source "${HELPER}" + +# Initialize the helper +setup_vendor "${DEVICE}" "${VENDOR}" "${LINEAGE_ROOT}" + +# Copyright headers and guards +write_headers "kane" + +# The standard blobs +write_makefiles "${MY_DIR}/proprietary-files.txt" true + +# Finish +write_footers