From 4e5e42b749bdd6ce2b005f5a3a5ad38eedb1f495 Mon Sep 17 00:00:00 2001 From: Isaac Chen Date: Tue, 4 Jun 2019 16:20:07 +0800 Subject: [PATCH] Add misc_info.txt to rebuild super.img Include misc_info.txt (of CF's super.img) in *-img-*.zip. This is needed if we want to rebuild super.img by replacing some partitions in it. Other tools, lpunpack and lpmake, are included in CF's host package in another CL. Bug: 134461288 Test: $ lunch aosp_cf_x86-userdebug $ m dist $ unzip -l $OUT/*-img-*.zip | grep misc_info 619 2019-05-27 17:42 misc_info.txt Change-Id: Idf6146c2a7f9f32c9c4e5ddd2f6b9e65fc6bf55b --- core/Makefile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/core/Makefile b/core/Makefile index a4825e1d5a..952e2d1462 100644 --- a/core/Makefile +++ b/core/Makefile @@ -4432,6 +4432,7 @@ ifneq (true,$(PRODUCT_RETROFIT_DYNAMIC_PARTITIONS)) # For real devices and for dist builds, build super image from target files to an intermediate directory. INTERNAL_SUPERIMAGE_DIST_TARGET := $(call intermediates-dir-for,PACKAGING,super.img)/super.img +INTERNAL_SUPERIMAGE_MISC_INFO := $(call intermediates-dir-for,PACKAGING,superimage_debug)/misc_info.txt $(INTERNAL_SUPERIMAGE_DIST_TARGET): extracted_input_target_files := $(patsubst %.zip,%,$(BUILT_TARGET_FILES_PACKAGE)) $(INTERNAL_SUPERIMAGE_DIST_TARGET): $(LPMAKE) $(BUILT_TARGET_FILES_PACKAGE) $(BUILD_SUPER_IMAGE) $(call pretty,"Target super fs image from target files: $@") @@ -4483,7 +4484,7 @@ ifeq (true,$(BOARD_BUILD_SUPER_IMAGE_BY_DEFAULT)) $(INSTALLED_SUPERIMAGE_TARGET): $(INSTALLED_SUPERIMAGE_DEPENDENCIES) $(call pretty,"Target super fs image for debug: $@") $(call build-superimage-target,$(INSTALLED_SUPERIMAGE_TARGET),\ - $(call intermediates-dir-for,PACKAGING,superimage_debug)/misc_info.txt) + $(INTERNAL_SUPERIMAGE_MISC_INFO)) droidcore: $(INSTALLED_SUPERIMAGE_TARGET) @@ -4557,6 +4558,7 @@ $(INTERNAL_UPDATE_PACKAGE_TARGET): $(INTERNAL_SUPERIMAGE_DIST_TARGET) $(foreach device,$(BOARD_SUPER_PARTITION_BLOCK_DEVICES), \ OTA/super_$(device).img:super_$(device).img)) \ OTA/android-info.txt:android-info.txt "IMAGES/*.img:." + $(if $(INTERNAL_SUPERIMAGE_MISC_INFO), zip -q -j -u $@ $(INTERNAL_SUPERIMAGE_MISC_INFO)) $(if $(INTERNAL_SUPERIMAGE_DIST_TARGET), zip -q -j -u $@ $(INTERNAL_SUPERIMAGE_DIST_TARGET)) else $(INTERNAL_UPDATE_PACKAGE_TARGET):