Skip to contentSkip to conversation

stubdom: reduce xenstore library dependencies

PATCH In review Juergen Gross 4 participants 7 messages Oct 10, 2024 – Oct 11, 2024

lore
Share & tools
lore
#0 lore raw

cover stubdom: reduce xenstore library dependencies

Instead of letting the xenstore stubdoms depend on libxenguest and with that on basically all Xen libraries, only let it depend on the actually used libraries.

This is in preparation of removing the libxenctrl dependency from Xenstore and with that the capability to use xenstore-stubdom on multiple hypervisor versions.

Juergen Gross (3):
config: update Mini-OS commit
tools/xenstored: remove unneeded libxenguest reference
stubdom: use real lib dependencies for xenstore stubdoms

 Config.mk                       | 2 +-
 stubdom/Makefile                | 6 ++++--
 tools/xenstored/Makefile.common | 1 -
 3 files changed, 5 insertions(+), 4 deletions(-)
Signature · 1 line
2.43.0
#1 lore raw

PATCH 1/3 config: update Mini-OS commit

Update the Mini-OS upstream revision.

---
 Config.mk | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
Config.mk +1 -1
index 1a3938b6c4..6dd2f9439c 100644
@@ -224,7 +224,7 @@ QEMU_UPSTREAM_URL ?= https://xenbits.xen.org/git-http/qemu-xen.git
 QEMU_UPSTREAM_REVISION ?= master
 
 MINIOS_UPSTREAM_URL ?= https://xenbits.xen.org/git-http/mini-os.git
-MINIOS_UPSTREAM_REVISION ?= 8b038c7411ae7e823eaf6d15d5efbe037a07197a
+MINIOS_UPSTREAM_REVISION ?= 80ef70f92cb7b95ef48deea1157f2194b10b8c05
 
 SEABIOS_UPSTREAM_URL ?= https://xenbits.xen.org/git-http/seabios.git
 SEABIOS_UPSTREAM_REVISION ?= rel-1.16.3
Signature · 1 line
2.43.0
#2 lore raw

PATCH 2/3 tools/xenstored: remove unneeded libxenguest reference

In reply to Juergen Gross

Today the xenstored Makefile contains an unneeded reference to the not used libxenguest library.

Remove it.

---
 tools/xenstored/Makefile.common | 1 -
 1 file changed, 1 deletion(-)
tools/xenstored/Makefile.common +0 -1
index ef63ef650c..27fdb3b49e 100644
@@ -13,7 +13,6 @@ XENSTORED_OBJS-$(CONFIG_MiniOS) += minios.o lu_minios.o
 CFLAGS += -include $(XEN_ROOT)/tools/config.h
 CFLAGS += $(CFLAGS_libxenevtchn)
 CFLAGS += $(CFLAGS_libxenctrl)
-CFLAGS += $(CFLAGS_libxenguest)
 CFLAGS += $(CFLAGS_libxentoolcore)
 
 $(XENSTORED_OBJS-y): CFLAGS += $(CFLAGS_libxengnttab)
Signature · 1 line
2.43.0
Reviewed-by on v1 2/3
#3 lore raw

Re: [PATCH 2/3] tools/xenstored: remove unneeded libxenguest reference

Quoted 6 lines · Juergen Gross

Today the xenstored Makefile contains an unneeded reference to the not used libxenguest library.

Remove it.

Thanks,

Signature · 5 lines
Anthony Perard | Vates XCP-ng Developer

XCP-ng & Xen Orchestra - Vates solutions

web: https://vates.tech
#4 lore raw

PATCH 3/3 stubdom: use real lib dependencies for xenstore stubdoms

In reply to Juergen Gross

Today the build of Xenstore stubdoms depend on libxenguest just because libxenguest depends on all needed libraries. In reality there is no dependency on libxenguest for Xenstore stubdoms.

Use the actual dependencies instead.

---
 stubdom/Makefile | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)
stubdom/Makefile +4 -2
index 6ed4253b25..2a81af28a1 100644
@@ -523,12 +523,14 @@ else
 pv-grub-if-enabled:
 endif
 
+XENSTORE_DEPS := libxenevtchn libxengnttab libxenctrl
+
 .PHONY: xenstore-stubdom
