tools: various changes
v2 cover tools: various changes
A resend of this series, with comments addressed:
http://lists.xenproject.org/archives/html/xen-devel/2015-03/msg02645.html
* The XENSTORED_ARGS= should be fine according to IanJ
* The changes for reproducible builds are really just interesting for distro packages. Passing all the variables via a rpm spec file for example can be automated in such build environment. The current behaviour is preserved.
Please review once more and apply.
Thanks,
Olaf
Olaf Hering (4):
tools/hotplug: introduce XENSTORED_ARGS= in sysconfig file.
INSTALL: mention variables for reproducible builds
hvmloader: add knob for fixed SMBIOS date string
hvmloader: add knob for fixed VGABIOS date string
INSTALL | 8 ++++++++ tools/firmware/hvmloader/Makefile | 5 ++++- tools/firmware/vgabios/Makefile | 4 ++-- tools/hotplug/Linux/init.d/sysconfig.xencommons.in | 8 ++++++++ 4 files changed, 22 insertions(+), 3 deletions(-)
PATCH v2 1/4 tools/hotplug: introduce XENSTORED_ARGS= in sysconfig file.
It is already used in the runlevel script and the service file.
--- tools/hotplug/Linux/init.d/sysconfig.xencommons.in | 8 ++++++++ 1 file changed, 8 insertions(+)
tools/hotplug/Linux/init.d/sysconfig.xencommons.in +8 -0
@@ -21,6 +21,14 @@ #XENSTORED=@XENSTORED@ ## Type: string +## Default: "" +# +# Additional commandline arguments to start xenstored, +# like "--trace-file /var/log/xen/xenstored-trace.log" +# See "@sbindir@/xenstored --help" for possible options. +XENSTORED_ARGS= + +## Type: string ## Default: Not defined, tracing off # # Log xenstored messages
PATCH v2 2/4 INSTALL: mention variables for reproducible builds
In reply to Olaf HeringMention two variables introduced by commit ac977f5 ("use more fixed strings to build the hypervisor").
---
v2: adjust format for XEN_BUILD_DATE
INSTALL | 6 ++++++ 1 file changed, 6 insertions(+)
INSTALL +6 -0
@@ -211,6 +211,12 @@ changed with these variables. XEN_WHOAMI= XEN_DOMAIN= +Some components of xen and tools will include an unpredictable timestamp +into the binaries. To allow reproducible builds the following variables +can be used to provide fixed timestamps in the expected format. +XEN_BUILD_DATE=<output of date(1)> +XEN_BUILD_TIME=hh:mm:ss + The following variables can be used to tweak some aspects of the hypervisor build. verbose=y
PATCH v2 3/4 hvmloader: add knob for fixed SMBIOS date string
In reply to Olaf HeringTo allow reproducible builds of hvmloader introduce a make variable SMBIOS_REL_DATE=mm/dd/yyyy to provide a fixed date string. Without this change the hvmloader binary changes with every rebuild.
--- INSTALL | 1 + tools/firmware/hvmloader/Makefile | 5 ++++- 2 files changed, 5 insertions(+), 1 deletion(-)
INSTALL +1 -0
@@ -216,6 +216,7 @@ into the binaries. To allow reproducible builds the following variables can be used to provide fixed timestamps in the expected format. XEN_BUILD_DATE=<output of date(1)> XEN_BUILD_TIME=hh:mm:ss +SMBIOS_REL_DATE=mm/dd/yyyy The following variables can be used to tweak some aspects of the hypervisor build.
tools/firmware/hvmloader/Makefile +4 -1
@@ -26,6 +26,9 @@ SUBDIRS := acpi # The HVM loader is started in 32-bit mode at the address below: LOADADDR = 0x100000 +# SMBIOS spec requires format mm/dd/yyyy +SMBIOS_REL_DATE ?= $(shell date +%m/%d/%Y) + CFLAGS += $(CFLAGS_xeninclude) OBJS = hvmloader.o mp_tables.o util.o smbios.o
@@ -88,7 +91,7 @@ all: subdirs-all $(MAKE) hvmloader ovmf.o rombios.o seabios.o hvmloader.o: roms.inc -smbios.o: CFLAGS += -D__SMBIOS_DATE__="\"$(shell date +%m/%d/%Y)\"" +smbios.o: CFLAGS += -D__SMBIOS_DATE__="$(SMBIOS_REL_DATE)" hvmloader: $(OBJS) acpi/acpi.a $(LD) $(LDFLAGS_DIRECT) -N -Ttext $(LOADADDR) -o hvmloader.tmp $^
PATCH v2 4/4 hvmloader: add knob for fixed VGABIOS date string
In reply to Olaf HeringTo allow reproducible builds of hvmloader introduce a make variable VGABIOS_REL_DATE="dd Mon yyyy" to provide a fixed date string. Without this change the hvmloader binary changes with every rebuild.
--- INSTALL | 1 + tools/firmware/vgabios/Makefile | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-)
INSTALL +1 -0
@@ -217,6 +217,7 @@ can be used to provide fixed timestamps in the expected format. XEN_BUILD_DATE=<output of date(1)> XEN_BUILD_TIME=hh:mm:ss SMBIOS_REL_DATE=mm/dd/yyyy +VGABIOS_REL_DATE="dd Mon yyyy" The following variables can be used to tweak some aspects of the hypervisor build.
tools/firmware/vgabios/Makefile +2 -2
@@ -5,10 +5,10 @@ BCC = bcc AS86 = as86 RELEASE = `pwd | sed "s-.*/--"` -RELDATE = `date '+%d %b %Y'` +VGABIOS_REL_DATE ?= `date '+%d %b %Y'` RELVERS = `pwd | sed "s-.*/--" | sed "s/vgabios//" | sed "s/-//"` -VGABIOS_DATE = "-DVGABIOS_DATE=\"$(RELDATE)\"" +VGABIOS_DATE = "-DVGABIOS_DATE=\"$(VGABIOS_REL_DATE)\"" .PHONY: all all: bios cirrus-bios
Re: [PATCH 2/4 v2] INSTALL: mention variables for reproducible builds
In reply to Olaf HeringQuoted 4 lines · Olaf Hering
Mention two variables introduced by commit ac977f5 ("use more fixed strings to build the hypervisor").
Signed-off-by Olaf Hering <[email protected]>
Re: [PATCH 4/4] hvmloader: add knob for fixed VGABIOS date string
In reply to Olaf HeringQuoted 7 lines · Olaf Hering
To allow reproducible builds of hvmloader introduce a make variable VGABIOS_REL_DATE="dd Mon yyyy" to provide a fixed date string. Without this change the hvmloader binary changes with every rebuild.
Signed-off-by Olaf Hering <[email protected]>Cc Ian Jackson <[email protected]>Cc Stefano Stabellini <[email protected]>
It's not clear if vgabios should be maintained by us tools folks or if it should have been taken under the hvmloader umbrella and maintained by the hypervisor folks.
I've CC-d Jan, but I'm not going to block on an ack.
Quoted 35 lines
Cc Wei Liu <[email protected]>--- INSTALL | 1 + tools/firmware/vgabios/Makefile | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-)INSTALL +1
-0@@ -217,6 +217,7 @@ can be used to provide fixed timestamps in the expected format. XEN_BUILD_DATE=<output of date(1)> XEN_BUILD_TIME=hh:mm:ss SMBIOS_REL_DATE=mm/dd/yyyy +VGABIOS_REL_DATE="dd Mon yyyy" The following variables can be used to tweak some aspects of the hypervisor build.tools/firmware/vgabios/Makefile +2
-2@@ -5,10 +5,10 @@ BCC = bcc AS86 = as86 RELEASE = `pwd | sed "s-.*/--"` -RELDATE = `date '+%d %b %Y'` +VGABIOS_REL_DATE ?= `date '+%d %b %Y'` RELVERS = `pwd | sed "s-.*/--" | sed "s/vgabios//" | sed "s/-//"` -VGABIOS_DATE = "-DVGABIOS_DATE=\"$(RELDATE)\"" +VGABIOS_DATE = "-DVGABIOS_DATE=\"$(VGABIOS_REL_DATE)\"" .PHONY: all all: bios cirrus-bios
Quoted 2 lines · Olaf Hering
A resend of this series, with comments addressed:
http://lists.xenproject.org/archives/html/xen-devel/2015-03/msg02645.html
Applied with my acks on 1,2&4 and Jan's on 3.
Re: [PATCH 4/4] hvmloader: add knob for fixed VGABIOS date string
In reply to Ian CampbellQuoted 10 lines
Quoted 1 line
Quoted 1 line · On 02.04.15 at 11:45, <[email protected]> wrote:
Quoted 7 lines · Olaf Hering
To allow reproducible builds of hvmloader introduce a make variable VGABIOS_REL_DATE="dd Mon yyyy" to provide a fixed date string. Without this change the hvmloader binary changes with every rebuild.
Signed-off-by Olaf Hering <[email protected]>Cc Ian Jackson <[email protected]>Cc Stefano Stabellini <[email protected]>
Quoted 5 lines
Acked-by Ian Campbell <[email protected]>It's not clear if vgabios should be maintained by us tools folks or if it should have been taken under the hvmloader umbrella and maintained by the hypervisor folks.
I'm not sure either - hvmloader is really code we grew and hence maintaining it together with its hypervisor side makes sense. For the various firmware blobs, otoh, I think they match more closely with the qemu/tools pattern.
Jan
Re: [PATCH 4/4] hvmloader: add knob for fixed VGABIOS date string
Quoted 12 lines · Jan Beulich
Quoted 12 lines
Quoted 1 line
Quoted 1 line · On 02.04.15 at 11:45, <[email protected]> wrote:
Quoted 7 lines · Olaf Hering
To allow reproducible builds of hvmloader introduce a make variable VGABIOS_REL_DATE="dd Mon yyyy" to provide a fixed date string. Without this change the hvmloader binary changes with every rebuild.
Signed-off-by Olaf Hering <[email protected]>Cc Ian Jackson <[email protected]>Cc Stefano Stabellini <[email protected]>Acked-by Ian Campbell <[email protected]>
Quoted 8 lines
Quoted 3 lines
It's not clear if vgabios should be maintained by us tools folks or if it should have been taken under the hvmloader umbrella and maintained by the hypervisor folks.
I'm not sure either - hvmloader is really code we grew and hence maintaining it together with its hypervisor side makes sense. For the various firmware blobs, otoh, I think they match more closely with the qemu/tools pattern.
OK, I think that makes sense.
We have specific maintainers for OVMF and SeaBIOS, I think the other stuff (rombios and vgabios) is frozen/inactive enough (and specific to qemu-trad) that we can muddle through via the tools/* umbrella maintainership.
I think ipxe is only used with trad too, but I'm not sure if it is quite so inactive or if someone ought to be keeping an eye on e.g. new upstream versions. I think we can just continue as we have been there too.
Ian.