From 1ac5495bc41c5097b66eeb3989f657209fae7c76 Mon Sep 17 00:00:00 2001 From: Simon McVittie Date: Fri, 23 Mar 2012 15:06:00 +0000 Subject: [PATCH 3/4] Install non-ABI-stable libraries used by plugins to a private directory Similar to https://bugs.freedesktop.org/show_bug.cgi?id=46417 in Gabble. --- configure.ac | 11 ++++++++++- salut/telepathy-salut-uninstalled.pc.in | 1 + salut/telepathy-salut.pc.in | 3 ++- src/Makefile.am | 4 ++-- 4 files changed, 15 insertions(+), 4 deletions(-) diff --git a/configure.ac b/configure.ac index f345e8c..578dbd9 100644 --- a/configure.ac +++ b/configure.ac @@ -273,6 +273,15 @@ AC_ARG_ENABLE(submodules, build_submodules=$enableval, build_submodules=yes ) +# These must contain "exec" for automake to work right (install-exec, +# not install-data). +# +# Private directory for Wocky and the salut-plugins library +if test "x$pluginexeclibdir" = x; then + pluginexeclibdir='${libdir}/telepathy/salut-0/lib' +fi +AC_ARG_VAR([pluginexeclibdir]) + dnl plugins AC_ARG_ENABLE(plugins, AC_HELP_STRING([--disable-plugins], @@ -317,7 +326,7 @@ fi # submodule's configure. prev_ac_configure_args=$ac_configure_args -ac_configure_args="$ac_configure_args --with-installed-headers=${wocky_install_headers_dir} --enable-shared-suffix=${PACKAGE}-${VERSION}" +ac_configure_args="$ac_configure_args --with-installed-headers=${wocky_install_headers_dir} --enable-shared-suffix=${PACKAGE}-${VERSION} --libdir=${pluginexeclibdir}" if test "x$ENABLE_CODING_STYLE_CHECKS" = xyes ; then ac_configure_args="$ac_configure_args --enable-coding-style-checks" diff --git a/salut/telepathy-salut-uninstalled.pc.in b/salut/telepathy-salut-uninstalled.pc.in index 018ac92..ba10113 100644 --- a/salut/telepathy-salut-uninstalled.pc.in +++ b/salut/telepathy-salut-uninstalled.pc.in @@ -3,6 +3,7 @@ exec_prefix=@exec_prefix@ abs_top_srcdir=@abs_top_srcdir@ abs_top_builddir=@abs_top_builddir@ libdir=@libdir@ +pluginexeclibdir=@pluginexeclibdir@ plugindir=${libdir}/telepathy/salut-0 salutpath=${abs_top_builddir}/src/telepathy-salut diff --git a/salut/telepathy-salut.pc.in b/salut/telepathy-salut.pc.in index c124d1d..8d01d6b 100644 --- a/salut/telepathy-salut.pc.in +++ b/salut/telepathy-salut.pc.in @@ -5,6 +5,7 @@ includedir=@includedir@ libexecdir=@libexecdir@ plugindir=${libdir}/telepathy/salut-0 +pluginexeclibdir=@pluginexeclibdir@ salutpath=${libexecdir}/telepathy-salut Name: Telepathy-Salut @@ -12,5 +13,5 @@ Description: Link-local XMPP backend for the Telepathy framework Version: @VERSION@ Requires: pkg-config >= 0.21 Requires.private: glib-2.0 >= 2.16, gobject-2.0 >= 2.16, telepathy-glib >= 0.13.12 -Libs: -L${libdir} -lsalut-plugins -lwocky +Libs: -L${pluginexeclibdir} -lsalut-plugins -lwocky Cflags: -I${includedir}/telepathy-salut-0 diff --git a/src/Makefile.am b/src/Makefile.am index cb92f06..1a9d36a 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -128,7 +128,7 @@ SHA1_SOURCES = \ sha1/sha1-util.h \ sha1/sha1-util.c -lib_LTLIBRARIES = libsalut-plugins.la +pluginexeclib_LTLIBRARIES = libsalut-plugins.la libsalut_plugins_la_LDFLAGS = \ -shared \ @@ -337,6 +337,6 @@ Android.mk: Makefile.am $(BUILT_SOURCES) $(AM_CFLAGS) \ -:CPPFLAGS $(CPPFLAGS) $(AM_CPPFLAGS) -DBUILD_AS_ANDROID_SERVICE \ -:LDFLAGS $(telepathy_salut_android_libs) $(AM_LDFLAGS) \ - $(lib_LTLIBRARIES) \ + $(pluginexeclib_LTLIBRARIES) \ -:LIBFILTER_STATIC salut-convenience \ > $@ -- 1.7.9.1