commit 9aefe1be3da4b777310063f49e9ef63b8d152ef9 Author: Les De Ridder Date: Mon Nov 11 20:52:56 2019 +0100 Add kugo stubs diff --git a/Android.mk b/Android.mk new file mode 100644 index 0000000..e721c70 --- /dev/null +++ b/Android.mk @@ -0,0 +1,21 @@ +# +# Copyright (C) 2019 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. +# + +LOCAL_PATH := $(call my-dir) + +ifeq ($(TARGET_DEVICE),kugo) + include $(call first-makefiles-under,$(LOCAL_PATH)) +endif diff --git a/AndroidProducts.mk b/AndroidProducts.mk new file mode 100644 index 0000000..86ba87c --- /dev/null +++ b/AndroidProducts.mk @@ -0,0 +1,18 @@ +# +# Copyright (C) 2019 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_kugo.mk diff --git a/BoardConfig.mk b/BoardConfig.mk new file mode 100644 index 0000000..b8faa16 --- /dev/null +++ b/BoardConfig.mk @@ -0,0 +1,48 @@ +# +# Copyright (C) 2019 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 the loire-common +include device/sony/loire-common/BoardConfigCommon.mk + +DEVICE_PATH := device/sony/kugo + +# Assert +TARGET_OTA_ASSERT_DEVICE := kugo + +# TODO +# HIDL +#DEVICE_MANIFEST_FILE += $(DEVICE_PATH)/manifest.xml + +# Include path +TARGET_SPECIFIC_HEADER_PATH += $(DEVICE_PATH)/include + +# TODO +# Kernel properties +#TARGET_KERNEL_CONFIG := lineageos_loire_kugo_defconfig + +# TODO +# Partition information +#BOARD_VOLD_MAX_PARTITIONS := 25 + +# TODO +# Power +#TARGET_TAP_TO_WAKE_NODE := "/sys/devices/virtual/input/clearpad/wakeup_gesture" + +# SELinux +BOARD_SEPOLICY_DIRS += $(DEVICE_PATH)/sepolicy + +# Inherit from proprietary files +include vendor/sony/kugo/BoardConfigVendor.mk diff --git a/extract-files.sh b/extract-files.sh new file mode 100644 index 0000000..948c6b3 --- /dev/null +++ b/extract-files.sh @@ -0,0 +1,30 @@ +#!/bin/bash +# +# Copyright (C) 2019 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. +# + +# 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 + +export DEVICE=kugo +export DEVICE_COMMON=loire-common +export VENDOR=sony + +"./../../${VENDOR}/${DEVICE_COMMON}/extract-files.sh" "$@" diff --git a/kugo.mk b/kugo.mk new file mode 100644 index 0000000..b85c38c --- /dev/null +++ b/kugo.mk @@ -0,0 +1,81 @@ +# +# Copyright (C) 2019 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 loire-common definitions +$(call inherit-product, device/sony/loire-common/loire.mk) + +DEVICE_PATH := device/sony/kugo + +# TODO +# Audio configs +#PRODUCT_COPY_FILES += \ +# $(LOCAL_PATH)/configs/audio/mixer_paths.xml:$(TARGET_COPY_OUT_VENDOR)/etc/mixer_paths.xml \ +# $(LOCAL_PATH)/configs/audio/mixer_paths_auxpcm.xml:$(TARGET_COPY_OUT_VENDOR)/etc/mixer_paths_auxpcm.xml + +# Boot animation +TARGET_SCREEN_HEIGHT := 1280 +TARGET_SCREEN_WIDTH := 720 + +# TODO +# Hardware-specific permissions +#PRODUCT_COPY_FILES += \ +# frameworks/native/data/etc/android.hardware.sensor.barometer.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.sensor.barometer.xml \ +# frameworks/native/data/etc/android.hardware.camera.flash-autofocus.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.camera.flash-autofocus.xml \ +# frameworks/native/data/etc/android.hardware.sensor.proximity.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.sensor.proximity.xml \ +# frameworks/native/data/etc/android.hardware.telephony.gsm.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/android.hardware.telephony.gsm.xml \ +# frameworks/native/data/etc/handheld_core_hardware.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/handheld_core_hardware.xml + +# TODO +# Lineage Hardware +#PRODUCT_PACKAGES += \ +# vendor.lineage.touch@1.0-service.kugo + +# Overlays +DEVICE_PACKAGE_OVERLAYS += \ + $(DEVICE_PATH)/overlay \ + $(DEVICE_PATH)/overlay-lineage + +# TODO +# Permissions +#PRODUCT_COPY_FILES += \ +# frameworks/native/data/etc/handheld_core_hardware.xml:$(TARGET_COPY_OUT_VENDOR)/etc/permissions/handheld_core_hardware.xml + +# Properties +include $(DEVICE_PATH)/system_prop.mk + +# TODO +# Sensors +#PRODUCT_COPY_FILES += \ +# $(LOCAL_PATH)/configs/sensor_def_qcomdev.conf:system/etc/sensor_def_qcomdev.conf + +# TODO: Check +# Screen density +PRODUCT_AAPT_CONFIG := normal +PRODUCT_AAPT_PREF_CONFIG := xhdpi + +# TODO +# Thermal manager +#PRODUCT_COPY_FILES += \ +# $(LOCAL_PATH)/configs/thermanager.xml:$(TARGET_COPY_OUT_VENDOR)/etc/thermanager.xml + +# TODO +# Wifi +#PRODUCT_COPY_FILES += \ +# $(LOCAL_PATH)/configs/wifi/bcmdhd.cal:$(TARGET_COPY_OUT_VENDOR)/firmware/bcmdhd.cal + +# Call the proprietary setup +$(call inherit-product, vendor/sony/kugo/kugo-vendor.mk) + diff --git a/lineage.dependencies b/lineage.dependencies new file mode 100644 index 0000000..3e2cb5a --- /dev/null +++ b/lineage.dependencies @@ -0,0 +1,6 @@ +[ + { + "repository": "android_device_sony_loire-common", + "target_path": "device/sony/loire-common" + } +] diff --git a/lineage_kugo.mk b/lineage_kugo.mk new file mode 100644 index 0000000..67a217c --- /dev/null +++ b/lineage_kugo.mk @@ -0,0 +1,30 @@ +# +# Copyright (C) 2019 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/full_base_telephony.mk) + +# Inherit from kugo device +$(call inherit-product, device/sony/kugo/kugo.mk) + +# Inherit some common Lineage stuff. +$(call inherit-product, vendor/lineage/config/common_full_phone.mk) + +PRODUCT_NAME := lineage_kugo +PRODUCT_DEVICE := kugo +PRODUCT_BRAND := Sony +PRODUCT_MODEL := Xperia X Compact +PRODUCT_MANUFACTURER := Sony diff --git a/proprietary-files.txt b/proprietary-files.txt new file mode 100644 index 0000000..4640904 --- /dev/null +++ b/proprietary-files.txt @@ -0,0 +1 @@ +# TODO diff --git a/setup-makefiles.sh b/setup-makefiles.sh new file mode 100644 index 0000000..2348ad4 --- /dev/null +++ b/setup-makefiles.sh @@ -0,0 +1,30 @@ +#!/bin/bash +# +# Copyright (C) 2019 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. +# + +# 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 + +export DEVICE=kugo +export DEVICE_COMMON=loire-common +export VENDOR=sony + +"./../../${VENDOR}/${DEVICE_COMMON}/setup-makefiles.sh" "$@" diff --git a/system_prop.mk b/system_prop.mk new file mode 100644 index 0000000..37a79ba --- /dev/null +++ b/system_prop.mk @@ -0,0 +1,17 @@ +# +# Copyright (C) 2019 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. +# + +# TODO diff --git a/vendorsetup.sh b/vendorsetup.sh new file mode 100644 index 0000000..cf38c66 --- /dev/null +++ b/vendorsetup.sh @@ -0,0 +1,2 @@ +add_lunch_combo lineage_kugo-eng +add_lunch_combo lineage_kugo-userdebug