summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStefan Tauner <stefan.tauner@gmx.at>2017-10-04 03:47:26 +0200
committerNico Huber <nico.h@gmx.de>2017-10-05 10:43:05 +0000
commitfa25bc3cd433e2cdbf8d0922a29be71815a072cd (patch)
treec15a00533e57c120f7700284f991af4a9f51aa0f
parent5bf6b855d4083070390b5c0eb03bca678090d75d (diff)
downloadflashrom-fa25bc3cd433e2cdbf8d0922a29be71815a072cd.tar.gz
flashrom-fa25bc3cd433e2cdbf8d0922a29be71815a072cd.tar.bz2
flashrom-fa25bc3cd433e2cdbf8d0922a29be71815a072cd.zip
fixup! Convert flashrom to git
- exploit Make's -include statement to simplify execution flow - expand and refine respective comment to better describe and match the new behavior Change-Id: I0c66f2508cc754cf9219211a06d6f305a32c422d Signed-off-by: Stefan Tauner <stefan.tauner@gmx.at> Reviewed-on: https://review.coreboot.org/21830 Reviewed-by: Nico Huber <nico.h@gmx.de> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
-rw-r--r--Makefile11
1 files changed, 4 insertions, 7 deletions
diff --git a/Makefile b/Makefile
index d0145809e..1893bb198 100644
--- a/Makefile
+++ b/Makefile
@@ -526,15 +526,12 @@ LIB_OBJS = libflashrom.o layout.o flashrom.o udelay.o programmer.o helpers.o ich
CLI_OBJS = cli_classic.o cli_output.o cli_common.o print.o
-# versioninfo.inc is used when packaging flashrom and is generated by the
-# export rule. If versioninfo.inc is not found, version info will be obtained
-# using util/getrevision.sh.
-ifeq ($(wildcard versioninfo.inc),)
+# versioninfo.inc stores metadata required to build a packaged flashrom. It is generated by the export rule and
+# imported below. If versioninfo.inc is not found and the variables are not defined by the user, the info will
+# be obtained using util/getrevision.sh, which is the common case during development.
+-include versioninfo.inc
VERSION ?= $(shell ./util/getrevision.sh --revision)
MAN_DATE ?= $(shell ./util/getrevision.sh --date $(PROGRAM).8.tmpl 2>/dev/null)
-else
-include versioninfo.inc
-endif
# VERSION equals "offline" if online access is required but the respective git
# config variable is not set yet.