]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
meson: tools: build libvirt_shell.a static library
authorPavel Hrdina <phrdina@redhat.com>
Wed, 24 Jun 2020 11:32:30 +0000 (13:32 +0200)
committerPavel Hrdina <phrdina@redhat.com>
Mon, 3 Aug 2020 07:27:05 +0000 (09:27 +0200)
Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
Reviewed-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Neal Gompa <ngompa13@gmail.com>
tools/Makefile.am
tools/meson.build

index 94e5f0c0b0dfc86d117b6479aff6ef3163739dd7..1848338adb742932a0aef32cd6d278fbf5ba955f 100644 (file)
@@ -64,24 +64,7 @@ virt-sanlock-cleanup: virt-sanlock-cleanup.in Makefile
            -e 's|[@]localstatedir@|$(localstatedir)|' < $< > $@ \
            || (rm $@ && exit 1) && chmod +x $@
 
-noinst_LTLIBRARIES = libvirt_shell.la
-libvirt_shell_la_CFLAGS = \
-               $(AM_CFLAGS) \
-               $(READLINE_CFLAGS) \
-               $(NULL)
-libvirt_shell_la_LDFLAGS = \
-               $(AM_LDFLAGS) \
-               $(COVERAGE_LDFLAGS) \
-               $(NULL)
-libvirt_shell_la_LIBADD = \
-               ../src/libvirt.la \
-               $(LIBXML_LIBS) \
-               $(READLINE_LIBS) \
-               $(GLIB_LIBS) \
-               $(NULL)
-libvirt_shell_la_SOURCES = \
-               vsh.c vsh.h \
-               vsh-table.c vsh-table.h
+noinst_LTLIBRARIES =
 
 virt_host_validate_SOURCES = \
                virt-host-validate.c \
index 43a772a40cccd27a81ced0cbfdfd60a4c2fdb1c9..f4df906d27fff1d4a4cf66f0c7e26cbce74594f5 100644 (file)
@@ -18,3 +18,21 @@ tools_dep = declare_dependency(
     + libvirt_no_undefined
   ),
 )
+
+libvirt_shell_lib = static_library(
+  'virt_shell',
+  [
+    'vsh.c',
+    'vsh-table.c',
+  ],
+  dependencies: [
+    tools_dep,
+    readline_dep,
+  ],
+  link_with: [
+    libvirt_lib,
+  ],
+  link_args: [
+    coverage_flags,
+  ],
+)