dm3q: Inherit from common tree
Change-Id: Ib4d9913df70195ac1efd2f117c3efbbeb4e2e75a
This commit is contained in:
2
Android.bp
Normal file
2
Android.bp
Normal file
@@ -0,0 +1,2 @@
|
||||
soong_namespace {
|
||||
}
|
22
Android.mk
Normal file
22
Android.mk
Normal file
@@ -0,0 +1,22 @@
|
||||
#
|
||||
# Copyright (C) 2023 The LineageOS Project
|
||||
#
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
#
|
||||
|
||||
LOCAL_PATH := $(call my-dir)
|
||||
|
||||
ifneq ($(filter dm3q,$(TARGET_DEVICE)),)
|
||||
|
||||
WIFI_FIRMWARE_SYMLINKS := $(TARGET_OUT_VENDOR)/firmware/
|
||||
$(WIFI_FIRMWARE_SYMLINKS): $(LOCAL_INSTALLED_MODULE)
|
||||
@echo "Creating WiFi firmware symlinks: $@"
|
||||
@mkdir -p $@/wlan/qca_cld/kiwi_v2
|
||||
$(hide) ln -sf /data/vendor/firmware/wlanmdsp.mbn $@/wlanmdsp.otaupdate
|
||||
$(hide) ln -sf /mnt/vendor/persist/kiwi_v2/wlan_mac.bin $@/wlan/qca_cld/kiwi_v2/wlan_mac.bin
|
||||
$(hide) ln -sf /vendor/etc/wifi/kiwi_v2/WCNSS_qcom_cfg.ini $@/wlan/qca_cld/kiwi_v2/WCNSS_qcom_cfg.ini
|
||||
|
||||
ALL_DEFAULT_INSTALLED_MODULES += \
|
||||
$(WIFI_FIRMWARE_SYMLINKS)
|
||||
|
||||
endif
|
13
AndroidProducts.mk
Normal file
13
AndroidProducts.mk
Normal file
@@ -0,0 +1,13 @@
|
||||
#
|
||||
# Copyright (C) 2023 The LineageOS Project
|
||||
#
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
#
|
||||
|
||||
PRODUCT_MAKEFILES := \
|
||||
$(LOCAL_DIR)/lineage_dm3q.mk
|
||||
|
||||
COMMON_LUNCH_CHOICES := \
|
||||
lineage_dm3q-eng \
|
||||
lineage_dm3q-user \
|
||||
lineage_dm3q-userdebug
|
19
BoardConfig.mk
Normal file
19
BoardConfig.mk
Normal file
@@ -0,0 +1,19 @@
|
||||
#
|
||||
# Copyright (C) 2023 The LineageOS Project
|
||||
#
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
#
|
||||
|
||||
# Include the common OEM chipset BoardConfig.
|
||||
include device/samsung/sm8550-common/BoardConfigCommon.mk
|
||||
|
||||
DEVICE_PATH := device/samsung/dm3q
|
||||
|
||||
# Assert
|
||||
TARGET_OTA_ASSERT_DEVICE := dm3q
|
||||
|
||||
# Display
|
||||
TARGET_SCREEN_DENSITY := 450
|
||||
|
||||
# Include the proprietary files BoardConfig.
|
||||
include vendor/samsung/dm3q/BoardConfigVendor.mk
|
1
board-info.txt
Normal file
1
board-info.txt
Normal file
@@ -0,0 +1 @@
|
||||
require board=kalama|dm3q
|
31
device.mk
Normal file
31
device.mk
Normal file
@@ -0,0 +1,31 @@
|
||||
#
|
||||
# Copyright (C) 2023 The LineageOS Project
|
||||
#
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
#
|
||||
|
||||
# AAPT
|
||||
PRODUCT_AAPT_CONFIG := normal
|
||||
PRODUCT_AAPT_PREF_CONFIG := xxxhdpi
|
||||
|
||||
# Boot animation
|
||||
TARGET_SCREEN_HEIGHT := 2340
|
||||
TARGET_SCREEN_WIDTH := 1080
|
||||
|
||||
# Init
|
||||
PRODUCT_PACKAGES += \
|
||||
init.dm3q.rc
|
||||
|
||||
# Namespaces
|
||||
PRODUCT_SOONG_NAMESPACES += \
|
||||
$(LOCAL_PATH)
|
||||
|
||||
# Overlays
|
||||
PRODUCT_PACKAGES += \
|
||||
FrameworksResDm2q
|
||||
|
||||
# Inherit from the common OEM chipset makefile.
|
||||
$(call inherit-product, device/samsung/sm8550-common/common.mk)
|
||||
|
||||
# Inherit from the proprietary files makefile.
|
||||
$(call inherit-product, vendor/samsung/dm3q/dm3q-vendor.mk)
|
27
extract-files.sh
Executable file
27
extract-files.sh
Executable file
@@ -0,0 +1,27 @@
|
||||
#!/bin/bash
|
||||
#
|
||||
# Copyright (C) 2016 The CyanogenMod Project
|
||||
# Copyright (C) 2017-2020 The LineageOS Project
|
||||
#
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
#
|
||||
|
||||
function blob_fixup() {
|
||||
case "${1}" in
|
||||
esac
|
||||
}
|
||||
|
||||
# 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=dm3q
|
||||
export DEVICE_COMMON=sm8550-common
|
||||
export VENDOR=samsung
|
||||
export VENDOR_COMMON=${VENDOR}
|
||||
|
||||
"./../../${VENDOR_COMMON}/${DEVICE_COMMON}/extract-files.sh" "$@"
|
11
init/Android.bp
Normal file
11
init/Android.bp
Normal file
@@ -0,0 +1,11 @@
|
||||
//
|
||||
// Copyright (C) 2023 The LineageOS Project
|
||||
// SPDX-License-Identifier: Apache-2.0
|
||||
//
|
||||
|
||||
prebuilt_etc {
|
||||
name: "init.dm3q.rc",
|
||||
src: "init.dm3q.rc",
|
||||
sub_dir: "init/hw",
|
||||
vendor: true,
|
||||
}
|
276
init/init.dm3q.rc
Normal file
276
init/init.dm3q.rc
Normal file
@@ -0,0 +1,276 @@
|
||||
|
||||
# Copyright (c) 2019-2021, The Linux Foundation. All rights reserved.
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions are
|
||||
# met:
|
||||
# * Redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer.
|
||||
# * Redistributions in binary form must reproduce the above
|
||||
# copyright notice, this list of conditions and the following
|
||||
# disclaimer in the documentation and/or other materials provided
|
||||
# with the distribution.
|
||||
# * Neither the name of The Linux Foundation nor the names of its
|
||||
# contributors may be used to endorse or promote products derived
|
||||
# from this software without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY EXPRESS OR IMPLIED
|
||||
# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT
|
||||
# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS
|
||||
# BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
|
||||
# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
|
||||
# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
|
||||
# BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
|
||||
# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
|
||||
# OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
|
||||
# IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
#
|
||||
#
|
||||
|
||||
on early-init
|
||||
|
||||
on init
|
||||
|
||||
on late-init
|
||||
|
||||
on post-fs
|
||||
|
||||
on late-fs
|
||||
|
||||
on post-fs-data
|
||||
# Samsung Pay
|
||||
mkdir /efs/pfw_data 0760 vendor_spay vendor_spay
|
||||
|
||||
# MST/NFC Switch
|
||||
chown vendor_spay system /dev/mst_ctrl
|
||||
chmod 0660 /dev/mst_ctrl
|
||||
|
||||
#mAFPC
|
||||
mkdir /efs/afc 0760 system system
|
||||
exec - system system -- /system/bin/mafpc_write
|
||||
|
||||
on boot
|
||||
# SDHMS Slowdown : Cpuset
|
||||
mkdir /dev/cpuset/abnormal
|
||||
write /dev/cpuset/abnormal/cpus 0-2
|
||||
copy /dev/cpuset/mems /dev/cpuset/abnormal/mems
|
||||
|
||||
chown system system /dev/cpuset/abnormal
|
||||
chown system system /dev/cpuset/abnormal/tasks
|
||||
chown system system /dev/cpuset/abnormal/cpus
|
||||
chown system system /dev/cpuset/abnormal/cgroup.procs
|
||||
chmod 0664 /dev/cpuset/abnormal/tasks
|
||||
chmod 0664 /dev/cpuset/abnormal/cpus
|
||||
chmod 0664 /dev/cpuset/abnormal/cgroup.procs
|
||||
|
||||
mkdir /dev/cpuset/moderate
|
||||
write /dev/cpuset/moderate/cpus 0-2
|
||||
copy /dev/cpuset/mems /dev/cpuset/moderate/mems
|
||||
|
||||
chown system system /dev/cpuset/moderate
|
||||
chown system system /dev/cpuset/moderate/tasks
|
||||
chown system system /dev/cpuset/moderate/cpus
|
||||
chown system system /dev/cpuset/moderate/cgroup.procs
|
||||
chmod 0664 /dev/cpuset/moderate/tasks
|
||||
chmod 0664 /dev/cpuset/moderate/cpus
|
||||
chmod 0664 /dev/cpuset/moderate/cgroup.procs
|
||||
|
||||
write /proc/sys/vm/swappiness 130
|
||||
write /sys/module/zram/parameters/zram_balance_ratio 0
|
||||
|
||||
# [ Permissions for Range Sensor Sensor
|
||||
# Range Sensor
|
||||
chown system radio /sys/class/sensors/range_sensor/ambient
|
||||
chown system radio /sys/class/sensors/range_sensor/cal01
|
||||
chown system radio /sys/class/sensors/range_sensor/cal02
|
||||
chown system radio /sys/class/sensors/range_sensor/cal_uid
|
||||
chown system radio /sys/class/sensors/range_sensor/open_calibration
|
||||
chown system radio /sys/class/sensors/range_sensor/calibration
|
||||
chown system radio /sys/class/sensors/range_sensor/enable
|
||||
chown system radio /sys/class/sensors/range_sensor/frame_rate
|
||||
chown system radio /sys/class/sensors/range_sensor/fw_version
|
||||
chown system radio /sys/class/sensors/range_sensor/mode
|
||||
chown system radio /sys/class/sensors/range_sensor/name
|
||||
chown system radio /sys/class/sensors/range_sensor/range_sigma
|
||||
chown system radio /sys/class/sensors/range_sensor/status
|
||||
chown system radio /sys/class/sensors/range_sensor/target_status
|
||||
chown system radio /sys/class/sensors/range_sensor/temp
|
||||
chown system radio /sys/class/sensors/range_sensor/test01
|
||||
chown system radio /sys/class/sensors/range_sensor/test02
|
||||
chown system radio /sys/class/sensors/range_sensor/test03
|
||||
chown system radio /sys/class/sensors/range_sensor/test_mode
|
||||
chown system radio /sys/class/sensors/range_sensor/uid
|
||||
chown system radio /sys/class/sensors/range_sensor/vendor
|
||||
chown system radio /sys/class/sensors/range_sensor/zone
|
||||
chown system radio /sys/class/sensors/range_sensor/file_cal
|
||||
chown system radio /sys/class/sensors/range_sensor/file_p2p
|
||||
chown system radio /sys/class/sensors/range_sensor/file_shape
|
||||
chown system radio /sys/class/sensors/range_sensor/interrupt
|
||||
chown system radio /sys/class/sensors/range_sensor/error
|
||||
# ] Permissions for Range Sensor
|
||||
|
||||
on shutdown
|
||||
|
||||
# service definition
|
||||
|
||||
# on property triggers
|
||||
|
||||
# Create carrier folder for HiddenMenu
|
||||
on post-fs
|
||||
mkdir /efs/carrier 0755 radio system
|
||||
chown radio system /efs/carrier
|
||||
chown radio system /efs/carrier/HiddenMenu
|
||||
|
||||
#permission for cache reclaim feature
|
||||
chown system system /proc/proc_caches_reclaim
|
||||
|
||||
# For Range Sensor
|
||||
chmod 0660 /dev/range_sensor
|
||||
chown system system /dev/range_sensor
|
||||
mkdir /efs/range_sensor 0770 system system
|
||||
chown system system /efs/range_sensor/cal_data.bin
|
||||
chmod 0660 /efs/range_sensor/cal_data.bin
|
||||
chown system system /efs/range_sensor/vl53l5_cal_shape.bin
|
||||
chmod 0660 /efs/range_sensor/vl53l5_cal_shape.bin
|
||||
chown system system /efs/range_sensor/vl53l5_cal_p2p.bin
|
||||
chmod 0660 /efs/range_sensor/vl53l5_cal_p2p.bin
|
||||
|
||||
# Range Sensor
|
||||
on property:sys.boot_completed=1
|
||||
write /sys/class/sensors/range_sensor/calibration 0
|
||||
|
||||
# Pageboostd
|
||||
on property:sys.boot_completed=1
|
||||
start pageboostd
|
||||
|
||||
service pageboostd /system/bin/pageboostd
|
||||
class main
|
||||
user system
|
||||
group system mount radio net_bt sdcard_rw shell media media_rw
|
||||
socket pageboostd seqpacket 0660 system system
|
||||
disabled
|
||||
|
||||
#Enable MGLRU
|
||||
on early-init
|
||||
write /sys/kernel/mm/lru_gen/enabled 7
|
||||
|
||||
# some priv-apps of DSH bind mount to DSA priv-apps
|
||||
on post-fs-data && property:ro.csc.sales_code=DSA
|
||||
umount /system/carrier
|
||||
mkdir /mnt/temp
|
||||
mount none /system/carrier/DSH /mnt/temp bind
|
||||
mount none /system/carrier/DSA /system/carrier bind
|
||||
mount none /mnt/temp/priv-app/VisualVoicemailDsh_Stub /system/carrier/priv-app/VisualVoicemailDsh_Stub bind
|
||||
umount /mnt/temp
|
||||
rmdir /mnt/temp
|
||||
|
||||
# some priv-apps of DSH & DSA bind mount to DSG priv-apps
|
||||
on post-fs-data && property:ro.csc.sales_code=DSG
|
||||
umount /system/carrier
|
||||
mkdir /mnt/temp1
|
||||
mkdir /mnt/temp2
|
||||
mount none /system/carrier/DSH /mnt/temp1 bind
|
||||
mount none /system/carrier/DSA /mnt/temp2 bind
|
||||
mount none /system/carrier/DSG /system/carrier bind
|
||||
mount none /mnt/temp1/priv-app/NetworkCompanion /system/carrier/priv-app/NetworkCompanion bind
|
||||
mount none /mnt/temp1/priv-app/VisualVoicemailDsh_Stub /system/carrier/priv-app/VisualVoicemailDsh_Stub bind
|
||||
mount none /mnt/temp2/priv-app/Opportunistic /system/carrier/priv-app/Opportunistic bind
|
||||
umount /mnt/temp1
|
||||
umount /mnt/temp2
|
||||
rmdir /mnt/temp1
|
||||
rmdir /mnt/temp2
|
||||
|
||||
# some priv-apps of TMB bind mount to ASR priv-apps
|
||||
on post-fs-data && property:ro.csc.sales_code=ASR
|
||||
umount /system/carrier
|
||||
mkdir /mnt/temp
|
||||
mount none /system/carrier/TMB /mnt/temp bind
|
||||
mount none /system/carrier/ASR /system/carrier bind
|
||||
mount none /mnt/temp/priv-app/SprintAndroidExtension2_TMB /system/carrier/priv-app/SprintAndroidExtension2_TMB bind
|
||||
umount /mnt/temp
|
||||
rmdir /mnt/temp
|
||||
|
||||
|
||||
# some priv-apps of TMB bind mount to TMK priv-apps
|
||||
on post-fs-data && property:ro.csc.sales_code=TMK
|
||||
umount /system/carrier
|
||||
mkdir /mnt/temp
|
||||
mount none /system/carrier/TMB /mnt/temp bind
|
||||
mount none /system/carrier/TMK /system/carrier bind
|
||||
mount none /mnt/temp/priv-app/SprintAndroidExtension2_TMB /system/carrier/priv-app/SprintAndroidExtension2_TMB bind
|
||||
umount /mnt/temp
|
||||
rmdir /mnt/temp
|
||||
|
||||
# some priv-apps of DSA bind mount to DSH priv-apps
|
||||
on post-fs-data && property:ro.csc.sales_code=DSH
|
||||
umount /system/carrier
|
||||
mkdir /mnt/temp
|
||||
mount none /system/carrier/DSA /mnt/temp bind
|
||||
mount none /system/carrier/DSH /system/carrier bind
|
||||
mount none /mnt/temp/priv-app/Opportunistic /system/carrier/priv-app/Opportunistic bind
|
||||
umount /mnt/temp
|
||||
rmdir /mnt/temp
|
||||
|
||||
# DCK properties based on target
|
||||
# DigitalKey (Supported Country) : KR,US,GB,DE,FR,IT,ES,AE,CH,KZ,SE,VN,ZA,AU,BR,CA,HK,IN,MY,SG,TW,SA
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=KR
|
||||
setprop ro.gms.dck.eligible_wcc 3
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=US
|
||||
setprop ro.gms.dck.eligible_wcc 3
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=GB
|
||||
setprop ro.gms.dck.eligible_wcc 3
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=GB && property:ro.oem.key2=MET
|
||||
setprop ro.gms.dck.eligible_wcc 0
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=GB && property:ro.oem.key2=VDI
|
||||
setprop ro.gms.dck.eligible_wcc 0
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=GB && property:ro.oem.key2=TSI
|
||||
setprop ro.gms.dck.eligible_wcc 0
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=GB && property:ro.oem.key2=3IE
|
||||
setprop ro.gms.dck.eligible_wcc 0
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=DE
|
||||
setprop ro.gms.dck.eligible_wcc 3
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=FR
|
||||
setprop ro.gms.dck.eligible_wcc 3
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=IT
|
||||
setprop ro.gms.dck.eligible_wcc 3
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=ES
|
||||
setprop ro.gms.dck.eligible_wcc 3
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=AE
|
||||
setprop ro.gms.dck.eligible_wcc 3
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=AE && property:ro.oem.key2=AFR
|
||||
setprop ro.gms.dck.eligible_wcc 0
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=CH
|
||||
setprop ro.gms.dck.eligible_wcc 3
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=KZ
|
||||
setprop ro.gms.dck.eligible_wcc 3
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=SE
|
||||
setprop ro.gms.dck.eligible_wcc 3
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=SE && property:ro.oem.key2=TEN
|
||||
setprop ro.gms.dck.eligible_wcc 0
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=VN
|
||||
setprop ro.gms.dck.eligible_wcc 3
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=VN && property:ro.oem.key2=XEV
|
||||
setprop ro.gms.dck.eligible_wcc 0
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=ZA
|
||||
setprop ro.gms.dck.eligible_wcc 3
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=ZA && property:ro.oem.key2=XFE
|
||||
setprop ro.gms.dck.eligible_wcc 0
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=AU
|
||||
setprop ro.gms.dck.eligible_wcc 3
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=BR
|
||||
setprop ro.gms.dck.eligible_wcc 3
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=CA
|
||||
setprop ro.gms.dck.eligible_wcc 3
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=HK
|
||||
setprop ro.gms.dck.eligible_wcc 3
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=IN
|
||||
setprop ro.gms.dck.eligible_wcc 3
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=MY
|
||||
setprop ro.gms.dck.eligible_wcc 3
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=SG
|
||||
setprop ro.gms.dck.eligible_wcc 3
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=TW
|
||||
setprop ro.gms.dck.eligible_wcc 3
|
||||
on property:sys.boot_completed=1 && property:ro.csc.countryiso_code=SA
|
||||
setprop ro.gms.dck.eligible_wcc 3
|
28
lineage_dm3q.mk
Normal file
28
lineage_dm3q.mk
Normal file
@@ -0,0 +1,28 @@
|
||||
#
|
||||
# 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 the device configuration.
|
||||
$(call inherit-product, device/samsung/dm3q/device.mk)
|
||||
|
||||
# Inherit from the Lineage configuration.
|
||||
$(call inherit-product, vendor/lineage/config/common_full_phone.mk)
|
||||
|
||||
PRODUCT_NAME := lineage_dm3q
|
||||
PRODUCT_DEVICE := dm3q
|
||||
PRODUCT_BRAND := Samsung
|
||||
PRODUCT_MODEL := SM-S918B
|
||||
PRODUCT_MANUFACTURER := Samsung
|
||||
|
||||
PRODUCT_GMS_CLIENTID_BASE := android-samsung
|
||||
|
||||
PRODUCT_BUILD_PROP_OVERRIDES += \
|
||||
PRIVATE_BUILD_DESC="dm3qxxx-user 13 TP1A.220624.014 S918BXXS3AWHR release-keys"
|
||||
|
||||
BUILD_FINGERPRINT := samsung/dm3qxxx/dm3q:13/TP1A.220624.014/S918BXXS3AWHR:user/release-keys
|
10
overlay/FrameworksResDm3q/Android.bp
Normal file
10
overlay/FrameworksResDm3q/Android.bp
Normal file
@@ -0,0 +1,10 @@
|
||||
//
|
||||
// Copyright (C) 2023 The LineageOS Project
|
||||
//
|
||||
// SPDX-License-Identifier: Apache-2.0
|
||||
//
|
||||
|
||||
runtime_resource_overlay {
|
||||
name: "FrameworksResDm3q",
|
||||
device_specific: true,
|
||||
}
|
12
overlay/FrameworksResDm3q/AndroidManifest.xml
Normal file
12
overlay/FrameworksResDm3q/AndroidManifest.xml
Normal file
@@ -0,0 +1,12 @@
|
||||
<!--
|
||||
Copyright (C) 2023 The LineageOS Project
|
||||
SPDX-License-Identifier: Apache-2.0
|
||||
-->
|
||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
package="android.overlay.dm3q">
|
||||
|
||||
<overlay
|
||||
android:isStatic="true"
|
||||
android:priority="700"
|
||||
android:targetPackage="android" />
|
||||
</manifest>
|
1398
overlay/FrameworksResDm3q/res/values/config.xml
Normal file
1398
overlay/FrameworksResDm3q/res/values/config.xml
Normal file
File diff suppressed because it is too large
Load Diff
21
overlay/FrameworksResDm3q/res/values/dimens.xml
Normal file
21
overlay/FrameworksResDm3q/res/values/dimens.xml
Normal file
@@ -0,0 +1,21 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
Copyright (C) 2023 The LineageOS Project
|
||||
SPDX-License-Identifier: Apache-2.0
|
||||
-->
|
||||
<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
|
||||
|
||||
<!-- Height of the status bar in portrait.
|
||||
Do not read this dimen directly. Use {@link SystemBarUtils#getStatusBarHeight} instead.
|
||||
-->
|
||||
<dimen name="status_bar_height_portrait">5.069977mm</dimen>
|
||||
|
||||
<!-- Radius of the software rounded corners at the top of the display in its natural
|
||||
orientation. If zero, the value of rounded_corner_radius is used. -->
|
||||
<dimen name="rounded_corner_radius_top">4.0dip</dimen>
|
||||
|
||||
<!-- Radius of the software rounded corners at the bottom of the display in its natural
|
||||
orientation. If zero, the value of rounded_corner_radius is used. -->
|
||||
<dimen name="rounded_corner_radius_bottom">4.0dip</dimen>
|
||||
|
||||
</resources>
|
180
overlay/FrameworksResDm3q/res/xml/power_profile.xml
Normal file
180
overlay/FrameworksResDm3q/res/xml/power_profile.xml
Normal file
@@ -0,0 +1,180 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<device name="Android">
|
||||
<item name="none">0</item>
|
||||
<item name="ambient.on">19.61</item>
|
||||
<item name="screen.on">63.8</item>
|
||||
<item name="screen.full">276.8</item>
|
||||
<item name="bluetooth.active">0</item>
|
||||
<item name="bluetooth.on">0</item>
|
||||
<item name="wifi.on">0</item>
|
||||
<item name="wifi.active">0</item>
|
||||
<item name="wifi.scan">0</item>
|
||||
<item name="audio">11.4</item>
|
||||
<item name="video">21.75</item>
|
||||
<item name="camera.flashlight">107</item>
|
||||
<item name="camera.avg">287</item>
|
||||
<item name="gps.on">37.9</item>
|
||||
<item name="radio.active">177.02</item>
|
||||
<item name="radio.scanning">92.98</item>
|
||||
<array name="radio.on">
|
||||
<value>8.77</value>
|
||||
<value>8.77</value>
|
||||
</array>
|
||||
<item name="modem.controller.idle">0</item>
|
||||
<item name="modem.controller.rx">0</item>
|
||||
<item name="modem.controller.tx">0</item>
|
||||
<item name="modem.controller.voltage">0</item>
|
||||
<array name="cpu.clusters.cores">
|
||||
<value>3</value>
|
||||
<value>4</value>
|
||||
<value>1</value>
|
||||
</array>
|
||||
<array name="cpu.core_speeds.cluster0">
|
||||
<value>307200</value>
|
||||
<value>441600</value>
|
||||
<value>556800</value>
|
||||
<value>672000</value>
|
||||
<value>787200</value>
|
||||
<value>902400</value>
|
||||
<value>1017600</value>
|
||||
<value>1113600</value>
|
||||
<value>1228800</value>
|
||||
<value>1344000</value>
|
||||
<value>1459200</value>
|
||||
<value>1555200</value>
|
||||
<value>1670400</value>
|
||||
<value>1785600</value>
|
||||
<value>1990800</value>
|
||||
<value>2016000</value>
|
||||
</array>
|
||||
<array name="cpu.core_power.cluster0">
|
||||
<value>14</value>
|
||||
<value>16</value>
|
||||
<value>18</value>
|
||||
<value>20</value>
|
||||
<value>22</value>
|
||||
<value>24</value>
|
||||
<value>28</value>
|
||||
<value>29</value>
|
||||
<value>32</value>
|
||||
<value>35</value>
|
||||
<value>39</value>
|
||||
<value>42</value>
|
||||
<value>46</value>
|
||||
<value>50</value>
|
||||
<value>54</value>
|
||||
<value>60</value>
|
||||
</array>
|
||||
<array name="cpu.core_speeds.cluster1">
|
||||
<value>499200</value>
|
||||
<value>614400</value>
|
||||
<value>729600</value>
|
||||
<value>844800</value>
|
||||
<value>940800</value>
|
||||
<value>1056000</value>
|
||||
<value>1171200</value>
|
||||
<value>1286400</value>
|
||||
<value>1401600</value>
|
||||
<value>1536000</value>
|
||||
<value>1651200</value>
|
||||
<value>1785600</value>
|
||||
<value>1920000</value>
|
||||
<value>2054400</value>
|
||||
<value>2188800</value>
|
||||
<value>2323200</value>
|
||||
<value>2457600</value>
|
||||
<value>2592000</value>
|
||||
<value>2707200</value>
|
||||
<value>2803200</value>
|
||||
</array>
|
||||
<array name="cpu.core_power.cluster1">
|
||||
<value>28</value>
|
||||
<value>33</value>
|
||||
<value>39</value>
|
||||
<value>45</value>
|
||||
<value>49</value>
|
||||
<value>57</value>
|
||||
<value>64</value>
|
||||
<value>72</value>
|
||||
<value>80</value>
|
||||
<value>91</value>
|
||||
<value>101</value>
|
||||
<value>120</value>
|
||||
<value>133</value>
|
||||
<value>153</value>
|
||||
<value>178</value>
|
||||
<value>202</value>
|
||||
<value>238</value>
|
||||
<value>277</value>
|
||||
<value>321</value>
|
||||
<value>321</value>
|
||||
</array>
|
||||
<array name="cpu.core_speeds.cluster2">
|
||||
<value>595200</value>
|
||||
<value>729600</value>
|
||||
<value>86400</value>
|
||||
<value>998400</value>
|
||||
<value>1132800</value>
|
||||
<value>1248000</value>
|
||||
<value>1363200</value>
|
||||
<value>1478400</value>
|
||||
<value>1593600</value>
|
||||
<value>1708800</value>
|
||||
<value>1843200</value>
|
||||
<value>1977600</value>
|
||||
<value>2092800</value>
|
||||
<value>2227200</value>
|
||||
<value>2342400</value>
|
||||
<value>2476800</value>
|
||||
<value>2592000</value>
|
||||
<value>2726400</value>
|
||||
<value>2841600</value>
|
||||
<value>2956800</value>
|
||||
<value>3360000</value>
|
||||
</array>
|
||||
<array name="cpu.core_power.cluster2">
|
||||
<value>80</value>
|
||||
<value>92</value>
|
||||
<value>109</value>
|
||||
<value>122</value>
|
||||
<value>139</value>
|
||||
<value>157</value>
|
||||
<value>171</value>
|
||||
<value>188</value>
|
||||
<value>205</value>
|
||||
<value>224</value>
|
||||
<value>249</value>
|
||||
<value>281</value>
|
||||
<value>334</value>
|
||||
<value>374</value>
|
||||
<value>404</value>
|
||||
<value>460</value>
|
||||
<value>500</value>
|
||||
<value>560</value>
|
||||
<value>614</value>
|
||||
<value>715</value>
|
||||
<value>1139</value>
|
||||
</array>
|
||||
<item name="cpu.suspend">7.7</item>
|
||||
<item name="cpu.idle">19.6</item>
|
||||
<item name="battery.capacity">4855</item>
|
||||
<item name="battery.typical.capacity">5000</item>
|
||||
<item name="bluetooth.controller.idle">3.5</item>
|
||||
<item name="bluetooth.controller.rx">12</item>
|
||||
<item name="bluetooth.controller.tx">33</item>
|
||||
<item name="bluetooth.controller.voltage">4000</item>
|
||||
<item name="wifi.controller.idle">1</item>
|
||||
<item name="wifi.controller.rx">120</item>
|
||||
<item name="wifi.controller.tx">300</item>
|
||||
<array name="wifi.controller.tx_levels">
|
||||
<value>0</value>
|
||||
</array>
|
||||
<item name="wifi.controller.voltage">4000</item>
|
||||
<array name="wifi.batchedscan">
|
||||
<value>.0002</value>
|
||||
<value>.002</value>
|
||||
<value>.02</value>
|
||||
<value>.2</value>
|
||||
<value>2</value>
|
||||
</array>
|
||||
</device>
|
204
proprietary-files.txt
Normal file
204
proprietary-files.txt
Normal file
@@ -0,0 +1,204 @@
|
||||
# All unpinned blobs are extracted from S918BXXS3AWHR
|
||||
|
||||
# ACDB
|
||||
vendor/etc/audconf/OPEN/acdb_cal.acdb
|
||||
vendor/etc/audconf/OPEN/workspaceFileXml.qwsp
|
||||
|
||||
# Audio configs
|
||||
vendor/etc/audio/sku_kalama/mixer_paths.xml
|
||||
vendor/etc/dolby/dax-default.xml
|
||||
|
||||
# Bluetooth firmware
|
||||
vendor/firmware/bt_nvm_loading.xml
|
||||
|
||||
# Camera
|
||||
vendor/lib64/camera/com.samsung.ois.mcu_stm32g.so
|
||||
vendor/lib64/camera/com.samsung.sensormodule.0_lsi_s5khp2.bin
|
||||
vendor/lib64/camera/com.samsung.sensormodule.12_lsi_s5k3lu_full.bin
|
||||
vendor/lib64/camera/com.samsung.sensormodule.1_lsi_s5k3lu.bin
|
||||
vendor/lib64/camera/com.samsung.sensormodule.2_sony_imx564.bin
|
||||
vendor/lib64/camera/com.samsung.sensormodule.3_sony_imx754_x3.bin
|
||||
vendor/lib64/camera/com.samsung.sensormodule.6_sony_imx754_x10.bin
|
||||
vendor/lib64/camera/com.samsung.tuned.lsi_s5khp2.bin
|
||||
vendor/lib64/camera/com.samsung.tuned.sony_imx754_x10.bin
|
||||
vendor/lib64/camera/com.samsung.tuned.sony_imx754_x3.bin
|
||||
vendor/lib64/camera/components/com.qti.eisv2.so
|
||||
vendor/lib64/camera/components/com.qti.eisv3.so
|
||||
vendor/lib64/camera/components/com.qti.hvx.addconstant.so
|
||||
vendor/lib64/camera/components/com.qti.hvx.binning.so
|
||||
vendor/lib64/camera/components/com.qti.node.afbfusion.so
|
||||
vendor/lib64/camera/components/com.qti.node.aon.so
|
||||
vendor/lib64/camera/components/com.qti.node.customhwnode.so
|
||||
vendor/lib64/camera/components/com.qti.node.depth.so
|
||||
vendor/lib64/camera/components/com.qti.node.depthprovider.so
|
||||
vendor/lib64/camera/components/com.qti.node.dewarp.so
|
||||
vendor/lib64/camera/components/com.qti.node.dummydepth.so
|
||||
vendor/lib64/camera/components/com.qti.node.dummyrtb.so
|
||||
vendor/lib64/camera/components/com.qti.node.dummysat.so
|
||||
vendor/lib64/camera/components/com.qti.node.eisv2.so
|
||||
vendor/lib64/camera/components/com.qti.node.eisv3.so
|
||||
vendor/lib64/camera/components/com.qti.node.fcv.so
|
||||
vendor/lib64/camera/components/com.qti.node.formatconversion.so
|
||||
vendor/lib64/camera/components/com.qti.node.gme.so
|
||||
vendor/lib64/camera/components/com.qti.node.gpu.so
|
||||
vendor/lib64/camera/components/com.qti.node.gyrornn.so
|
||||
vendor/lib64/camera/components/com.qti.node.hdr10pgen.so
|
||||
vendor/lib64/camera/components/com.qti.node.hdr10phist.so
|
||||
vendor/lib64/camera/components/com.qti.node.memcpy.so
|
||||
vendor/lib64/camera/components/com.qti.node.ml.so
|
||||
vendor/lib64/camera/components/com.qti.node.muxer.so
|
||||
vendor/lib64/camera/components/com.qti.node.remosaic.so
|
||||
vendor/lib64/camera/components/com.qti.node.seg.so
|
||||
vendor/lib64/camera/components/com.qti.node.stich.so
|
||||
vendor/lib64/camera/components/com.qti.node.swaidenoiser.so
|
||||
vendor/lib64/camera/components/com.qti.node.swbestats.so
|
||||
vendor/lib64/camera/components/com.qti.node.swcac.so
|
||||
vendor/lib64/camera/components/com.qti.node.swec.so
|
||||
vendor/lib64/camera/components/com.qti.node.swfusion.so
|
||||
vendor/lib64/camera/components/com.qti.node.swhme.so
|
||||
vendor/lib64/camera/components/com.qti.node.swlsc.so
|
||||
vendor/lib64/camera/components/com.qti.node.swmctf.so
|
||||
vendor/lib64/camera/components/com.qti.node.swpdpc.so
|
||||
vendor/lib64/camera/components/com.qti.node.swpreprocess.so
|
||||
vendor/lib64/camera/components/com.qti.node.swregistration.so
|
||||
vendor/lib64/camera/components/com.qti.node.swvrt.so
|
||||
vendor/lib64/camera/components/com.qti.stats.aecxcore.so
|
||||
vendor/lib64/camera/components/com.qti.stats.af.so
|
||||
vendor/lib64/camera/components/com.qti.stats.afd.so
|
||||
vendor/lib64/camera/components/com.qti.stats.afwrapper.so
|
||||
vendor/lib64/camera/components/com.qti.stats.asd.so
|
||||
vendor/lib64/camera/components/com.qti.stats.awb.so
|
||||
vendor/lib64/camera/components/com.qti.stats.awbwrapper.so
|
||||
vendor/lib64/camera/components/com.qti.stats.cnndriver.so
|
||||
vendor/lib64/camera/components/com.qti.stats.haf.so
|
||||
vendor/lib64/camera/components/com.qti.stats.hafoverride.so
|
||||
vendor/lib64/camera/components/com.qti.stats.localhistogram.so
|
||||
vendor/lib64/camera/components/com.qti.stats.pdlib.so
|
||||
vendor/lib64/camera/components/com.qti.stats.pdlibsony.so
|
||||
vendor/lib64/camera/components/com.qti.stats.pdlibwrapper.so
|
||||
vendor/lib64/camera/components/com.qti.stats.statsgenerator.so
|
||||
vendor/lib64/camera/components/com.qti.stats.tracker.so
|
||||
vendor/lib64/camera/components/com.qtistatic.stats.af.so
|
||||
vendor/lib64/camera/components/com.qtistatic.stats.awb.so
|
||||
vendor/lib64/camera/components/com.qtistatic.stats.pdlib.so
|
||||
vendor/lib64/camera/components/com.samsung.node.capture_fusion.so
|
||||
vendor/lib64/camera/components/com.samsung.node.realtimebokeh.so
|
||||
vendor/lib64/camera/components/com.samsung.node.resolution.so
|
||||
vendor/lib64/camera/components/com.samsung.node.smooth_transition.so
|
||||
vendor/lib64/camera/components/com.samsung.node.uniplugin_capture.so
|
||||
vendor/lib64/camera/components/com.samsung.node.uniplugin_preview.so
|
||||
vendor/lib64/camera/components/com.samsung.node.uniplugin_recording.so
|
||||
vendor/lib64/camera/components/com.samsung.node.uniplugin_vdis.so
|
||||
vendor/lib64/camera/components/com.ss.stats.aec.so
|
||||
vendor/lib64/camera/components/com.ss.stats.af.so
|
||||
vendor/lib64/camera/components/com.ss.stats.awb.so
|
||||
vendor/lib64/camera/components/com.ss.stats.pdlib.so
|
||||
vendor/lib64/camera/components/libTsAeFront_dm3.so
|
||||
vendor/lib64/camera/components/libTsAe_dm3.so
|
||||
vendor/lib64/camera/components/libdepthmapwrapper_secure.so
|
||||
vendor/lib64/camera/t_t10_dual_calibration.bin
|
||||
vendor/lib64/camera/uw_dual_calibration.bin
|
||||
vendor/lib64/camera/w_dual_calibration.bin
|
||||
vendor/lib64/com.qti.camx.chiiqutils.so
|
||||
vendor/lib64/com.qti.feature2.afbrckt.so
|
||||
vendor/lib64/com.qti.feature2.anchorsync.so
|
||||
vendor/lib64/com.qti.feature2.demux.so
|
||||
vendor/lib64/com.qti.feature2.derivedoffline.so
|
||||
vendor/lib64/com.qti.feature2.frameselect.so
|
||||
vendor/lib64/com.qti.feature2.fusion.so
|
||||
vendor/lib64/com.qti.feature2.generic.so
|
||||
vendor/lib64/com.qti.feature2.gs.sm8550.so
|
||||
vendor/lib64/com.qti.feature2.hdr.so
|
||||
vendor/lib64/com.qti.feature2.mcreprocrt.so
|
||||
vendor/lib64/com.qti.feature2.memcpy.so
|
||||
vendor/lib64/com.qti.feature2.mfsr.so
|
||||
vendor/lib64/com.qti.feature2.ml.so
|
||||
vendor/lib64/com.qti.feature2.mux.so
|
||||
vendor/lib64/com.qti.feature2.qcfa.so
|
||||
vendor/lib64/com.qti.feature2.rawhdr.so
|
||||
vendor/lib64/com.qti.feature2.realtimeserializer.so
|
||||
vendor/lib64/com.qti.feature2.rt.so
|
||||
vendor/lib64/com.qti.feature2.rtmcx.so
|
||||
vendor/lib64/com.qti.feature2.serializer.so
|
||||
vendor/lib64/com.qti.feature2.statsregeneration.so
|
||||
vendor/lib64/com.qti.feature2.stub.so
|
||||
vendor/lib64/com.qti.feature2.swmf.so
|
||||
vendor/lib64/com.qualcomm.mcx.linearmapper.so
|
||||
vendor/lib64/com.qualcomm.mcx.nonlinearmapper.so
|
||||
vendor/lib64/com.qualcomm.mcx.policy.mfl.so
|
||||
vendor/lib64/com.qualcomm.mcx.policy.xr.so
|
||||
vendor/lib64/com.qualcomm.qti.mcx.usecase.extension.so
|
||||
vendor/lib64/hw/camera.qcom.so
|
||||
vendor/lib64/hw/com.qti.chi.offline.so
|
||||
vendor/lib64/hw/com.qti.chi.override.so
|
||||
vendor/lib64/libPdSdCore.so
|
||||
vendor/lib64/libSWB.camera.samsung.so
|
||||
vendor/lib64/libTsAwbFront_DM3.so
|
||||
vendor/lib64/libTsAwb_DM3.so
|
||||
vendor/lib64/libcamerapostproc.so
|
||||
vendor/lib64/libcamxcommonutils.so
|
||||
vendor/lib64/libcamxexternalformatutils.so
|
||||
vendor/lib64/libcamximageformatutils.so
|
||||
vendor/lib64/libcamxsettingsmanager.so
|
||||
vendor/lib64/libcamxswispiqmodule.so
|
||||
vendor/lib64/libchifeature2.so
|
||||
vendor/lib64/libcom.qti.chinodeutils.so
|
||||
vendor/lib64/libmulticam_image_optical_zoom.so
|
||||
vendor/lib64/libmulticam_optical_zoom_control.so
|
||||
vendor/lib64/libmulticam_video_optical_zoom.so
|
||||
vendor/lib64/libswb_interface.so
|
||||
|
||||
# Camera firmware
|
||||
vendor/firmware/ois_mcu_stm32g_fw.bin
|
||||
|
||||
# Display calibration data
|
||||
vendor/etc/display/qdcm_calib_data_DM3_S6E3HAE_AMB681AZ01.json
|
||||
vendor/firmware/DM3_S6E3HAE_AMB681AZ01.dat
|
||||
|
||||
# NFC
|
||||
vendor/etc/nfc/libnfc-nxp_RF.conf
|
||||
|
||||
# RIL
|
||||
vendor/etc/init/init.vendor.onebinary.rc
|
||||
|
||||
# Sensors config
|
||||
vendor/etc/sensors/config/kailua_ak991x_1.json
|
||||
vendor/etc/sensors/config/kailua_ak991x_2.json
|
||||
vendor/etc/sensors/config/kailua_ak991x_3.json
|
||||
vendor/etc/sensors/config/kailua_ak991x_8.json
|
||||
vendor/etc/sensors/config/kailua_lsm6dso_0_1.json
|
||||
vendor/etc/sensors/config/kailua_lsm6dso_0_8.json
|
||||
vendor/etc/sensors/config/kailua_stk3a9x_0.json
|
||||
vendor/etc/sensors/config/kailua_tmd4913_2.json
|
||||
|
||||
# Sensors
|
||||
vendor/bin/factory.ssc
|
||||
vendor/lib64/sensors.flicker.so
|
||||
vendor/lib64/sensors.grip.so
|
||||
vendor/lib64/sensors.ssc.so
|
||||
|
||||
# Touchscreen firmware
|
||||
vendor/firmware/tsp_stm/fts2ba61y_dm3q.bin
|
||||
|
||||
# Vendor firmware
|
||||
vendor/firmware/00_generic_xtalk_shape.bin
|
||||
vendor/firmware/hmtnv20.b21
|
||||
vendor/firmware/vl53l8.bin
|
||||
vendor/firmware/wez02_dm3_c0.bin
|
||||
vendor/firmware/wez02_dm3_c1.bin
|
||||
vendor/firmware/wez02_dm3_c2.bin
|
||||
vendor/firmware/wez02_dm3_c3.bin
|
||||
|
||||
# Wifi firmware
|
||||
vendor/firmware/Data.msc
|
||||
vendor/firmware/kiwi/amss20.bin
|
||||
vendor/firmware/kiwi/bdwlan.elf
|
||||
vendor/firmware/kiwi/bdwlan.elf1
|
||||
vendor/firmware/kiwi/bdwlan.elf10
|
||||
vendor/firmware/kiwi/bdwlan.elf2
|
||||
vendor/firmware/kiwi/phy_ucode20.elf
|
||||
vendor/firmware/kiwi/qdss_trace_config_v2.cfg
|
||||
vendor/firmware/kiwi/regdb.bin
|
||||
|
||||
# WiFi
|
||||
vendor/etc/wifi/kiwi_v2/WCNSS_qcom_cfg.ini
|
16
setup-makefiles.sh
Executable file
16
setup-makefiles.sh
Executable file
@@ -0,0 +1,16 @@
|
||||
#!/bin/bash
|
||||
#
|
||||
# Copyright (C) 2016 The CyanogenMod Project
|
||||
# Copyright (C) 2017-2020 The LineageOS Project
|
||||
#
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
#
|
||||
|
||||
set -e
|
||||
|
||||
export DEVICE=dm3q
|
||||
export DEVICE_COMMON=sm8550-common
|
||||
export VENDOR=samsung
|
||||
export VENDOR_COMMON=${VENDOR}
|
||||
|
||||
"./../../${VENDOR_COMMON}/${DEVICE_COMMON}/setup-makefiles.sh" "$@"
|
46
sort-blobs-list.py
Executable file
46
sort-blobs-list.py
Executable file
@@ -0,0 +1,46 @@
|
||||
#!/usr/bin/env python3
|
||||
#
|
||||
# Copyright (C) 2021-2022 The LineageOS Project
|
||||
#
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
#
|
||||
|
||||
import re, sys
|
||||
from functools import cmp_to_key
|
||||
from locale import LC_ALL, setlocale, strcoll
|
||||
from pathlib import Path
|
||||
|
||||
|
||||
def strcoll_extract_utils(string1: str, string2: str) -> int:
|
||||
# Skip logic if one of the string if empty
|
||||
if not string1 or not string2:
|
||||
return strcoll(string1, string2)
|
||||
|
||||
# Remove '-' from strings if there,
|
||||
# it is used to indicate a build target
|
||||
string1 = re.sub("^-", "", string1)
|
||||
string2 = re.sub("^-", "", string2)
|
||||
|
||||
# Compare normally
|
||||
return strcoll(string1, string2)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
setlocale(LC_ALL, "C")
|
||||
|
||||
for file in sys.argv[1:] or ["proprietary-files.txt"]:
|
||||
if not Path(file).is_file():
|
||||
print(f"File {file} not found")
|
||||
continue
|
||||
|
||||
with open(file, "r") as f:
|
||||
sections = f.read().split("\n\n")
|
||||
|
||||
ordered_sections = []
|
||||
for section in sections:
|
||||
section_list = [line.strip() for line in section.splitlines()]
|
||||
section_list.sort(key=cmp_to_key(strcoll_extract_utils))
|
||||
ordered_sections.append("\n".join(section_list))
|
||||
|
||||
with open(file, "w") as f:
|
||||
f.write("\n\n".join(ordered_sections).strip() + "\n")
|
Reference in New Issue
Block a user