-xenstore-stubdom: mini-os-$(XEN_TARGET_ARCH)-xenstore libxenguest xenstore
+xenstore-stubdom: mini-os-$(XEN_TARGET_ARCH)-xenstore $(XENSTORE_DEPS) xenstore
 	DEF_CPPFLAGS="$(TARGET_CPPFLAGS)" DEF_CFLAGS="$(TARGET_CFLAGS)" DEF_LDFLAGS="$(TARGET_LDFLAGS)" MINIOS_CONFIG="$(CURDIR)/xenstore-minios.gen.cfg" $(MAKE) DESTDIR= -C $(MINI_OS) OBJ_DIR=$(CURDIR)/$< APP_OBJS=$(CURDIR)/xenstore/xenstored.a
 
 .PHONY: xenstorepvh-stubdom
-xenstorepvh-stubdom: mini-os-$(XEN_TARGET_ARCH)-xenstorepvh libxenguest xenstorepvh
+xenstorepvh-stubdom: mini-os-$(XEN_TARGET_ARCH)-xenstorepvh $(XENSTORE_DEPS) xenstorepvh
 	DEF_CPPFLAGS="$(TARGET_CPPFLAGS)" DEF_CFLAGS="$(TARGET_CFLAGS)" DEF_LDFLAGS="$(TARGET_LDFLAGS)" MINIOS_CONFIG="$(CURDIR)/xenstorepvh-minios.gen.cfg" $(MAKE) DESTDIR= -C $(MINI_OS) OBJ_DIR=$(CURDIR)/$< APP_OBJS=$(CURDIR)/xenstorepvh/xenstored.a
 
 #########
Signature · 1 line
2.43.0
Reviewed-by on v1 3/3
#5 lore raw

Re: [PATCH 3/3] stubdom: use real lib dependencies for xenstore stubdoms

Juergen Gross, le jeu. 10 oct. 2024 17:54:59 +0200, a ecrit:

Quoted 7 lines

Today the build of Xenstore stubdoms depend on libxenguest just because libxenguest depends on all needed libraries. In reality there is no dependency on libxenguest for Xenstore stubdoms.

Use the actual dependencies instead.

Quoted 27 lines
---
 stubdom/Makefile | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)
stubdom/Makefile +4 -2
index 6ed4253b25..2a81af28a1 100644
@@ -523,12 +523,14 @@ else
 pv-grub-if-enabled:
 endif
 
+XENSTORE_DEPS := libxenevtchn libxengnttab libxenctrl
+
 .PHONY: xenstore-stubdom
-xenstore-stubdom: mini-os-$(XEN_TARGET_ARCH)-xenstore libxenguest xenstore
+xenstore-stubdom: mini-os-$(XEN_TARGET_ARCH)-xenstore $(XENSTORE_DEPS) xenstore
 	DEF_CPPFLAGS="$(TARGET_CPPFLAGS)" DEF_CFLAGS="$(TARGET_CFLAGS)" DEF_LDFLAGS="$(TARGET_LDFLAGS)" MINIOS_CONFIG="$(CURDIR)/xenstore-minios.gen.cfg" $(MAKE) DESTDIR= -C $(MINI_OS) OBJ_DIR=$(CURDIR)/$< APP_OBJS=$(CURDIR)/xenstore/xenstored.a
 
 .PHONY: xenstorepvh-stubdom
-xenstorepvh-stubdom: mini-os-$(XEN_TARGET_ARCH)-xenstorepvh libxenguest xenstorepvh
+xenstorepvh-stubdom: mini-os-$(XEN_TARGET_ARCH)-xenstorepvh $(XENSTORE_DEPS) xenstorepvh
 	DEF_CPPFLAGS="$(TARGET_CPPFLAGS)" DEF_CFLAGS="$(TARGET_CFLAGS)" DEF_LDFLAGS="$(TARGET_LDFLAGS)" MINIOS_CONFIG="$(CURDIR)/xenstorepvh-minios.gen.cfg" $(MAKE) DESTDIR= -C $(MINI_OS) OBJ_DIR=$(CURDIR)/$< APP_OBJS=$(CURDIR)/xenstorepvh/xenstored.a
 
 #########
Signature · 1 line
2.43.0
Acked-by on the v1 series
#6 lore raw
In reply to Juergen Gross
Quoted 13 lines · Juergen Gross

Instead of letting the xenstore stubdoms depend on libxenguest and with that on basically all Xen libraries, only let it depend on the actually used libraries.

This is in preparation of removing the libxenctrl dependency from Xenstore and with that the capability to use xenstore-stubdom on multiple hypervisor versions.

Juergen Gross (3):
config: update Mini-OS commit
tools/xenstored: remove unneeded libxenguest reference
stubdom: use real lib dependencies for xenstore stubdoms

Quoted 5 lines
 Config.mk                       | 2 +-
 stubdom/Makefile                | 6 ++++--
 tools/xenstored/Makefile.common | 1 -
 3 files changed, 5 insertions(+), 4 deletions(-)