mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-11 09:17:52 +03:00
vz: build driver as module and don't register it on client's side
Make it possible to build vz driver as a module and don't link it with libvirt.so statically. Remove registering it on client's side as far as we start relying on daemon Signed-off-by: Maxim Nestratov <mnestratov@virtuozzo.com>
This commit is contained in:
parent
6e76738e54
commit
30c61901c8
@ -233,6 +233,10 @@ if WITH_VBOX
|
||||
libvirtd_LDADD += ../src/libvirt_driver_vbox.la
|
||||
endif WITH_VBOX
|
||||
|
||||
if WITH_VZ
|
||||
libvirtd_LDADD += ../src/libvirt_driver_vz.la
|
||||
endif WITH_VZ
|
||||
|
||||
if WITH_STORAGE
|
||||
libvirtd_LDADD += ../src/libvirt_driver_storage.la
|
||||
endif WITH_STORAGE
|
||||
|
@ -102,6 +102,9 @@
|
||||
# include "nwfilter/nwfilter_driver.h"
|
||||
# endif
|
||||
#endif
|
||||
#ifdef WITH_VZ
|
||||
# include "vz/vz_driver.h"
|
||||
#endif
|
||||
|
||||
#include "configmake.h"
|
||||
|
||||
@ -390,6 +393,9 @@ static void daemonInitialize(void)
|
||||
# ifdef WITH_BHYVE
|
||||
virDriverLoadModule("bhyve");
|
||||
# endif
|
||||
# ifdef WITH_VZ
|
||||
virDriverLoadModule("vz");
|
||||
# endif
|
||||
#else
|
||||
# ifdef WITH_NETWORK
|
||||
networkRegister();
|
||||
@ -430,6 +436,9 @@ static void daemonInitialize(void)
|
||||
# ifdef WITH_BHYVE
|
||||
bhyveRegister();
|
||||
# endif
|
||||
# ifdef WITH_VZ
|
||||
vzRegister();
|
||||
# endif
|
||||
#endif
|
||||
}
|
||||
|
||||
|
@ -630,6 +630,7 @@ DRIVER_SOURCE_FILES = \
|
||||
$(NULL)
|
||||
|
||||
STATEFUL_DRIVER_SOURCE_FILES = \
|
||||
$(VZ_DRIVER_SOURCES) \
|
||||
$(BHYVE_DRIVER_SOURCES) \
|
||||
$(INTERFACE_DRIVER_SOURCES) \
|
||||
$(LIBXL_DRIVER_SOURCES) \
|
||||
@ -886,7 +887,7 @@ HYPERV_DRIVER_EXTRA_DIST = \
|
||||
hyperv/hyperv_wmi_generator.py \
|
||||
$(HYPERV_DRIVER_GENERATED)
|
||||
|
||||
VZ_DRIVER_SOURCES = \
|
||||
VZ_DRIVER_SOURCES = \
|
||||
vz/vz_driver.h \
|
||||
vz/vz_driver.c \
|
||||
vz/vz_utils.c \
|
||||
@ -1493,13 +1494,21 @@ libvirt_driver_hyperv_la_SOURCES = $(HYPERV_DRIVER_SOURCES)
|
||||
endif WITH_HYPERV
|
||||
|
||||
if WITH_VZ
|
||||
noinst_LTLIBRARIES += libvirt_driver_vz_impl.la
|
||||
libvirt_driver_vz_la_SOURCES =
|
||||
libvirt_driver_vz_la_LIBADD = libvirt_driver_vz_impl.la
|
||||
if WITH_DRIVER_MODULES
|
||||
mod_LTLIBRARIES += libvirt_driver_vz.la
|
||||
libvirt_driver_vz_la_LIBADD += ../gnulib/lib/libgnu.la
|
||||
libvirt_driver_vz_la_LDFLAGS = -module -avoid-version $(AM_LDFLAGS)
|
||||
else ! WITH_DRIVER_MODULES
|
||||
noinst_LTLIBRARIES += libvirt_driver_vz.la
|
||||
libvirt_la_BUILT_LIBADD += libvirt_driver_vz.la
|
||||
libvirt_driver_vz_la_CFLAGS = \
|
||||
endif ! WITH_DRIVER_MODULES
|
||||
libvirt_driver_vz_impl_la_CFLAGS = \
|
||||
-I$(srcdir)/conf $(AM_CFLAGS) \
|
||||
$(PARALLELS_SDK_CFLAGS) $(LIBNL_CFLAGS)
|
||||
libvirt_driver_vz_la_LIBADD = $(PARALLELS_SDK_LIBS) $(LIBNL_LIBS)
|
||||
libvirt_driver_vz_la_SOURCES = $(VZ_DRIVER_SOURCES)
|
||||
libvirt_driver_vz_impl_la_SOURCES = $(VZ_DRIVER_SOURCES)
|
||||
libvirt_driver_vz_impl_la_LIBADD = $(PARALLELS_SDK_LIBS) $(LIBNL_LIBS)
|
||||
endif WITH_VZ
|
||||
|
||||
if WITH_BHYVE
|
||||
|
@ -92,9 +92,6 @@
|
||||
#ifdef WITH_XENAPI
|
||||
# include "xenapi/xenapi_driver.h"
|
||||
#endif
|
||||
#ifdef WITH_VZ
|
||||
# include "vz/vz_driver.h"
|
||||
#endif
|
||||
#ifdef WITH_BHYVE
|
||||
# include "bhyve/bhyve_driver.h"
|
||||
#endif
|
||||
@ -433,10 +430,6 @@ virGlobalInit(void)
|
||||
if (xenapiRegister() == -1)
|
||||
goto error;
|
||||
# endif
|
||||
# ifdef WITH_VZ
|
||||
if (vzRegister() == -1)
|
||||
goto error;
|
||||
# endif
|
||||
#endif
|
||||
#ifdef WITH_REMOTE
|
||||
if (remoteRegister() == -1)
|
||||
|
@ -929,6 +929,11 @@ virGetSecret;
|
||||
virGetStoragePool;
|
||||
virGetStorageVol;
|
||||
virGetStream;
|
||||
virConnectCloseCallbackDataGetCallback;
|
||||
virNewConnectCloseCallbackData;
|
||||
virConnectCloseCallbackDataUnregister;
|
||||
virConnectCloseCallbackDataRegister;
|
||||
virConnectCloseCallbackDataCall;
|
||||
virInterfaceClass;
|
||||
virNetworkClass;
|
||||
virNodeDeviceClass;
|
||||
@ -937,6 +942,7 @@ virSecretClass;
|
||||
virStoragePoolClass;
|
||||
virStorageVolClass;
|
||||
virStreamClass;
|
||||
virConnectCloseCallbackDataClass;
|
||||
|
||||
|
||||
# fdstream.h
|
||||
@ -1304,6 +1310,7 @@ virCommandHandshakeWait;
|
||||
virCommandNew;
|
||||
virCommandNewArgList;
|
||||
virCommandNewArgs;
|
||||
virCommandNewVAList;
|
||||
virCommandNonblockingFDs;
|
||||
virCommandPassFD;
|
||||
virCommandPassFDGetFDIndex;
|
||||
|
Loading…
Reference in New Issue
Block a user