* Somehow this newer versionis 130mb bigger - and wrecks basically
all current devices to the point that gapps couldn't fit.
* [javelinanddart]: Script it up.
Co-authored-by: javelinanddart@gmail.com
Some devices have a 32-bit userspace but a 64-bit kernel. These
devices need to have 32-bit gapps, not 64-bit ones. To fix this,
switch to getting arch from ro.bionic.arch instead of uname -m.
Additionally, remove the nice_arch function as it makes debugging
issues more difficult when the nice arch matches but the underlying
values don't line up.
* Only updated package names for now
* TODO: Remove Markup libs when removing MarkupGoogle apk
* TODO: Drop x86 support and/or add x86_64 support for emu
And don't count as needed space that will be freed from the replaced
files. This will allow to flash the zip over an existing installation
when space is tight.
Also:
awk --> tr | cut because recovery might not provide awk
grep -v --> tail -1 in du because it might spit out 3 lines
* Support dynamic partitions
* Mount product and system_ext when they're dedicated partitions
* Mount system at /mnt/system to not interfere with newer recoveries
* Android 10+ system images always contain a rootfs before system
* Don't use system toybox
From redfin-rq1a.201205.011
* Move everything to product or system_ext
* No more maps jar?
* Fix sha1sum of arm64 MarkupGoogle/lib/arm64/libsketchology_native.so
The file is unchanged, the checksum simply has always been wrong
* Adapt to new blueprint based extract utils
On devices with low memory or storage, the update-binary skips
installation of SetupWizard, which normally overrides AOSP's Provision
app. Unfortunately, the script currently removes the Provision app even
when SetupWizard is not installed in the low memory or storage case,
which causes the device to remain stuck in an unprovisioned state (Home
button doesn't work for example).
Tests
-----
Tested on Nexus 5 (hammerhead) with LOW_STORAGE and confirmed that the
Provision app is not removed since SetupWizard is not installed.
Confirmed that the Play store works.
Tested on Nexus 5X (bullhead) which is not LOW_STORAGE and confirmed
that the Provision app is removed since SetupWizard is installed.
Confirmed that the Play store works.
* On Custom ROM's on Pixels, the downloading of
this app by SetupWizard often hangs up,
and needs to be restarted. Ship this to avoid
that.
* Added to LOWMEM checkas it isn't necessary.
* Currently, on both devices enforcing veirty, and devices not
enforcing verity, we are unable to flash files to the system
partition after a payload (a/b) style flash. Revert this
logic until is/when we figure this out.
* A/B users will need to flash the ROM, reboot, and install
from thee recovery in the other slot.
* On some devices, /system is already mounted, and when we try to
mount it ourselves, it fails, causing installation to abort
* To prevent this, umount /system before we try to mount it
* We'll first check the currently loaded slot. We can
assume the user just flashed a rom and that the target
slot for this rom is the other slot, so mount that
system image. TODO: autodetect this somehow
* Mount this system partition at /system_root (rw) and then
mount the /system/system folder at /system. We do it
this way for a couple reasons. Because it makes the
script easier to work with and because we're using
toybox from the system partition for operations, which
is expecting /system/bin/linker64 to exist.
Change-Id: Ia6f96f0864d725b0123665bbbce0e31523bb834f
* For some bizarre reason, the unzip util included with
lineage recovery doesn't work with the system/*
wildcard for unzip, so just extract the entire zip
and remove the META-INF folder from /tmp manually
Change-Id: Id11e18d7fef0c78b10f7060a10274ea0e958ea84
Signed-off-by: Paul Keith <javelinanddart@bestas.gr>
* This is done based on the total memory as reported by /proc/meminfo
* If the memory in the MemTotal field is less than 1572864 kB (1.5 GB),
then Google's SuW is removed as a precaution, as it is known to crash
on devices that don't have much memory available to use
* Thanks to cdesai for the solution idea
Change-Id: If0d5b9dff7f9536f78d4069df8665b19209fea52
Signed-off-by: Paul Keith <javelinanddart@bestas.gr>