From d001dd2ca3436cae899456994230b22e1c6ec6c7 Mon Sep 17 00:00:00 2001 From: Guillaume Desmottes Date: Thu, 6 Sep 2012 10:12:44 +0200 Subject: UOA account plugins: move shared code to a shared lib Avoid to redefine existing symbols when different plugins are loaded. https://bugzilla.gnome.org/show_bug.cgi?id=683415 --- .../cc-plugins/generate-plugins.py | 25 ++++++++++++++++------ 1 file changed, 19 insertions(+), 6 deletions(-) (limited to 'ubuntu-online-accounts/cc-plugins/generate-plugins.py') diff --git a/ubuntu-online-accounts/cc-plugins/generate-plugins.py b/ubuntu-online-accounts/cc-plugins/generate-plugins.py index b3b54f6e2..a5acab488 100755 --- a/ubuntu-online-accounts/cc-plugins/generate-plugins.py +++ b/ubuntu-online-accounts/cc-plugins/generate-plugins.py @@ -179,15 +179,11 @@ def generate_build_block(p): la = 'lib%s_la' % p.protocol.replace('-', '_') output = '''%s_SOURCES = \\ - empathy-accounts-plugin.c \\ - empathy-accounts-plugin.h \\ empathy-accounts-plugin-%s.c \\ - empathy-accounts-plugin-%s.h \\ - empathy-accounts-plugin-widget.c \\ - empathy-accounts-plugin-widget.h + empathy-accounts-plugin-%s.h %s_LDFLAGS = -module -avoid-version %s_LIBADD = \\ - $(UOA_LIBS) \\ + libempathy-uoa-account-plugin.la \\ $(top_builddir)/libempathy/libempathy.la \\ $(top_builddir)/libempathy-gtk/libempathy-gtk.la ''' % (la, p.protocol, p.protocol, la, la) @@ -228,6 +224,23 @@ INCLUDES = \\ $(DISABLE_DEPRECATED) \\ $(EMPATHY_CFLAGS) +pkglib_LTLIBRARIES = libempathy-uoa-account-plugin.la + +# this API is not stable and will never be, so use -release to make the +# SONAME of the plugin library change with every Empathy release. +libempathy_uoa_account_plugin_la_LDFLAGS = \\ + -no-undefined \\ + -release $(VERSION) + +libempathy_uoa_account_plugin_la_SOURCES = \\ + empathy-accounts-plugin.c \\ + empathy-accounts-plugin.h \\ + empathy-accounts-plugin-widget.c \\ + empathy-accounts-plugin-widget.h + +libempathy_uoa_account_plugin_la_LIBADD = \\ + $(UOA_LIBS) + plugin_LTLIBRARIES = \\ %s \\ $(NULL) -- cgit v1.2.3