diff mbox series

[3/4] build: move xenlibs-dependencies make definition to uselibs.mk

Message ID 20241005151548.29184-4-jgross@suse.com (mailing list archive)
State New
Headers show
Series stubdom: prepare more fine grained Xen library usage | expand

Commit Message

Jürgen Groß Oct. 5, 2024, 3:15 p.m. UTC
In order to be able to use the xenlibs-dependencies macro from stubdom
build, move it to tools/libs/uselibs.mk, which is included from
current users and stubdom/Makefile.

No functional change intended.

Signed-off-by: Juergen Gross <jgross@suse.com>
---
 tools/Rules.mk        | 7 -------
 tools/libs/uselibs.mk | 7 +++++++
 2 files changed, 7 insertions(+), 7 deletions(-)

Comments

Anthony PERARD Oct. 7, 2024, 1:14 p.m. UTC | #1
On Sat, Oct 05, 2024 at 05:15:47PM +0200, Juergen Gross wrote:
> In order to be able to use the xenlibs-dependencies macro from stubdom
> build, move it to tools/libs/uselibs.mk, which is included from
> current users and stubdom/Makefile.
> 
> No functional change intended.
> 
> Signed-off-by: Juergen Gross <jgross@suse.com>

Acked-by: Anthony PERARD <anthony.perard@vates.tech>

Thanks,
diff mbox series

Patch

diff --git a/tools/Rules.mk b/tools/Rules.mk
index e2289c25b4..6bd636709f 100644
--- a/tools/Rules.mk
+++ b/tools/Rules.mk
@@ -81,13 +81,6 @@  endif
 # include any CFLAGS or LDLIBS relating to libbar or libbaz unless
 # they use those libraries directly (not via libfoo) too.
 
-# Give the list of Xen library that the libraries in $(1) are linked against,
-# directly or indirectly.
-define xenlibs-dependencies
-    $(sort $(foreach lib,$(1), \
-        $(USELIBS_$(lib)) $(call xenlibs-dependencies,$(USELIBS_$(lib)))))
-endef
-
 # Flags for linking recursive dependencies of Xen libraries in $(1)
 define xenlibs-rpath
     $(addprefix -Wl$(comma)-rpath-link=$(XEN_ROOT)/tools/libs/,$(call xenlibs-dependencies,$(1)))
diff --git a/tools/libs/uselibs.mk b/tools/libs/uselibs.mk
index efd7a475ba..7aa8d83e06 100644
--- a/tools/libs/uselibs.mk
+++ b/tools/libs/uselibs.mk
@@ -31,3 +31,10 @@  USELIBS_light := toollog evtchn toolcore ctrl store hypfs guest
 LIBS_LIBS += util
 USELIBS_util := light
 FILENAME_util := xlutil
+
+# Give the list of Xen library that the libraries in $(1) are linked against,
+# directly or indirectly.
+define xenlibs-dependencies
+    $(sort $(foreach lib,$(1), \
+        $(USELIBS_$(lib)) $(call xenlibs-dependencies,$(USELIBS_$(lib)))))
+endef