[gjs] tests: Force generation of shared libraries
- From: Colin Walters <walters src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gjs] tests: Force generation of shared libraries
- Date: Fri, 25 Oct 2013 15:57:37 +0000 (UTC)
commit f87c38787640f639da5ebf73014bbcf3b98cd9fc
Author: Colin Walters <walters verbum org>
Date: Fri Oct 25 16:56:37 2013 +0100
tests: Force generation of shared libraries
If installed tests are disabled, we need to force libtool
to generate .so files that can be dlopened by introspection.
https://bugzilla.gnome.org/710697
Makefile-insttest.am | 11 ++++++++---
1 files changed, 8 insertions(+), 3 deletions(-)
---
diff --git a/Makefile-insttest.am b/Makefile-insttest.am
index 2ebdc77..e63709f 100644
--- a/Makefile-insttest.am
+++ b/Makefile-insttest.am
@@ -37,10 +37,15 @@ else
check_LTLIBRARIES += libregress.la libwarnlib.la libgimarshallingtests.la
endif
+# This rpath /nowhere thing is the libtool upstream recommended way to
+# force generation of shared libraries, which we need in order for the
+# tests to work uninstalled.
+common_test_ldflags = -avoid-version -rpath /nowhere $(GJS_LIBS)
+
nodist_libregress_la_SOURCES = $(GI_DATADIR)/tests/regress.c $(GI_DATADIR)/tests/regress.h
libregress_la_CPPFLAGS = $(AM_CPPFLAGS)
libregress_la_CFLAGS = $(GJS_CFLAGS)
-libregress_la_LDFLAGS = -avoid-version $(GJS_LIBS)
+libregress_la_LDFLAGS = $(common_test_ldflags)
libregress_scannerflags_includes = --include=Gio-2.0
if ENABLE_CAIRO
libregress_la_CFLAGS += $(GJS_CAIRO_CFLAGS)
@@ -51,10 +56,10 @@ libregress_la_CPPFLAGS += -D_GI_DISABLE_CAIRO
endif
nodist_libwarnlib_la_SOURCES = $(GI_DATADIR)/tests/warnlib.c $(GI_DATADIR)/tests/warnlib.h
libwarnlib_la_CFLAGS = $(GJS_CFLAGS)
-libwarnlib_la_LDFLAGS = -avoid-version $(GJS_LIBS)
+libwarnlib_la_LDFLAGS = $(common_test_ldflags)
nodist_libgimarshallingtests_la_SOURCES = $(GI_DATADIR)/tests/gimarshallingtests.c
$(GI_DATADIR)/tests/gimarshallingtests.h
libgimarshallingtests_la_CFLAGS = $(GJS_CFLAGS)
-libgimarshallingtests_la_LDFLAGS = -avoid-version $(GJS_LIBS)
+libgimarshallingtests_la_LDFLAGS = $(common_test_ldflags)
Regress-1.0.gir: libregress.la
Regress_1_0_gir_LIBS = libregress.la
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]