[HD2 Android NAND Development] kokotas:
Hi guys,

First of all consider this an experiment.

Accept to use it by expecting things not to work:eek:.

(Then why should you try it in the first place? Because you have nothing else to do and feel curious!?)

Ok then, attached below is the first TWRP version with my modifications, v2.3.2.X.

(X = Parental advisory - Explicit content)

New features :

Detection of bootloader

It's possible using the cmdline arg:

bool DataManager::BLDR_Is_cLK(void) {
bool ret = false;
string cmd = "grep -Fxq \"clk=\" /proc/cmdline";

if (system(cmd.c_str()) == 0)
ret = true;
else
ret = false;

return ret;
}

Nilfs2 support for sdcard's ext partition

Under "Partition SD Card" we now have these file system options: NILFS2 and EXT4

Using Unhelpful's binaries we can now format an ext partition to nilfs2 file system.

From what I read the thing to look out with nilfs2 is the garbage cleaning.

In case our ext partition gets full, even if we delete stuff, it will still be impossible to use it without re-formatting (all these inside recovery's environment).

Anyway this needs more studying...maybe new nilfs2 binaries too...

Option for converting file system(formatting) of sdcard's ext partition: [ext2 - ext3 - ext4 - nilfs2]

Under ADVANCED there is a new button: "Set EXT FS type"

From there you can format the selected ext partition to any of the above file systems.

In-built NativeSD manager

Under ADVANCED there is a new button: "NativeSD manager"

From there you can Backup - Restore - Delete - Fix Permissions - Wipe Data - Wipe Dalvik-Cache on any NativeSD located on your card.

Selecting a Rom is done by entering the folder named after the Rom inside /sdcard/NativeSD/ and hit "Select" button.

If you have the latest cLK you can Restore(=flash) the kernel of the rom you want to the extra boot partition you want.

You can set which parts(boot - system - data) to backup/restore.

Lastly you can set which ext partition to use in all the above operations in case you've added a 2nd one.

Option for adding a 2nd ext partition(mmcblk0p3)

Under "Partition SD Card" we can add a 2nd ext partition (mount point : /sdext2).

If it exists it can be backed up/restored just like /sd-ext.

(cLK)Direct rebooting to selected boot partition

If you have the latest cLK and have added any extra boot partition then under "Reboot" you will find the relevant button to boot directly from that partition.

Option to adjust the backup process for DataOnExt case

Under "BackUp" there is a new button "DataOnExt" for users that use this method. Instructions are provided within the recovery's menu.

Example1: I use DataOnExt and my sd-ext is mounted as /data

Press "DataOnExt" button => set path: /sd-ext => uncheck checkbox => Press ENTER

Check /data & Uncheck /sd-ext

Swipe to backup

Example2: I use DataOnExt with DalvikOnNand and my sd-ext is mounted as /data

Press "DataOnExt" button => set path: /sd-ext => check checkbox => Press ENTER

Check /data & Uncheck /sd-ext

Swipe to backup

Example3: I use DataOnExt and my sd-ext/Path/to/data is mounted as /data

Press "DataOnExt" button => set path: /sd-ext/Path/to/data => uncheck checkbox => Press ENTER

Check /data & Uncheck /sd-ext

Swipe to backup

Bug fixes :

1st attempt for archive splitting(also lowered the max size to 512MB)

1st attempt for MAGLDR boot restoring

Regards!