diff --git a/LeOS/instrumentation_test_list.mk b/LeOS/instrumentation_test_list.mk
new file mode 100644
index 00000000..1a9d6fdf
--- /dev/null
+++ b/LeOS/instrumentation_test_list.mk
@@ -0,0 +1,103 @@
+# Copyright (C) 2016 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.
+
+instrumentation_tests := \
+ HelloWorldTests \
+ BluetoothInstrumentationTests \
+ LongevityPlatformLibTests \
+ ManagedProvisioningTests \
+ FrameworksCoreTests \
+ FrameworksCoreGameManagerTests \
+ FrameworksMockingCoreTests \
+ BinderProxyCountingTestApp \
+ BinderProxyCountingTestService \
+ FrameworksNetTests \
+ FrameworksUiServicesTests \
+ BstatsTestApp \
+ FrameworksServicesTests \
+ FrameworksMockingServicesTests \
+ WmTests \
+ WmPerfTests \
+ DisplayServiceTests \
+ JobTestApp \
+ SuspendTestApp \
+ FrameworksUtilTests \
+ MtpServiceTests \
+ MtpTests \
+ DocumentsUITests \
+ ShellTests \
+ SystemUITests \
+ TestablesTests \
+ FrameworksWifiApiTests \
+ FrameworksWifiNonUpdatableApiTests \
+ FrameworksWifiTests \
+ FrameworksTelephonyTests \
+ ContactsProviderTests \
+ SettingsUnitTests \
+ TelecomUnitTests \
+ TraceurUiTests \
+ AndroidVCardTests \
+ PermissionFunctionalTests \
+ BlockedNumberProviderTest \
+ DownloadAppFunctionalTests \
+ NotificationFunctionalTests \
+ DynamicCodeLoggerIntegrationTests \
+ UsbTests \
+ DownloadProviderTests \
+ CalendarProviderTests \
+ SettingsLibTests \
+ RSTest \
+ PrintSpoolerOutOfProcessTests \
+ CellBroadcastReceiverUnitTests \
+ CellBroadcastServiceTests \
+ TelephonyProviderTests \
+ CarrierConfigTests \
+ TeleServiceTests \
+ PresencePollingTests \
+ ImsCommonTests \
+ SettingsProviderTest \
+ FrameworksPrivacyLibraryTests \
+ SettingsUITests \
+ SettingsPerfTests \
+ ExtServicesUnitTests \
+ FrameworksNetSmokeTests \
+ FlickerLibTest \
+ FlickerTestsOther \
+ FlickerTestsAppClose \
+ FlickerTestsIme \
+ FlickerTestsAppLaunch \
+ FlickerTestsQuickswitch \
+ FlickerTestsRotation \
+ FlickerTestApp \
+ WMShellFlickerTestsOther \
+ WMShellFlickerTestsBubbles \
+ WMShellFlickerTestsPip \
+ WMShellFlickerTestsSplitScreen \
+ trace_config_detailed.textproto \
+ perfetto_trace_processor_shell \
+ CarDeveloperOptionsUnitTests \
+ SpaPrivilegedLibTests \
+ SettingsSpaUnitTests \
+ SpaLibTests
+
+ifneq ($(strip $(BOARD_PERFSETUP_SCRIPT)),)
+instrumentation_tests += perf-setup
+endif
+
+# Storage Manager may not exist on device
+ifneq ($(filter StorageManager, $(PRODUCT_PACKAGES)),)
+
+instrumentation_tests += StorageManagerUnitTests
+
+endif
diff --git a/LeOS/remove.xml b/LeOS/remove.xml
new file mode 100644
index 00000000..c9478f7b
--- /dev/null
+++ b/LeOS/remove.xml
@@ -0,0 +1,75 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/build-u.sh b/build-u.sh
index 135542d4..08ac6706 100644
--- a/build-u.sh
+++ b/build-u.sh
@@ -10,11 +10,17 @@ echo " harvey186 "
echo "--------------------------------------"
echo
-git clone http://62.178.96.192:3000/JoJo/LeOS-GSI.git -b LeOS-U --git-lfs
+#git clone http://62.178.96.192:3000/JoJo/LeOS-GSI.git -b LeOS-U
+
+##### only for testing ###
+sudo rm -R treble_aosp
+###-
+
git clone https://github.com/ponces/treble_aosp -b android-14.0
+cp LeOS/patch.sh treble_aosp/patch.sh
-git clone https://github.com/ponces/vendor_ponces.git -b android-14.0 vendor/ponces
+#git clone https://github.com/ponces/vendor_ponces.git -b android-14.0 vendor/ponces
set -e
@@ -46,26 +52,28 @@ applyPatches() {
echo "--> Applying ponces personal patches"
rm treble_aosp/patches/personal/platform_frameworks_base/0001-gmscompat-Change-attestation-and-instrumentation-to-.patch
- rm treble_aosp/patches/personal/platform_packages_apps_Trebuchet/0001-Revert-Add-support-for-toggling-taskbar.patch
+ rm treble_aosp/patches/personal/platform_frameworks_base/0002-gmscompat-Spoof-Pixel-XL-for-Google-Photos.patch
rm treble_aosp/patches/personal/platform_frameworks_base/0003-monet-Use-Style.SPRITZ-by-default.patch
rm treble_aosp/patches/personal/platform_frameworks_base/0004-fw-b-Use-ro.build.version.incremental-to-signal-OTA-.patch
+ rm treble_aosp/patches/personal/platform_frameworks_base/0005-SystemUI-fix-SliceView-layout.patch
rm treble_aosp/patches/personal/platform_frameworks_base/0006-Add-android.permission.READ_PHONE_STATE-to-manifest.patch
- rm /home/ich/src/LeOS-GSI/treble_aosp/patches/personal/platform_frameworks_base/0005-SystemUI-fix-SliceView-layout.patch
- rm -R treble_aosp/patches/personal/device_phh/treble
- rm -R treble_aosp/patches/personal/platform_build
- rm treble_aosp/patches/personal/platform_frameworks_base/0002-gmscompat-Spoof-Pixel-XL-for-Google-Photos.patch
rm treble_aosp/patches/personal/platform_frameworks_base/0007-permissions-Pre-grant-google-restore-permissions.patch
- rm -R treble_aosp/patches/personal/platform_frameworks_base/0008-feat-Add-Lockscreen-Weather-with-OmniJaws-1-2.patch
+ rm -R treble_aosp/patches/personal/platform_frameworks_base/0008-feat-Add-Lockscreen-Weather-with-OmniJaws-1-2.patch
+ rm -R treble_aosp/patches/personal/device_phh_treble
+ rm -R treble_aosp/patches/personal/platform_build
+ rm -R treble_aosp/patches/personal/platform_packages_apps_Trebuchet
+ rm -R treble_aosp/patches/personal/platform_packages_apps_Aperture
rm -R treble_aosp/patches/personal/platform_packages_apps_Settings/0001-feat-Add-Lockscreen-Weather-with-OmniJaws-2-2.patch
- rm treble_aosp/patches/personal/platform_build/0001-Remove-su-from-vanilla-builds.patch
bash treble_aosp/patch.sh treble_aosp personal
echo
echo "--> Applying LeOS patches"
- mv patches/leos treble_aosp/patches/leos
+ cp -R patches/leos treble_aosp/patches/leos
bash treble_aosp/patch.sh treble_aosp leos
+ echo "testlists"
cp LeOS/instrumentation_test_list.mk platform_testing/build/tasks/tests/
cp LeOS/platform_test_list.mk platform_testing/build/tasks/tests/
+ echo "texte"
cp LeOS/texte.sh .
bash texte.sh
echo
@@ -179,13 +187,13 @@ echo "READY"
START=$(date +%s)
-#initRepos
-#syncRepos
-#applyPatches
+initRepos
+syncRepos
+applyPatches
#setupEnv
#buildTrebleApp
-buildVanillaVariant
-generatePackages
+#buildVanillaVariant
+#generatePackages
END=$(date +%s)
ELAPSEDM=$(($(($END-$START))/60))
diff --git a/patches/leos/platform_device_phh_treble/0001-LeOS-Stuff.patch b/patches/leos/platform_device_phh_treble/0001-LeOS-Stuff.patch
deleted file mode 100644
index 900980f1..00000000
--- a/patches/leos/platform_device_phh_treble/0001-LeOS-Stuff.patch
+++ /dev/null
@@ -1,164 +0,0 @@
-From d5f70e02277ae0389693651b7d62ac5dcb1ea9d6 Mon Sep 17 00:00:00 2001
-From: harvey186
-Date: Mon, 11 Dec 2023 17:20:55 +0100
-Subject: [PATCH] LeOS-Stuff
-
----
- generate.sh | 31 +++++--------------
- {tdgsi_a64_ab => leos_a64_ab}/BoardConfig.mk | 0
- .../BoardConfig.mk | 0
- tdgsi_a64_a/BoardConfig.mk | 8 -----
- tdgsi_arm64_a/BoardConfig.mk | 7 -----
- tdgsi_arm_a/BoardConfig.mk | 11 -------
- tdgsi_arm_ab/BoardConfig.mk | 7 -----
- 7 files changed, 8 insertions(+), 56 deletions(-)
- rename {tdgsi_a64_ab => leos_a64_ab}/BoardConfig.mk (100%)
- rename {tdgsi_arm64_ab => leos_arm64_ab}/BoardConfig.mk (100%)
- delete mode 100644 tdgsi_a64_a/BoardConfig.mk
- delete mode 100644 tdgsi_arm64_a/BoardConfig.mk
- delete mode 100644 tdgsi_arm_a/BoardConfig.mk
- delete mode 100644 tdgsi_arm_ab/BoardConfig.mk
-
-diff --git a/generate.sh b/generate.sh
-index 8fbb16b..ffad809 100644
---- a/generate.sh
-+++ b/generate.sh
-@@ -15,8 +15,8 @@ fi
- echo 'PRODUCT_MAKEFILES := \' > AndroidProducts.mk
-
- for part in a ab;do
-- for apps in vanilla gapps foss gapps-go;do
-- for arch in arm64 arm a64;do
-+ for apps in vanilla;do
-+ for arch in arm64 a64;do
- for su in yes no;do
- apps_suffix=""
- apps_script=""
-@@ -24,29 +24,13 @@ for part in a ab;do
- extra_packages=""
- vndk="vndk.mk"
- optional_base=""
-- if [ "$apps" == "gapps" ];then
-- apps_suffix="g"
-- apps_script='$(call inherit-product, vendor/gapps/common/common-vendor.mk)'
-- apps_name="with GApps"
-- fi
-- if [ "$apps" == "gapps-go" ];then
-- apps_suffix="o"
-- apps_script='$(call inherit-product, device/phh/treble/gapps-go.mk)'
-- apps_name="Go"
-- fi
-- if [ "$apps" == "foss" ];then
-- apps_suffix="f"
-- apps_script='$(call inherit-product, vendor/foss/foss.mk)'
-- apps_name="with FOSS apps"
-- fi
-+
- if [ "$apps" == "vanilla" ];then
- apps_suffix="v"
- apps_script=''
- apps_name="vanilla"
- fi
-- if [ "$arch" == "arm" ];then
-- vndk="vndk-binder32.mk"
-- fi
-+
- if [ "$arch" == "a64" ];then
- vndk="vndk32.mk"
- fi
-@@ -64,7 +48,7 @@ for part in a ab;do
- optional_base='$(call inherit-product, device/phh/treble/base-sas.mk)'
- fi
-
-- target="treble_${arch}_${part_suffix}${apps_suffix}${su_suffix}"
-+ target="leos${arch}_${part_suffix}${apps_suffix}${su_suffix}"
-
- baseArch="$arch"
- if [ "$arch" = "a64" ];then
-@@ -81,15 +65,16 @@ TARGET_GAPPS_ARCH := ${baseArch}
- \$(call inherit-product, device/phh/treble/base-pre.mk)
- include build/make/target/product/aosp_${baseArch}.mk
- \$(call inherit-product, device/phh/treble/base.mk)
-+\$(call inherit-product, vendor/LeOS/leos.mk)
- $optional_base
- $apps_script
- $rom_script
-
- PRODUCT_NAME := $target
--PRODUCT_DEVICE := tdgsi_${arch}_$part
-+PRODUCT_DEVICE := leos_${arch}_$part
- PRODUCT_BRAND := google
- PRODUCT_SYSTEM_BRAND := google
--PRODUCT_MODEL := TrebleDroid $apps_name
-+PRODUCT_MODEL := LeOS-A14
-
- # Overwrite the inherited "emulator" characteristics
- PRODUCT_CHARACTERISTICS := device
-diff --git a/tdgsi_a64_ab/BoardConfig.mk b/leos_a64_ab/BoardConfig.mk
-similarity index 100%
-rename from tdgsi_a64_ab/BoardConfig.mk
-rename to leos_a64_ab/BoardConfig.mk
-diff --git a/tdgsi_arm64_ab/BoardConfig.mk b/leos_arm64_ab/BoardConfig.mk
-similarity index 100%
-rename from tdgsi_arm64_ab/BoardConfig.mk
-rename to leos_arm64_ab/BoardConfig.mk
-diff --git a/tdgsi_a64_a/BoardConfig.mk b/tdgsi_a64_a/BoardConfig.mk
-deleted file mode 100644
-index d430bf8..0000000
---- a/tdgsi_a64_a/BoardConfig.mk
-+++ /dev/null
-@@ -1,8 +0,0 @@
--include build/make/target/board/generic_arm_ab/BoardConfig.mk
--include device/phh/treble/board-base.mk
--
--ifeq ($(BOARD_SYSTEMIMAGE_PARTITION_RESERVED_SIZE),)
--BOARD_SYSTEMIMAGE_PARTITION_SIZE := 1572864000
--endif
--TARGET_USES_64_BIT_BINDER := true
--BOARD_SYSTEMIMAGE_AS_SYSTEM := true
-diff --git a/tdgsi_arm64_a/BoardConfig.mk b/tdgsi_arm64_a/BoardConfig.mk
-deleted file mode 100644
-index c9bc831..0000000
---- a/tdgsi_arm64_a/BoardConfig.mk
-+++ /dev/null
-@@ -1,7 +0,0 @@
--include build/make/target/board/generic_arm64_ab/BoardConfig.mk
--include device/phh/treble/board-base.mk
--
--ifeq ($(BOARD_SYSTEMIMAGE_PARTITION_RESERVED_SIZE),)
--BOARD_SYSTEMIMAGE_PARTITION_SIZE := 2080374784
--endif
--BOARD_SYSTEMIMAGE_AS_SYSTEM := true
-diff --git a/tdgsi_arm_a/BoardConfig.mk b/tdgsi_arm_a/BoardConfig.mk
-deleted file mode 100644
-index 7340fc4..0000000
---- a/tdgsi_arm_a/BoardConfig.mk
-+++ /dev/null
-@@ -1,11 +0,0 @@
--include build/make/target/board/generic_arm_ab/BoardConfig.mk
--include device/phh/treble/board-base.mk
--
--ifeq ($(BOARD_SYSTEMIMAGE_PARTITION_RESERVED_SIZE),)
--BOARD_SYSTEMIMAGE_PARTITION_SIZE := 1313583104
--else
--BOARD_SYSTEMIMAGE_PARTITION_RESERVED_SIZE := 25165824
--endif
--
--TARGET_USES_64_BIT_BINDER := false
--BOARD_SYSTEMIMAGE_AS_SYSTEM := true
-diff --git a/tdgsi_arm_ab/BoardConfig.mk b/tdgsi_arm_ab/BoardConfig.mk
-deleted file mode 100644
-index a9a4fe3..0000000
---- a/tdgsi_arm_ab/BoardConfig.mk
-+++ /dev/null
-@@ -1,7 +0,0 @@
--include build/make/target/board/generic_arm_ab/BoardConfig.mk
--include device/phh/treble/board-base.mk
--
--ifeq ($(BOARD_SYSTEMIMAGE_PARTITION_RESERVED_SIZE),)
--BOARD_SYSTEMIMAGE_PARTITION_SIZE := 1073741824
--endif
--TARGET_USES_64_BIT_BINDER := false
---
-2.34.1
-
diff --git a/patches/leos/platform_device_phh_treble/0001-adb_secure.patch b/patches/leos/platform_device_phh_treble/0001-adb_secure.patch
deleted file mode 100644
index 497edeb3..00000000
--- a/patches/leos/platform_device_phh_treble/0001-adb_secure.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From a926ba87b4a39f1c773a6de566094e0ff8a7638f Mon Sep 17 00:00:00 2001
-From: harvey186
-Date: Mon, 8 Jan 2024 10:07:07 +0100
-Subject: [PATCH] adb_secure
-
----
- rw-system.sh | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/rw-system.sh b/rw-system.sh
-index fdd47ae..867a954 100644
---- a/rw-system.sh
-+++ b/rw-system.sh
-@@ -827,7 +827,7 @@ copyprop() {
- resetprop_phh ro.build.type user
- resetprop_phh ro.build.selinux 0
-
-- resetprop_phh ro.adb.secure 1
-+ resetprop_phh ro.adb.secure 0
-
- for abi in "" 64;do
- f=/vendor/lib$abi/libstagefright_foundation.so
---
-2.34.1
-
diff --git a/patches/leos/platform_device_phh_treble/0001-generate_sh.patch b/patches/leos/platform_device_phh_treble/0001-generate_sh.patch
new file mode 100644
index 00000000..46f18dab
--- /dev/null
+++ b/patches/leos/platform_device_phh_treble/0001-generate_sh.patch
@@ -0,0 +1,88 @@
+From eda5a305da60f3e10b1d9173d5812738a72ecb07 Mon Sep 17 00:00:00 2001
+From: harvey186
+Date: Wed, 10 Jan 2024 12:08:02 +0100
+Subject: [PATCH] generate_sh
+
+---
+ generate.sh | 30 ++++++------------------------
+ 1 file changed, 6 insertions(+), 24 deletions(-)
+
+diff --git a/generate.sh b/generate.sh
+index 461eff1..b3d80c4 100644
+--- a/generate.sh
++++ b/generate.sh
+@@ -15,8 +15,8 @@ fi
+ echo 'PRODUCT_MAKEFILES := \' > AndroidProducts.mk
+
+ for part in a ab;do
+- for apps in vanilla gapps foss gapps-go;do
+- for arch in arm64 arm a64;do
++ for apps in vanilla;do
++ for arch in arm64 a64;do
+ for su in yes no;do
+ apps_suffix=""
+ apps_script=""
+@@ -24,29 +24,11 @@ for part in a ab;do
+ extra_packages=""
+ vndk="vndk.mk"
+ optional_base=""
+- if [ "$apps" == "gapps" ];then
+- apps_suffix="g"
+- apps_script='$(call inherit-product, device/phh/treble/gapps.mk)'
+- apps_name="with GApps"
+- fi
+- if [ "$apps" == "gapps-go" ];then
+- apps_suffix="o"
+- apps_script='$(call inherit-product, device/phh/treble/gapps-go.mk)'
+- apps_name="Go"
+- fi
+- if [ "$apps" == "foss" ];then
+- apps_suffix="f"
+- apps_script='$(call inherit-product, vendor/foss/foss.mk)'
+- apps_name="with FOSS apps"
+- fi
+ if [ "$apps" == "vanilla" ];then
+ apps_suffix="v"
+ apps_script=''
+ apps_name="vanilla"
+ fi
+- if [ "$arch" == "arm" ];then
+- vndk="vndk-binder32.mk"
+- fi
+ if [ "$arch" == "a64" ];then
+ vndk="vndk32.mk"
+ fi
+@@ -64,7 +46,7 @@ for part in a ab;do
+ optional_base='$(call inherit-product, device/phh/treble/base-sas.mk)'
+ fi
+
+- target="treble_${arch}_${part_suffix}${apps_suffix}${su_suffix}"
++ target="leos_${arch}_${part_suffix}${apps_suffix}${su_suffix}"
+
+ baseArch="$arch"
+ if [ "$arch" = "a64" ];then
+@@ -77,18 +59,18 @@ for part in a ab;do
+ fi
+
+ cat > ${target}.mk << EOF
+-TARGET_GAPPS_ARCH := ${baseArch}
+ include build/make/target/product/aosp_${baseArch}.mk
+ \$(call inherit-product, device/phh/treble/base.mk)
++\$(call inherit-product, vendor/LeOS/leos.mk)
+ $optional_base
+ $apps_script
+ $rom_script
+
+ PRODUCT_NAME := $target
+-PRODUCT_DEVICE := tdgsi_${arch}_$part
++PRODUCT_DEVICE := leos_${arch}_$part
+ PRODUCT_BRAND := google
+ PRODUCT_SYSTEM_BRAND := google
+-PRODUCT_MODEL := TrebleDroid $apps_name
++PRODUCT_MODEL := LeOS-A14
+
+ # Overwrite the inherited "emulator" characteristics
+ PRODUCT_CHARACTERISTICS := device
+--
+2.34.1
+
diff --git a/patches/leos/platform_device_phh_treble/0002-LeOS-Stuff.patch b/patches/leos/platform_device_phh_treble/0002-LeOS-Stuff.patch
index eec82575..e9f3cd07 100644
--- a/patches/leos/platform_device_phh_treble/0002-LeOS-Stuff.patch
+++ b/patches/leos/platform_device_phh_treble/0002-LeOS-Stuff.patch
@@ -1,88 +1,89 @@
-From cfe78eb7d23ea53fa588a4a4ee724f0fe6665d71 Mon Sep 17 00:00:00 2001
+From d5f70e02277ae0389693651b7d62ac5dcb1ea9d6 Mon Sep 17 00:00:00 2001
From: harvey186
-Date: Sun, 7 Jan 2024 16:39:26 +0100
-Subject: [PATCH] 0001-LeOS-Stuff
+Date: Mon, 11 Dec 2023 17:20:55 +0100
+Subject: [PATCH] LeOS-Stuff
---
- generate.sh | 30 ++++++------------------------
- 1 file changed, 6 insertions(+), 24 deletions(-)
+ generate.sh | 31 +++++--------------
+ {tdgsi_a64_ab => leos_a64_ab}/BoardConfig.mk | 0
+ .../BoardConfig.mk | 0
+ tdgsi_a64_a/BoardConfig.mk | 8 -----
+ tdgsi_arm64_a/BoardConfig.mk | 7 -----
+ tdgsi_arm_a/BoardConfig.mk | 11 -------
+ tdgsi_arm_ab/BoardConfig.mk | 7 -----
+ 7 files changed, 8 insertions(+), 56 deletions(-)
+ rename {tdgsi_a64_ab => leos_a64_ab}/BoardConfig.mk (100%)
+ rename {tdgsi_arm64_ab => leos_arm64_ab}/BoardConfig.mk (100%)
+ delete mode 100644 tdgsi_a64_a/BoardConfig.mk
+ delete mode 100644 tdgsi_arm64_a/BoardConfig.mk
+ delete mode 100644 tdgsi_arm_a/BoardConfig.mk
+ delete mode 100644 tdgsi_arm_ab/BoardConfig.mk
-diff --git a/generate.sh b/generate.sh
-index 1e63d8c..b3d80c4 100644
---- a/generate.sh
-+++ b/generate.sh
-@@ -15,8 +15,8 @@ fi
- echo 'PRODUCT_MAKEFILES := \' > AndroidProducts.mk
-
- for part in a ab;do
-- for apps in vanilla gapps foss gapps-go;do
-- for arch in arm64 arm a64;do
-+ for apps in vanilla;do
-+ for arch in arm64 a64;do
- for su in yes no;do
- apps_suffix=""
- apps_script=""
-@@ -24,29 +24,11 @@ for part in a ab;do
- extra_packages=""
- vndk="vndk.mk"
- optional_base=""
-- if [ "$apps" == "gapps" ];then
-- apps_suffix="g"
-- apps_script='$(call inherit-product, vendor/gapps/common/common-vendor.mk)'
-- apps_name="with GApps"
-- fi
-- if [ "$apps" == "gapps-go" ];then
-- apps_suffix="o"
-- apps_script='$(call inherit-product, device/phh/treble/gapps-go.mk)'
-- apps_name="Go"
-- fi
-- if [ "$apps" == "foss" ];then
-- apps_suffix="f"
-- apps_script='$(call inherit-product, vendor/foss/foss.mk)'
-- apps_name="with FOSS apps"
-- fi
- if [ "$apps" == "vanilla" ];then
- apps_suffix="v"
- apps_script=''
- apps_name="vanilla"
- fi
-- if [ "$arch" == "arm" ];then
-- vndk="vndk-binder32.mk"
-- fi
- if [ "$arch" == "a64" ];then
- vndk="vndk32.mk"
- fi
-@@ -64,7 +46,7 @@ for part in a ab;do
- optional_base='$(call inherit-product, device/phh/treble/base-sas.mk)'
- fi
-
-- target="treble_${arch}_${part_suffix}${apps_suffix}${su_suffix}"
-+ target="leos_${arch}_${part_suffix}${apps_suffix}${su_suffix}"
-
- baseArch="$arch"
- if [ "$arch" = "a64" ];then
-@@ -77,18 +59,18 @@ for part in a ab;do
- fi
-
- cat > ${target}.mk << EOF
--TARGET_GAPPS_ARCH := ${baseArch}
- include build/make/target/product/aosp_${baseArch}.mk
- \$(call inherit-product, device/phh/treble/base.mk)
-+\$(call inherit-product, vendor/LeOS/leos.mk)
- $optional_base
- $apps_script
- $rom_script
-
- PRODUCT_NAME := $target
--PRODUCT_DEVICE := tdgsi_${arch}_$part
-+PRODUCT_DEVICE := leos_${arch}_$part
- PRODUCT_BRAND := google
- PRODUCT_SYSTEM_BRAND := google
--PRODUCT_MODEL := TrebleDroid $apps_name
-+PRODUCT_MODEL := LeOS-A14
-
- # Overwrite the inherited "emulator" characteristics
- PRODUCT_CHARACTERISTICS := device
+diff --git a/tdgsi_a64_ab/BoardConfig.mk b/leos_a64_ab/BoardConfig.mk
+similarity index 100%
+rename from tdgsi_a64_ab/BoardConfig.mk
+rename to leos_a64_ab/BoardConfig.mk
+diff --git a/tdgsi_arm64_ab/BoardConfig.mk b/leos_arm64_ab/BoardConfig.mk
+similarity index 100%
+rename from tdgsi_arm64_ab/BoardConfig.mk
+rename to leos_arm64_ab/BoardConfig.mk
+diff --git a/tdgsi_a64_a/BoardConfig.mk b/tdgsi_a64_a/BoardConfig.mk
+deleted file mode 100644
+index d430bf8..0000000
+--- a/tdgsi_a64_a/BoardConfig.mk
++++ /dev/null
+@@ -1,8 +0,0 @@
+-include build/make/target/board/generic_arm_ab/BoardConfig.mk
+-include device/phh/treble/board-base.mk
+-
+-ifeq ($(BOARD_SYSTEMIMAGE_PARTITION_RESERVED_SIZE),)
+-BOARD_SYSTEMIMAGE_PARTITION_SIZE := 1572864000
+-endif
+-TARGET_USES_64_BIT_BINDER := true
+-BOARD_SYSTEMIMAGE_AS_SYSTEM := true
+diff --git a/tdgsi_arm64_a/BoardConfig.mk b/tdgsi_arm64_a/BoardConfig.mk
+deleted file mode 100644
+index c9bc831..0000000
+--- a/tdgsi_arm64_a/BoardConfig.mk
++++ /dev/null
+@@ -1,7 +0,0 @@
+-include build/make/target/board/generic_arm64_ab/BoardConfig.mk
+-include device/phh/treble/board-base.mk
+-
+-ifeq ($(BOARD_SYSTEMIMAGE_PARTITION_RESERVED_SIZE),)
+-BOARD_SYSTEMIMAGE_PARTITION_SIZE := 2080374784
+-endif
+-BOARD_SYSTEMIMAGE_AS_SYSTEM := true
+diff --git a/tdgsi_arm_a/BoardConfig.mk b/tdgsi_arm_a/BoardConfig.mk
+deleted file mode 100644
+index 7340fc4..0000000
+--- a/tdgsi_arm_a/BoardConfig.mk
++++ /dev/null
+@@ -1,11 +0,0 @@
+-include build/make/target/board/generic_arm_ab/BoardConfig.mk
+-include device/phh/treble/board-base.mk
+-
+-ifeq ($(BOARD_SYSTEMIMAGE_PARTITION_RESERVED_SIZE),)
+-BOARD_SYSTEMIMAGE_PARTITION_SIZE := 1313583104
+-else
+-BOARD_SYSTEMIMAGE_PARTITION_RESERVED_SIZE := 25165824
+-endif
+-
+-TARGET_USES_64_BIT_BINDER := false
+-BOARD_SYSTEMIMAGE_AS_SYSTEM := true
+diff --git a/tdgsi_arm_ab/BoardConfig.mk b/tdgsi_arm_ab/BoardConfig.mk
+deleted file mode 100644
+index a9a4fe3..0000000
+--- a/tdgsi_arm_ab/BoardConfig.mk
++++ /dev/null
+@@ -1,7 +0,0 @@
+-include build/make/target/board/generic_arm_ab/BoardConfig.mk
+-include device/phh/treble/board-base.mk
+-
+-ifeq ($(BOARD_SYSTEMIMAGE_PARTITION_RESERVED_SIZE),)
+-BOARD_SYSTEMIMAGE_PARTITION_SIZE := 1073741824
+-endif
+-TARGET_USES_64_BIT_BINDER := false
--
2.34.1
diff --git a/patches/leos/platform_device_phh_treble/0001-a64_mk-file.patch b/patches/leos/platform_device_phh_treble/0003-a64_mk-file.patch
similarity index 100%
rename from patches/leos/platform_device_phh_treble/0001-a64_mk-file.patch
rename to patches/leos/platform_device_phh_treble/0003-a64_mk-file.patch
diff --git a/patches/leos/platform_device_phh_treble/0001-AdvancedPrivacy.patch b/patches/leos/platform_device_phh_treble/0004-AdvancedPrivacy.patch
similarity index 100%
rename from patches/leos/platform_device_phh_treble/0001-AdvancedPrivacy.patch
rename to patches/leos/platform_device_phh_treble/0004-AdvancedPrivacy.patch
diff --git a/patches/leos/platform_device_phh_treble/0001-secure_0_rw_system.patch b/patches/leos/platform_device_phh_treble/0020-adb_and_debugable.patch
similarity index 60%
rename from patches/leos/platform_device_phh_treble/0001-secure_0_rw_system.patch
rename to patches/leos/platform_device_phh_treble/0020-adb_and_debugable.patch
index cb840789..20391196 100644
--- a/patches/leos/platform_device_phh_treble/0001-secure_0_rw_system.patch
+++ b/patches/leos/platform_device_phh_treble/0020-adb_and_debugable.patch
@@ -1,17 +1,17 @@
-From 4b800e04249254a798ce2c5f120501084cad2579 Mon Sep 17 00:00:00 2001
+From c205b881e04aa9cb2f4b5ed4d7b7995a414ffb35 Mon Sep 17 00:00:00 2001
From: harvey186
-Date: Tue, 9 Jan 2024 10:15:21 +0100
-Subject: [PATCH] secure_0_rw_system
+Date: Wed, 10 Jan 2024 13:13:34 +0100
+Subject: [PATCH] adb_and_debugable
---
rw-system.sh | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/rw-system.sh b/rw-system.sh
-index 867a954..6cf1919 100644
+index 9a65307..a89a2f2 100644
--- a/rw-system.sh
+++ b/rw-system.sh
-@@ -822,12 +822,11 @@ copyprop() {
+@@ -795,12 +795,11 @@ if [ -f /system/phh/secure ] || [ -f /metadata/phh/secure ];then
resetprop_phh ro.boot.veritymode enforcing
resetprop_phh ro.boot.warranty_bit 0
resetprop_phh ro.warranty_bit 0
@@ -22,10 +22,10 @@ index 867a954..6cf1919 100644
resetprop_phh ro.build.type user
resetprop_phh ro.build.selinux 0
-- resetprop_phh ro.adb.secure 0
+- resetprop_phh ro.adb.secure 1
- for abi in "" 64;do
- f=/vendor/lib$abi/libstagefright_foundation.so
+ # Hide system/xbin/su
+ mount /mnt/phh/empty_dir /system/xbin
--
2.34.1
diff --git a/patches/leos/platform_packages_apps_Settings/0002-Captive_Portal_Toggle.patch b/patches/leos/platform_packages_apps_Settings/0002-Captive_Portal_Toggle.patchXXX
similarity index 100%
rename from patches/leos/platform_packages_apps_Settings/0002-Captive_Portal_Toggle.patch
rename to patches/leos/platform_packages_apps_Settings/0002-Captive_Portal_Toggle.patchXXX