Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ChangeLog7
-rw-r--r--configure.ac34
-rw-r--r--libdocument/Makefile.am7
-rw-r--r--libview/Makefile.am15
4 files changed, 56 insertions, 7 deletions
diff --git a/ChangeLog b/ChangeLog
index f36b2d0..c3412bb 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,12 @@
2009-01-21 Christian Persch <chpe@gnome.org>
+ * configure.ac:
+ * libdocument/Makefile.am:
+ * libview/Makefile.am: Add libtool versioning to libevbackend and
+ libevview. Bug #568229.
+
+2009-01-21 Christian Persch <chpe@gnome.org>
+
* Makefile.am:
* configure.ac:
A evince-{backend,view}.pc.in: Add pkgconfig files. Bug #568220.
diff --git a/configure.ac b/configure.ac
index f3b9c7e..a76cb0a 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,4 +1,6 @@
-dnl Process this file with autoconf to produce a configure script.
+# *****************************************************************************
+# Versioning
+# *****************************************************************************
m4_define([ev_major_version],[2])
m4_define([ev_minor_version],[25])
@@ -9,6 +11,31 @@ m4_define([ev_version],[ev_major_version.ev_minor_version.ev_micro_version()ev_e
# The evince API version
m4_define([ev_api_version], [2.25])
+# Libtool versioning. The backend and view libraries have separate versions.
+# Before making a release, the libtool version should be modified.
+# The string is of the form C:R:A.
+# - If interfaces have been changed or added, but binary compatibility has
+# been preserved, change to C+1:0:A+1
+# - If binary compatibility has been broken (eg removed or changed interfaces)
+# change to C+1:0:0
+# - If the interface is the same as the previous version, change to C:R+1:A
+
+# Libtool version of the backend library
+m4_define([ev_backend_lt_current],[1])
+m4_define([ev_backend_lt_revision],[0])
+m4_define([ev_backend_lt_age],[0])
+m4_define([ev_backend_lt_version_info],[ev_backend_lt_current:ev_backend_lt_revision:ev_backend_lt_age])
+m4_define([ev_backend_lt_current_minus_age],[m4_eval(ev_backend_lt_current - ev_backend_lt_age)])
+
+# Libtool version of the view library
+m4_define([ev_view_lt_current],[1])
+m4_define([ev_view_lt_revision],[0])
+m4_define([ev_view_lt_age],[0])
+m4_define([ev_view_lt_version_info],[ev_view_lt_current:ev_view_lt_revision:ev_view_lt_age])
+m4_define([ev_view_lt_current_minus_age],[m4_eval(ev_view_lt_current - ev_view_lt_age)])
+
+# *****************************************************************************
+
AC_PREREQ([2.57])
AC_INIT([Evince],[ev_version],[http://bugzilla.gnome.org/enter_bug.cgi?product=evince],[evince])
AM_INIT_AUTOMAKE([1.9 dist-bzip2 no-dist-gzip])
@@ -429,6 +456,11 @@ AC_SUBST([EV_MICRO_VERSION],[ev_micro_version])
AC_SUBST([EV_API_VERSION],[ev_api_version])
+AC_SUBST([EV_BACKEND_LT_VERSION_INFO],[ev_backend_lt_version_info])
+AC_SUBST([EV_BACKEND_LT_CURRENT_MINUS_AGE],[ev_backend_lt_current_minus_age])
+AC_SUBST([EV_VIEW_LT_VERSION_INFO],[ev_view_lt_version_info])
+AC_SUBST([EV_VIEW_LT_CURRENT_MINUS_AGE],[ev_view_lt_current_minus_age])
+
# *****************************************************************************
AC_CONFIG_FILES([
diff --git a/libdocument/Makefile.am b/libdocument/Makefile.am
index c08f5a8..a44ed64 100644
--- a/libdocument/Makefile.am
+++ b/libdocument/Makefile.am
@@ -1,4 +1,5 @@
INCLUDES= \
+ -DG_LOG_DOMAIN=\"EvDocument\" \
-DEVINCE_UIDIR=\"$(pkgdatadir)\" \
-DGNOMELOCALEDIR=\"$(datadir)/locale\" \
-DEV_BACKENDSDIR=\"$(libdir)/evince/backends\" \
@@ -8,7 +9,11 @@ INCLUDES= \
lib_LTLIBRARIES = libevbackend.la
-libevbackend_la_LDFLAGS = -export-dynamic
+libevbackend_la_LDFLAGS = \
+ -version-info $(EV_BACKEND_LT_VERSION_INFO) \
+ -export-symbols-regex "^ev_*" \
+ $(AM_LDFLAGS)
+
libevbackend_la_LIBADD = $(LIBDOCUMENT_LIBS)
NOINST_H_FILES = \
diff --git a/libview/Makefile.am b/libview/Makefile.am
index 608fa85..eede6da 100644
--- a/libview/Makefile.am
+++ b/libview/Makefile.am
@@ -1,4 +1,5 @@
INCLUDES= \
+ -DG_LOG_DOMAIN=\"EvView\" \
-DGNOMELOCALEDIR=\"$(datadir)/locale\" \
-I$(top_srcdir)/libdocument \
$(LIBVIEW_CFLAGS) \
@@ -7,7 +8,11 @@ INCLUDES= \
lib_LTLIBRARIES = libevview.la
-libevview_la_LDFLAGS = -export-dynamic
+libevview_la_LDFLAGS = \
+ -version-info $(EV_VIEW_LT_VERSION_INFO) \
+ -export-symbols-regex "^ev_*" \
+ $(AM_LDFLAGS)
+
libevview_la_LIBADD = $(LIBVIEW_LIBS)
NOINST_H_FILES = \
@@ -25,7 +30,7 @@ INST_H_FILES = \
ev-view.h \
ev-view-type-builtins.h
-headerdir = $(prefix)/include/evince/@EV_API_VERSION@/ev-view
+headerdir = $(includedir)/evince/$(EV_API_VERSION)/ev-view
header_DATA = $(INST_H_FILES)
libevview_la_SOURCES = \
@@ -51,11 +56,11 @@ BUILT_SOURCES = \
CLEANFILES = $(BUILT_SOURCES) stamp-ev-view-type-builtins.h
ev-view-marshal.h: $(srcdir)/ev-view-marshal.list
- $(GLIB_GENMARSHAL) --prefix=ev_view_marshal $(srcdir)/ev-view-marshal.list --header > $@
+ $(GLIB_GENMARSHAL) --prefix=ev_view_marshal $(srcdir)/ev-view-marshal.list --header --internal > $@
ev-view-marshal.c: $(srcdir)/ev-view-marshal.list
- echo '#include "ev-view-marshal.h"' > ev-view-marshal.c
- $(GLIB_GENMARSHAL) --prefix=ev_view_marshal $(srcdir)/ev-view-marshal.list --body >> $@
+ echo '#include <config.h>' > ev-view-marshal.c
+ $(GLIB_GENMARSHAL) --prefix=ev_view_marshal $(srcdir)/ev-view-marshal.list --header --internal --body >> $@
ev-view-type-builtins.h: stamp-ev-view-type-builtins.h
@true