[PATCH] tools/helpers: fix Arm build by excluding init-xenstore-domain

Juergen Gross posted 1 patch 3 years, 6 months ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/xen tags/patchew/20201025054546.4960-1-jgross@suse.com
Maintainers: Ian Jackson <iwj@xenproject.org>, Wei Liu <wl@xen.org>
tools/helpers/Makefile | 12 ++++--------
1 file changed, 4 insertions(+), 8 deletions(-)
[PATCH] tools/helpers: fix Arm build by excluding init-xenstore-domain
Posted by Juergen Gross 3 years, 6 months ago
The support for PVH xenstore-stubdom has broken the Arm build.

Xenstore stubdom isn't supported on Arm, so there is no need to build
the init-xenstore-domain helper.

Build the helper on x86 only.

Signed-off-by: Juergen Gross <jgross@suse.com>
---
 tools/helpers/Makefile | 12 ++++--------
 1 file changed, 4 insertions(+), 8 deletions(-)

diff --git a/tools/helpers/Makefile b/tools/helpers/Makefile
index f759528322..1bcc97ea8a 100644
--- a/tools/helpers/Makefile
+++ b/tools/helpers/Makefile
@@ -7,8 +7,10 @@ include $(XEN_ROOT)/tools/Rules.mk
 
 PROGS += xen-init-dom0
 ifeq ($(CONFIG_Linux),y)
+ifeq ($(CONFIG_X86),y)
 PROGS += init-xenstore-domain
 endif
+endif
 
 XEN_INIT_DOM0_OBJS = xen-init-dom0.o init-dom-json.o
 $(XEN_INIT_DOM0_OBJS): CFLAGS += $(CFLAGS_libxentoollog)
@@ -37,17 +39,11 @@ init-xenstore-domain: $(INIT_XENSTORE_DOMAIN_OBJS)
 .PHONY: install
 install: all
 	$(INSTALL_DIR) $(DESTDIR)$(LIBEXEC_BIN)
-	$(INSTALL_PROG) xen-init-dom0 $(DESTDIR)$(LIBEXEC_BIN)
-ifeq ($(CONFIG_Linux),y)
-	$(INSTALL_PROG) init-xenstore-domain $(DESTDIR)$(LIBEXEC_BIN)
-endif
+	for i in $(PROGS); do $(INSTALL_PROG) $$i $(DESTDIR)$(LIBEXEC_BIN); done
 
 .PHONY: uninstall
 uninstall:
-ifeq ($(CONFIG_Linux),y)
-	rm -f $(DESTDIR)$(LIBEXEC_BIN)/init-xenstore-domain
-endif
-	rm -f $(DESTDIR)$(LIBEXEC_BIN)/xen-init-dom0
+	for i in $(PROGS); do rm -f $(DESTDIR)$(LIBEXEC_BIN)/$$i; done
 
 .PHONY: clean
 clean:
-- 
2.26.2


Re: [PATCH] tools/helpers: fix Arm build by excluding init-xenstore-domain
Posted by Wei Liu 3 years, 5 months ago
On Sun, Oct 25, 2020 at 06:45:46AM +0100, Juergen Gross wrote:
> The support for PVH xenstore-stubdom has broken the Arm build.
> 
> Xenstore stubdom isn't supported on Arm, so there is no need to build
> the init-xenstore-domain helper.
> 
> Build the helper on x86 only.
> 
> Signed-off-by: Juergen Gross <jgross@suse.com>

Acked-by: Wei Liu <wl@xen.org>

I have applied this patch to unblock osstest.