[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [xen staging] tools/firmware: reproducible seabios build



commit 773b86303ffe1a0181be3382d98680f58314f84d
Author:     Olaf Hering <olaf@xxxxxxxxx>
AuthorDate: Wed Jul 18 13:02:38 2018 +0200
Commit:     Wei Liu <wei.liu2@xxxxxxxxxx>
CommitDate: Wed Jul 18 17:32:19 2018 +0100

    tools/firmware: reproducible seabios build
    
    The build system of seabios always includes the current time and the
    hostname into the resulting binary. To avoid that, it is required to
    have a file '.version' in the toplevel directory of seabios-dir-remote.
    And it is required to pass EXTRAVERSION= to make because its toplevel
    Makefile does not take EXTRAVERSION from environment.
    
    Adjust the code to create a '.version' file with fixed content.
    Adjust the code to pass EXTRAVERSION down to make.
    
    Signed-off-by: Olaf Hering <olaf@xxxxxxxxx>
    Acked-by: Wei Liu <wei.liu2@xxxxxxxxxx>
---
 tools/firmware/Makefile | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/tools/firmware/Makefile b/tools/firmware/Makefile
index bc84300b69..ed1a1318f6 100644
--- a/tools/firmware/Makefile
+++ b/tools/firmware/Makefile
@@ -21,6 +21,7 @@ SUBDIRS-y += hvmloader
 
 SEABIOSCC ?= $(CC)
 SEABIOSLD ?= $(LD)
+SEABIOS_EXTRAVERSION ?= "-Xen"
 
 ovmf-dir:
        GIT=$(GIT) $(XEN_ROOT)/scripts/git-checkout.sh $(OVMF_UPSTREAM_URL) 
$(OVMF_UPSTREAM_REVISION) ovmf-dir
@@ -30,6 +31,8 @@ seabios-dir:
        GIT=$(GIT) $(XEN_ROOT)/scripts/git-checkout.sh $(SEABIOS_UPSTREAM_URL) 
$(SEABIOS_UPSTREAM_REVISION) seabios-dir
        cp seabios-config seabios-dir/.config;
        $(MAKE) -C seabios-dir olddefconfig CC=$(SEABIOSCC) LD=$(SEABIOSLD)
+       rm -f seabios-dir/.version
+       echo '$(SEABIOS_UPSTREAM_REVISION)' > seabios-dir/.version
 
 .PHONY: all
 all: $(SUBDIRS-y)
@@ -136,4 +139,4 @@ subtree-force-update-all:
        $(MAKE) ovmf-dir-force-update
 
 subdir-all-seabios-dir: seabios-dir
-       $(MAKE) -C $< CC=$(SEABIOSCC) LD=$(SEABIOSLD) PYTHON=$(PYTHON) all;
+       $(MAKE) -C $< CC=$(SEABIOSCC) LD=$(SEABIOSLD) PYTHON=$(PYTHON) 
EXTRAVERSION=$(SEABIOS_EXTRAVERSION) all;
--
generated by git-patchbot for /home/xen/git/xen.git#staging

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/xen-changelog

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.