From b0d7d4fa6f15961caa320fdeb5a5c51533a15ad0 Mon Sep 17 00:00:00 2001 From: Caio Schnepper Date: Sat, 4 Jul 2015 22:57:09 -0300 Subject: releasetools: resize system partition after flashing resize2fs.static is placed in install/bin, possible to run without /system mounted. running it will resize /system to the actual system partition size, supporting custom pits with block-based OTAs Change-Id: Id2c82add1f697ae3d7e5a1031f6a6d51a4ee53e0 --- releasetools/extensions/releasetools.py | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 releasetools/extensions/releasetools.py (limited to 'releasetools') diff --git a/releasetools/extensions/releasetools.py b/releasetools/extensions/releasetools.py new file mode 100644 index 0000000..b64b999 --- /dev/null +++ b/releasetools/extensions/releasetools.py @@ -0,0 +1,10 @@ +import common +import struct + +def FullOTA_PostValidate(info): + # run e2fsck + info.script.AppendExtra('run_program("/sbin/e2fsck", "-fy", "/dev/block/mmcblk0p9");'); + # resize2fs: run and delete + info.script.AppendExtra('run_program("/tmp/install/bin/resize2fs_static", "/dev/block/mmcblk0p9");'); + # run e2fsck + info.script.AppendExtra('run_program("/sbin/e2fsck", "-fy", "/dev/block/mmcblk0p9");'); -- cgit v1.1