aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel P. Berrange <berrange@redhat.com>2012-07-24 14:37:48 +0100
committerDaniel P. Berrange <berrange@redhat.com>2012-07-27 10:54:38 +0100
commit536a1d7d0a722383d45c70173f4a021eef3ad639 (patch)
tree4235f88baf957b44885ab9c9e875228c45b302d8 /src/Makefile.am
parentRemove accidentally commited virNetClientSetEOFNotify symbol (diff)
downloadlibvirt-536a1d7d0a722383d45c70173f4a021eef3ad639.tar.gz
libvirt-536a1d7d0a722383d45c70173f4a021eef3ad639.tar.bz2
libvirt-536a1d7d0a722383d45c70173f4a021eef3ad639.zip
Add a test case that checks there are no bogus entries in .syms
During refactoring of code, it has proved common to forget to remove old symbols from the .syms file. While the Win32 linker will complain about this, the Linux ELF linker does not. The new test case validates that every symbol listed in the .syms file actually exists in the built ELF libraries. Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
Diffstat (limited to 'src/Makefile.am')
-rw-r--r--src/Makefile.am42
1 files changed, 41 insertions, 1 deletions
diff --git a/src/Makefile.am b/src/Makefile.am
index 93fcf3bc8..13641cea4 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -306,6 +306,46 @@ PDWTAGS = \
echo 'WARNING: install the dwarves package to get pdwtags' >&2; \
fi
+ALL_ELF_LIBS = $(builddir)/.libs/libvirt.so
+if WITH_DRIVER_MODULES
+if WITH_QEMU
+ALL_ELF_LIBS += $(builddir)/.libs/libvirt_driver_qemu.so
+endif
+if WITH_LXC
+ALL_ELF_LIBS += $(builddir)/.libs/libvirt_driver_lxc.so
+endif
+if WITH_UML
+ALL_ELF_LIBS += $(builddir)/.libs/libvirt_driver_uml.so
+endif
+if WITH_XEN
+ALL_ELF_LIBS += $(builddir)/.libs/libvirt_driver_xen.so
+endif
+if WITH_LIBXL
+ALL_ELF_LIBS += $(builddir)/.libs/libvirt_driver_libxl.so
+endif
+if WITH_NETCF
+ALL_ELF_LIBS += $(builddir)/.libs/libvirt_driver_interface.so
+endif
+if WITH_NETWORK
+ALL_ELF_LIBS += $(builddir)/.libs/libvirt_driver_network.so
+endif
+if WITH_NODE_DEVICES
+ALL_ELF_LIBS += $(builddir)/.libs/libvirt_driver_nodedev.so
+endif
+if WITH_NWFILTER
+ALL_ELF_LIBS += $(builddir)/.libs/libvirt_driver_nwfilter.so
+endif
+if WITH_SECRETS
+ALL_ELF_LIBS += $(builddir)/.libs/libvirt_driver_secret.so
+endif
+if WITH_STORAGE
+ALL_ELF_LIBS += $(builddir)/.libs/libvirt_driver_storage.so
+endif
+endif
+
+check-symfile: libvirt.syms $(ALL_ELF_LIBS:%.so=%.la)
+ $(AM_V_GEN)$(PERL) $(srcdir)/check-symfile.pl libvirt.syms $(ALL_ELF_LIBS)
+
PROTOCOL_STRUCTS = \
$(srcdir)/remote_protocol-structs \
$(srcdir)/qemu_protocol-structs \
@@ -328,7 +368,7 @@ else !WITH_REMOTE
check-protocol:
endif
EXTRA_DIST += $(PROTOCOL_STRUCTS)
-check-local: check-protocol
+check-local: check-protocol check-symfile
.PHONY: check-protocol $(PROTOCOL_STRUCTS:structs=struct)
# Mock driver, covering domains, storage, networks, etc