[coreboot-gerrit] New patch to review for coreboot: Makefile.inc: Stop running git repeatedly for each build
Martin Roth (martinroth@google.com)
gerrit at coreboot.org
Mon Apr 18 04:15:43 CEST 2016
Martin Roth (martinroth at google.com) just uploaded a new patch set to gerrit, which you can find at https://review.coreboot.org/14392
-gerrit
commit b173fe2f9199aead7805456f96918be4120d55d8
Author: Martin Roth <martinroth at google.com>
Date: Tue Apr 19 20:15:16 2016 -0600
Makefile.inc: Stop running git repeatedly for each build
Currently, the coreboot makefiles repeatedly run git to try to set
the KERNELVERSION variable and to fetch the submodules. This happens
three times for every build. By exporting a variable, we can catch
this on recursive makes and not run each of these steps again.
Change-Id: I85ab867b40e80c36bd94d48510ffe3252c6cf93f
Signed-off-by: Martin Roth <martinroth at google.com>
---
Makefile.inc | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/Makefile.inc b/Makefile.inc
index 0a3b92c..02ea674 100644
--- a/Makefile.inc
+++ b/Makefile.inc
@@ -22,6 +22,7 @@ CONFIG_FMDFILE:=$(call strip_quotes,$(CONFIG_FMDFILE))
#######################################################################
# misleadingly named, this is the coreboot version
+ifeq ($(KERNELVERSION),)
ifeq ($(BUILD_TIMELESS),1)
export KERNELVERSION := TIMELESS
else
@@ -31,6 +32,7 @@ export KERNELVERSION := $(strip $(if $(GIT),\
$(shell cat $(top)/.coreboot-version),\
coreboot-unknown$(KERNELREVISION))))
endif
+endif
#######################################################################
# Basic component discovery
@@ -174,6 +176,7 @@ ifeq ($(CONFIG_COVERAGE),y)
ramstage-c-ccopts += -fprofile-arcs -ftest-coverage
endif
+ifneq ($(UPDATED_SUBMODULES),1)
# try to fetch non-optional submodules if the source is under git
forgetthis:=$(if $(GIT),$(shell git submodule update --init))
ifeq ($(CONFIG_USE_BLOBS),y)
@@ -181,6 +184,8 @@ ifeq ($(CONFIG_USE_BLOBS),y)
# unless explicitly requested and enabled through --checkout
forgetthis:=$(if $(GIT),$(shell git submodule update --init --checkout 3rdparty/blobs))
endif
+export UPDATED_SUBMODULES:=1
+endif
ramstage-c-deps:=$$(OPTION_TABLE_H)
romstage-c-deps:=$$(OPTION_TABLE_H)
More information about the coreboot-gerrit
mailing list