]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
meson: src: build libvirt_driver_bhyve_impl.a static library
authorPavel Hrdina <phrdina@redhat.com>
Wed, 17 Jun 2020 23:09:06 +0000 (01:09 +0200)
committerPavel Hrdina <phrdina@redhat.com>
Mon, 3 Aug 2020 07:27:04 +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>
src/bhyve/Makefile.inc.am
src/bhyve/meson.build [new file with mode: 0644]
src/meson.build

index f75194fd3c87040298b40bfd431bd49a675beae3..3433e6a3dabe1e6a97eb937b3b93a3bd02905f6e 100644 (file)
@@ -1,33 +1,9 @@
 # vim: filetype=automake
 
-BHYVE_DRIVER_SOURCES = \
-       bhyve/bhyve_capabilities.c \
-       bhyve/bhyve_capabilities.h \
-       bhyve/bhyve_command.c \
-       bhyve/bhyve_command.h \
-       bhyve/bhyve_conf.c \
-       bhyve/bhyve_conf.h \
-       bhyve/bhyve_parse_command.c \
-       bhyve/bhyve_parse_command.h \
-       bhyve/bhyve_device.c \
-       bhyve/bhyve_device.h \
-       bhyve/bhyve_domain.c \
-       bhyve/bhyve_domain.h \
-       bhyve/bhyve_driver.h \
-       bhyve/bhyve_driver.c \
-       bhyve/bhyve_monitor.c \
-       bhyve/bhyve_monitor.h \
-       bhyve/bhyve_process.c \
-       bhyve/bhyve_process.h \
-       bhyve/bhyve_utils.h \
-       $(NULL)
-
 DRIVER_SOURCE_FILES += $(addprefix $(srcdir)/,$(BHYVE_DRIVER_SOURCES))
 STATEFUL_DRIVER_SOURCE_FILES += $(addprefix $(srcdir)/,$(BHYVE_DRIVER_SOURCES))
 
-
 if WITH_BHYVE
-noinst_LTLIBRARIES += libvirt_driver_bhyve_impl.la
 libvirt_driver_bhyve_la_SOURCES =
 libvirt_driver_bhyve_la_LIBADD = \
        libvirt_driver_bhyve_impl.la \
@@ -37,16 +13,6 @@ libvirt_driver_bhyve_la_LIBADD = \
 mod_LTLIBRARIES += libvirt_driver_bhyve.la
 libvirt_driver_bhyve_la_LDFLAGS = $(AM_LDFLAGS_MOD_NOUNDEF)
 
-libvirt_driver_bhyve_impl_la_CFLAGS = \
-       -I$(srcdir)/access \
-       -I$(builddir)/access \
-       -I$(srcdir)/conf \
-       -I$(srcdir)/hypervisor \
-       $(AM_CFLAGS) \
-       $(NULL)
-libvirt_driver_bhyve_impl_la_LDFLAGS = $(AM_LDFLAGS)
-libvirt_driver_bhyve_impl_la_SOURCES = $(BHYVE_DRIVER_SOURCES)
-
 sbin_PROGRAMS += virtbhyved
 
 nodist_conf_DATA += bhyve/virtbhyved.conf
diff --git a/src/bhyve/meson.build b/src/bhyve/meson.build
new file mode 100644 (file)
index 0000000..a9af677
--- /dev/null
@@ -0,0 +1,28 @@
+bhyve_sources = files(
+  'bhyve_capabilities.c',
+  'bhyve_command.c',
+  'bhyve_conf.c',
+  'bhyve_parse_command.c',
+  'bhyve_device.c',
+  'bhyve_domain.c',
+  'bhyve_driver.c',
+  'bhyve_monitor.c',
+  'bhyve_process.c',
+)
+
+if conf.has('WITH_BHYVE')
+  bhyve_driver_impl = static_library(
+    'virt_driver_bhyve_impl',
+    [
+      bhyve_sources,
+    ],
+    dependencies: [
+      access_dep,
+      src_dep,
+    ],
+    include_directories: [
+      conf_inc_dir,
+      hypervisor_inc_dir,
+    ],
+  )
+endif
index cb35c599b3d365c191c4145cae923e270d70f91b..1212489e025d56ff2bc6a239e010e7f533b5ca50 100644 (file)
@@ -154,6 +154,7 @@ subdir('locking')
 subdir('logging')
 subdir('security')
 
+subdir('bhyve')
 subdir('esx')
 subdir('hyperv')
 subdir('openvz')