* Some versions of SuperSU use only loop0 or loop1, so let's skip those
and create the fake system.img (needed for block_image_update) at the
next free loop device.
Change-Id: Ie4a9e1679a11c75b95411dfe7c0e048b0215fa4e
* Using a real block device for the fake boot.img improves compatibility
with scripts/mods/etc that directly manipulate the boot partition, so
boot.img truncation as well as 'dd if=/dev/zero of=$BOOTIMAGE' overflows
will be avoided.
Change-Id: I9b93ac5df829db713bc81c3ce3b34f7c2fbee27f
* MultiROM uses restorecon -D which is only available in toolbox, which is
now deprecated in toolbox and moved to toybox.
* Furthermore the existence of file_contexts and file_contexts.bin
has made recovery based restorecon unreliable for secondary ROMs
so instead opt for using the secondary ROM's own restorecon.
* This may need to tested for backward compatibility.
* Alternative: consider building our own restorcon which should be capable
of handling both text and binary formats of filecontexts.
Change-Id: I836cd9a2a72487b9211f9ffe1703118c50ef44fd
We can use switches and enums to make things more understandable
and work with results in a more sensible manner.
PS2: Move file MD5 verification and error handling into
a separate function to reduce code.
PS3: Default to false in Check_Restore_File_MD5 function
Change-Id: Id3ee0bb444cf13be67bb5dec2c43f7c26a86b954
* Zip files containing only an update-binary as a shell script, without
the accompanying updater-script (which would just be a dummy file), such
as some gapps installers would fail.
Since they lack the dummy updater-script file, normally including in zips
that rely on shell-script formatted update-binary.
* Since MultiROM tries to adjust the updater-script for anything that may
interfere with secondary ROM installation, it fails to, if it cannot find
an updater-script.
* This patch will react as normal zip installation would, it won't parse or edify
any offending command and simply pass it on to normal TWRP zip flash.
Change-Id: If1c96c7e8be32288e532dd6ce20dcafb7ae251ab
PS2: full_filename is not a dir
PS3: use a consistent format of always assuming directory
is missing the trailing / + fix whitespace alignment
Change-Id: Ib963473ae10571b3d069b326d024ca04c7224dda
* Fixes issue when flashing a ZIP with AROMA Installer and the screen is off
AROMA Installer takes over screen and button input, so there's no way to
wake the device.
Change-Id: I3c0dd3cdba5aae3c7a91f0141f29ddd02dd84b35
No-kexec workaround version 4 for no kexec-hardboot kernels
* MultiROM support for no kexec-hardboot enabled kernels.
It has been tested on the HTC One M7, M8, M9 and HTC 10
as well as other devices successfully.
* This commit is the TWRP recovery portion, which adds
(1) various settings in TWRP->MultiROM-Settings
(2) properly restores primary kernel if needed
the real code is in multirom https://github.com/multirom-htc/multirom
Note:
* The following build flag needs to be added in BoardConfig:
MR_NO_KEXEC := <value> where value is:
- 1 true allowed
-> No-Kexec is built but not enabled by default
- 2 enabled
-> No-Kexec is set to "only when needed"
- 3 ui_confirm
-> No-Kexec is set to "ask for confirmation"
- 4 ui_choice
-> No-Kexec is set to "choose boot method"
- 5 forced
-> No-Kexec is set to "force using no-kexec"
please see http://forum.xda-developers.com/showpost.php?p=68738134&postcount=4 for a description of these options
Change-Id: I8b7958cb2d7759933875ef82b2fa8f60bb514f00
The PartitionSettings struct contains some data elements that are duplicates
of data elements in the TWPartition class that is contained within the
PartitionsSettings.Part element. We will eliminate this duplication to help
reduce the chances for programming bugs.
Specifically, this fixes problems where the current file system does not
match the backed up file system.
Change-Id: I02f236e72093362050556a2e53a09d1dbb9a269d
* Allows the usage of symlinks on /init for ramdisk
using this method to call the real binary or script
Change-Id: I664e232e86bc8271a327bbcd62f370924cc9326f
Signed-off-by: Adrian DC <radian.dc@gmail.com>
Workaround (v2) for no kexec-hardboot kernels
* MultiROM support for no kexec-hardboot enabled kernels.
It has been tested on the HTC One M7, M8 and M9 successfully.
* This commit is the TWRP recovery portion, which adds
(1) various settings in TWRP->MultiROM-Settings
(2) properly restores primary kernel if needed
the real code is in multirom https://github.com/nkk71/multirom
* This is an updated and more reliable version of the initial
WIP 6ae88fe659
Note:
* The following build flag needs to be added in BoardConfig:
MR_ALLOW_NKK71_NOKEXEC_WORKAROUND := true (reverted from commit 21ff5ee42a)
Change-Id: I27e1803b8821f01bc5d9cfd97940cbc6c6fb1334
This patchset will fix issues with creating and checking
md5 checksums with single partitions and subpartitions.
Change-Id: Iddfaf46412e95635af958094726cf9e3eb5a4cc8