mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-23 06:05:27 +00:00
meson: src: build libvirt_driver_admin.a static lib
Signed-off-by: Pavel Hrdina <phrdina@redhat.com> Reviewed-by: Peter Krempa <pkrempa@redhat.com> Reviewed-by: Neal Gompa <ngompa13@gmail.com>
This commit is contained in:
parent
9e24d677a0
commit
cb91468c98
@ -3,41 +3,11 @@
|
||||
ADMIN_PROTOCOL = $(srcdir)/admin/admin_protocol.x
|
||||
|
||||
ADMIN_PROTOCOL_GENERATED = \
|
||||
admin/admin_protocol.c \
|
||||
admin/admin_protocol.h \
|
||||
admin/admin_client.h \
|
||||
admin/admin_server_dispatch_stubs.h \
|
||||
$(NULL)
|
||||
|
||||
BUILT_SOURCES += $(ADMIN_PROTOCOL_GENERATED)
|
||||
|
||||
admin/admin_server_dispatch.c: admin/admin_server_dispatch_stubs.h
|
||||
|
||||
noinst_LTLIBRARIES += libvirt_driver_admin.la
|
||||
libvirt_driver_admin_la_SOURCES = \
|
||||
admin/admin_server.c \
|
||||
admin/admin_server.h \
|
||||
admin/admin_server_dispatch.c \
|
||||
admin/admin_server_dispatch.h \
|
||||
$(NULL)
|
||||
nodist_libvirt_driver_admin_la_SOURCES = \
|
||||
$(ADMIN_PROTOCOL_GENERATED)
|
||||
libvirt_driver_admin_la_CFLAGS = \
|
||||
$(AM_CFLAGS) \
|
||||
$(XDR_CFLAGS) \
|
||||
-I$(top_srcdir)/src/admin \
|
||||
-I$(top_builddir)/src/admin \
|
||||
-I$(top_srcdir)/src/util \
|
||||
-I$(top_builddir)/src/rpc \
|
||||
$(NULL)
|
||||
libvirt_driver_admin_la_LDFLAGS = -module -avoid-version $(AM_LDFLAGS)
|
||||
|
||||
if WITH_SASL
|
||||
libvirt_driver_admin_la_CFLAGS += \
|
||||
$(SASL_CFLAGS) \
|
||||
$(NULL)
|
||||
endif WITH_SASL
|
||||
|
||||
GENERATED_SYM_FILES += admin/libvirt_admin.syms admin/libvirt_admin.def
|
||||
|
||||
ADMIN_SYM_FILES = $(srcdir)/admin/libvirt_admin_private.syms
|
||||
@ -116,12 +86,6 @@ admin/admin_client.h: $(srcdir)/rpc/gendispatch.pl \
|
||||
admin ADMIN $(ADMIN_PROTOCOL) \
|
||||
> admin/admin_client.h
|
||||
|
||||
admin/admin_server_dispatch_stubs.h: $(srcdir)/rpc/gendispatch.pl \
|
||||
$(ADMIN_PROTOCOL) Makefile.am
|
||||
$(AM_V_GEN)$(PERL) -w $(srcdir)/rpc/gendispatch.pl --mode=server \
|
||||
admin ADMIN $(ADMIN_PROTOCOL) \
|
||||
> admin/admin_server_dispatch_stubs.h
|
||||
|
||||
admin/libvirt_admin.syms: admin/libvirt_admin_public.syms $(ADMIN_SYM_FILES) \
|
||||
$(top_builddir)/config.status
|
||||
$(AM_V_GEN)rm -f $@-tmp $@ ; \
|
||||
|
50
src/admin/meson.build
Normal file
50
src/admin/meson.build
Normal file
@ -0,0 +1,50 @@
|
||||
admin_driver_sources = [
|
||||
'admin_server.c',
|
||||
'admin_server_dispatch.c',
|
||||
]
|
||||
|
||||
admin_driver_protocol = files('admin_protocol.x')
|
||||
|
||||
admin_driver_generated = []
|
||||
|
||||
admin_driver_generated += custom_target(
|
||||
'admin_protocol.h',
|
||||
input: admin_driver_protocol,
|
||||
output: 'admin_protocol.h',
|
||||
command: [
|
||||
genprotocol_prog, rpcgen_prog, '-h', '@INPUT@', '@OUTPUT@',
|
||||
],
|
||||
)
|
||||
|
||||
admin_driver_generated += custom_target(
|
||||
'admin_protocol.c',
|
||||
input: admin_driver_protocol,
|
||||
output: 'admin_protocol.c',
|
||||
command: [
|
||||
genprotocol_prog, rpcgen_prog, '-c', '@INPUT@', '@OUTPUT@',
|
||||
],
|
||||
)
|
||||
|
||||
admin_driver_generated += custom_target(
|
||||
'admin_server_dispatch_stubs.h',
|
||||
input: admin_driver_protocol,
|
||||
output: 'admin_server_dispatch_stubs.h',
|
||||
command: [
|
||||
gendispatch_prog, '--mode=server', 'admin', 'ADMIN', '@INPUT@',
|
||||
],
|
||||
capture: true,
|
||||
)
|
||||
|
||||
admin_driver_lib = static_library(
|
||||
'virt_admin_driver',
|
||||
[
|
||||
admin_driver_sources,
|
||||
admin_driver_generated,
|
||||
],
|
||||
dependencies: [
|
||||
rpc_dep,
|
||||
sasl_dep,
|
||||
src_dep,
|
||||
xdr_dep,
|
||||
],
|
||||
)
|
@ -90,3 +90,5 @@ src_dep = declare_dependency(
|
||||
subdir('conf')
|
||||
subdir('rpc')
|
||||
subdir('access')
|
||||
|
||||
subdir('admin')
|
||||
|
@ -107,3 +107,8 @@ virt_rpc_client_lib = static_library(
|
||||
)
|
||||
|
||||
rpc_inc_dir = include_directories('.')
|
||||
|
||||
rpc_dep = declare_dependency(
|
||||
include_directories: [ rpc_inc_dir ],
|
||||
sources: [ rpc_gen_headers ],
|
||||
)
|
||||
|
Loading…
Reference in New Issue
Block a user