From 3b6827372e4313ebc1304597472f3235deda01d5 Mon Sep 17 00:00:00 2001 From: Chaosmaster Date: Sat, 25 Jan 2020 21:09:28 +0100 Subject: [PATCH] Set system-partition mount point to proper location This sets the system mount point to either /system_root or /system depending on whether SAR is detected or not irregardless of what is specified in fstab. This removes the need to edit fstab for SAR-builds and simplifies building unified (SAR/non-SAR) builds. Change-Id: I154fd76f842702be9e5d09005463c8e5f1d289a4 --- partition.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/partition.cpp b/partition.cpp index beb4a81d..9012d497 100644 --- a/partition.cpp +++ b/partition.cpp @@ -436,7 +436,10 @@ bool TWPartition::Process_Fstab_Line(const char *fstab_line, bool Display_Error, } else if (Is_File_System(Fstab_File_System)) { Find_Actual_Block_Device(); Setup_File_System(Display_Error); - if (Mount_Point == PartitionManager.Get_Android_Root_Path()) { + if (Mount_Point == "/" || Mount_Point == "/system" || Mount_Point == "/system_root") { + Mount_Point = PartitionManager.Get_Android_Root_Path(); + Backup_Path = Mount_Point; + Storage_Path = Mount_Point; Display_Name = "System"; Backup_Display_Name = Display_Name; Storage_Name = Display_Name;