[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Minios-devel] [UNIKRAFT PATCH] build: fix uncontional full recompilation
Reviewed-by: Simon Kuenzer <simon.kuenzer@xxxxxxxxx> Thanks! On 14.03.2018 15:49, Yuri Volchkov wrote: Files app.uk and elib.uk are regenerated always, but config.h depends on both of them. And because config.h is included by EVERY file in the unikraft (and apps), this forces a full recompilation every time one runs make. Let's do not touch mentioned files at first, and generate app.uk.new and elib.uk.new instead. Then compare them with what we have from last build (app.uk and elib.uk). If they do not match copy *.new to the final destination. Signed-off-by: Yuri Volchkov <yuri.volchkov@xxxxxxxxx> --- Makefile | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 7a34396..b177bff 100644 --- a/Makefile +++ b/Makefile @@ -541,7 +541,10 @@ HOSTCFLAGS = $(CFLAGS_FOR_BUILD) export HOSTCFLAGS# auto-generated KConfig files for including external app-$(KCONFIG_APP_IN): +$(KCONFIG_APP_IN) $(KCONFIG_ELIB_IN): %: %.new + @cmp -s $^ $@; if [ $$? -ne 0 ]; then cp $^ $@; fi + +$(KCONFIG_APP_IN).new: @echo '# external application' > $@ ifneq ($(UK_BASE),$(UK_APP)) @echo 'source "$(APP_DIR)/Config.uk"' >> $@ @@ -550,14 +553,14 @@ else endif# auto-generated KConfig files for including external libraries-$(KCONFIG_ELIB_IN): +$(KCONFIG_ELIB_IN).new: @echo '# external libraries' > $@ @$(foreach E,$(ELIB_DIR), \ echo 'source "$(E)/Config.uk"' >> $@; \ )# enforce execution-.PHONY: $(KCONFIG_APP_IN) $(KCONFIG_ELIB_IN) +.PHONY: $(KCONFIG_APP_IN).new $(KCONFIG_ELIB_IN).new$(KCONFIG_DIR)/%onf:mkdir -p $(@D)/lxdialog _______________________________________________ Minios-devel mailing list Minios-devel@xxxxxxxxxxxxxxxxxxxx https://lists.xenproject.org/mailman/listinfo/minios-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |