diff options
author | Christophe Fergeau <cfergeau@redhat.com> | 2014-02-14 14:25:32 +0100 |
---|---|---|
committer | Christophe Fergeau <cfergeau@redhat.com> | 2014-02-20 11:52:33 +0100 |
commit | aece5f02f62d6d482404c78abda2e58c168f54d6 (patch) | |
tree | 6b6290f6dbe3ae6ae1c04108d6b99e5a45593eb6 | |
parent | d28d6e11d20a562a93f23edf1e2a41019ecf6be0 (diff) | |
download | spice-gtk-aece5f02f62d6d482404c78abda2e58c168f54d6.tar.gz spice-gtk-aece5f02f62d6d482404c78abda2e58c168f54d6.tar.xz spice-gtk-aece5f02f62d6d482404c78abda2e58c168f54d6.zip |
build-sys: Don't build tests when not building static libs
The tests rely on static linking in order to get access to symbols which
are not exported in spice-gtk shared libraries. When build of static
libraries is disabled with --disable-static, we should not attempt to build
the tests as this will result in link errors.
-rw-r--r-- | Makefile.am | 6 | ||||
-rw-r--r-- | configure.ac | 2 |
2 files changed, 7 insertions, 1 deletions
diff --git a/Makefile.am b/Makefile.am index ab10f5f..8add19f 100644 --- a/Makefile.am +++ b/Makefile.am @@ -1,7 +1,11 @@ ACLOCAL_AMFLAGS = -I m4 NULL = -SUBDIRS = spice-common gtk po doc data tests +SUBDIRS = spice-common gtk po doc data + +if BUILD_TESTS +SUBDIRS += tests +endif if HAVE_INTROSPECTION if WITH_VALA diff --git a/configure.ac b/configure.ac index 24416a9..e2dd742 100644 --- a/configure.ac +++ b/configure.ac @@ -696,6 +696,8 @@ AC_SUBST(SPICE_GTK_REQUIRES) m4_ifdef([AM_SILENT_RULES],[AM_SILENT_RULES([yes])]) +AM_CONDITIONAL([BUILD_TESTS], [test x"$enable_static" = xyes]) + AC_OUTPUT([ Makefile spice-client-glib-2.0.pc |