Add typecode to sgdisk for proper detection in Android

- Fixes the "Unsupported SD Card" error when partitioning w/TWRP

PS2:
Use hex code instead of GUID to make code more succinct
Update typecode for Linux swap to be consistent

PS3: Revert PS2 changes

Change-Id: I5aec780aa4dfb7bd9025ae8cbceda13bfaaa0b03
This commit is contained in:
Captain Throwback
2016-05-27 11:44:51 -04:00
committed by Dees Troy
parent 786d734a41
commit 9643a80b02
+1 -1
View File
@@ -1779,7 +1779,7 @@ int TWPartitionManager::Partition_SDCard(void) {
return false;
}
gui_msg(Msg("create_part=Creating {1} partition...")("FAT32"));
Command = "sgdisk --new=0:0:" + fat_str + " --change-name=0:\"Microsoft basic data\" " + Device;
Command = "sgdisk --new=0:0:" + fat_str + " --change-name=0:\"Microsoft basic data\" --typecode=0:EBD0A0A2-B9E5-4433-87C0-68B6B72699C7 " + Device;
LOGINFO("Command is: '%s'\n", Command.c_str());
if (TWFunc::Exec_Cmd(Command) != 0) {
gui_msg(Msg(msg::kError, "unable_to_create_part=Unable to create {1} partition.")("FAT32"));