From 4355f401dbcfaba1ec75c672de60feaf990dddc8 Mon Sep 17 00:00:00 2001 From: Michael Shigorin Date: Tue, 7 Feb 2012 22:21:33 +0200 Subject: [PATCH] image.in/Makefile: introduced save-profile From now on, non-empty SAVE_PROFILE variable will indicate the need to carry the particular generated profile inside the image built from it. Thanks gns@ for this feature in liveflash.eeepc. --- doc/variables.txt | 5 +++++ image.in/Makefile | 7 +++++++ 2 files changed, 12 insertions(+) diff --git a/doc/variables.txt b/doc/variables.txt index cf54dd8e..7ac13518 100644 --- a/doc/variables.txt +++ b/doc/variables.txt @@ -65,6 +65,11 @@ + значение: пусто (по умолчанию) либо любая строка + см. ../lib/build.mk +- SAVE_PROFILE + + сохраняет архив сгенерированного профиля в .disk/ + + значение: пусто (по умолчанию) либо любая строка + + см. ../image.in/Makefile + пример ~~~~~~ make DEBUG=1 CLEAN=1 distro/syslinux.iso diff --git a/image.in/Makefile b/image.in/Makefile index a5a2bfbe..2a4935a3 100644 --- a/image.in/Makefile +++ b/image.in/Makefile @@ -47,6 +47,13 @@ include $(MKIMAGE_PREFIX)/targets.mk pack-image: OUTDIR = $(IMAGEDIR) pack-image: imagedir +copy-tree: $(SAVE_PROFILE:%=save-profile) + +save-profile: + @mkdir -p files/.disk; \ + git archive --prefix=mkimage-profile/ HEAD \ + | gzip -9 > files/.disk/profile.tgz + .PHONY: imagedir postprocess debug imagedir: