| From a790bfe8fa7b24b68cb6f9a1b7205fda2c6d558e Mon Sep 17 00:00:00 2001 |
| From: Bruce Ashfield <bruce.ashfield@windriver.com> |
| Date: Fri, 2 Aug 2013 11:38:43 -0400 |
| Subject: [PATCH] tools: add libvirt-net-rpc to virt-host-validate when TLS is |
| enabled |
| |
| When gnu-tls is enabled for libvirt references to virNetTLSInit are |
| generated in libvirt. Any binaries linking against libvirt, must also |
| link against libvirt-net-rpc which provides the implementation. |
| |
| Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com> |
| [ywei: rebased to libvirt-1.3.2] |
| Signed-off-by: Yunguo Wei <yunguo.wei@windriver.com> |
| --- |
| examples/Makefile.am | 19 +++++++++++++++++++ |
| tools/Makefile.am | 13 +++++++++++++ |
| 2 files changed, 32 insertions(+) |
| |
| diff --git a/examples/Makefile.am b/examples/Makefile.am |
| index 2adcefb..fff49d4 100644 |
| --- a/examples/Makefile.am |
| +++ b/examples/Makefile.am |
| @@ -39,6 +39,10 @@ INCLUDES = -I$(top_builddir)/include -I$(top_srcdir)/include -I$(top_srcdir) \ |
| LDADD = $(STATIC_BINARIES) $(WARN_CFLAGS) $(COVERAGE_LDFLAGS) \ |
| $(top_builddir)/src/libvirt.la $(top_builddir)/gnulib/lib/libgnu.la |
| |
| +if WITH_GNUTLS |
| +LDADD += $(top_builddir)/src/libvirt-net-rpc.la |
| +endif |
| + |
| noinst_PROGRAMS=dominfo/info1 dommigrate/dommigrate domsuspend/suspend \ |
| domtop/domtop hellolibvirt/hellolibvirt object-events/event-test \ |
| openauth/openauth rename/rename |
| @@ -52,6 +56,21 @@ object_events_event_test_SOURCES = object-events/event-test.c |
| openauth_openauth_SOURCES = openauth/openauth.c |
| rename_rename_SOURCES = rename/rename.c |
| |
| +if WITH_GNUTLS |
| +dominfo_info1_LDADD = $(top_builddir)/src/libvirt-net-rpc.la \ |
| + $(LDADD) \ |
| + $(NULL) |
| +domsuspend_suspend_LDADD = $(top_builddir)/src/libvirt-net-rpc.la \ |
| + $(LDADD) \ |
| + $(NULL) |
| +hellolibvirt_hellolibvirt_LDADD = $(top_builddir)/src/libvirt-net-rpc.la \ |
| + $(LDADD) \ |
| + $(NULL) |
| +openauth_openauth_LDADD = $(top_builddir)/src/libvirt-net-rpc.la \ |
| + $(LDADD) \ |
| + $(NULL) |
| +endif |
| + |
| if WITH_APPARMOR_PROFILES |
| apparmordir = $(sysconfdir)/apparmor.d/ |
| apparmor_DATA = \ |
| diff --git a/tools/Makefile.am b/tools/Makefile.am |
| index 0be3567..b3227a7 100644 |
| --- a/tools/Makefile.am |
| +++ b/tools/Makefile.am |
| @@ -169,6 +169,13 @@ virt_host_validate_LDADD = \ |
| ../gnulib/lib/libgnu.la \ |
| $(NULL) |
| |
| +if WITH_GNUTLS |
| +virt_host_validate_LDADD += ../src/libvirt-net-rpc.la \ |
| + ../gnulib/lib/libgnu.la \ |
| + $(NULL) |
| +endif |
| + |
| + |
| virt_host_validate_CFLAGS = \ |
| $(LIBXML_CFLAGS) \ |
| $(WARN_CFLAGS) \ |
| @@ -256,6 +263,12 @@ virt_admin_CFLAGS = \ |
| $(READLINE_CFLAGS) |
| BUILT_SOURCES = |
| |
| +if WITH_GNUTLS |
| +virsh_LDADD += ../src/libvirt-net-rpc.la \ |
| + ../gnulib/lib/libgnu.la \ |
| + $(NULL) |
| +endif |
| + |
| if WITH_WIN_ICON |
| virsh_LDADD += virsh_win_icon.$(OBJEXT) |
| |
| -- |
| 1.9.1 |
| |