From e4d80b668c93b1abfa4f299904551f56d44a9351 Mon Sep 17 00:00:00 2001 From: Monty Taylor Date: Wed, 20 May 2009 11:34:05 -0700 Subject: [PATCH] Add versioning to libmemcachedutil. --- configure.ac | 5 +++++ libmemcachedutil/Makefile.am | 5 ++++- libmemcachedutil/libmemcachedutil.ver | 1 + 3 files changed, 10 insertions(+), 1 deletion(-) create mode 100644 libmemcachedutil/libmemcachedutil.ver diff --git a/configure.ac b/configure.ac index 2bea7797..7c541b24 100644 --- a/configure.ac +++ b/configure.ac @@ -27,6 +27,8 @@ MEMCACHED_LIBRARY_VERSION=2:0:0 # | set to zero if current is incremented # +- increment if interfaces have been added, removed or changed AC_SUBST(MEMCACHED_LIBRARY_VERSION) +MEMCACHEDUTIL_LIBRARY_VERSION=0:0:0 +AC_SUBST(MEMCACHEDUTIL_LIBRARY_VERSION) AM_INIT_AUTOMAKE(nostdinc no-define -Wall -Werror) AC_USE_SYSTEM_EXTENSIONS @@ -39,12 +41,15 @@ AM_SANITY_CHECK LIBTOOL="$LIBTOOL --preserve-dup-deps" AC_SUBST(LIBTOOL)dnl + # libmemcached versioning when linked with GNU ld. if test "$lt_cv_prog_gnu_ld" = "yes" then LD_VERSION_SCRIPT="-Wl,--version-script=\$(top_srcdir)/libmemcached/libmemcached.ver" + LD_UTIL_VERSION_SCRIPT="-Wl,--version-script=\$(top_srcdir)/libmemcachedutil/libmemcachedutil.ver" fi AC_SUBST(LD_VERSION_SCRIPT) +AC_SUBST(LD_UTIL_VERSION_SCRIPT) AC_C_CONST AC_HEADER_TIME diff --git a/libmemcachedutil/Makefile.am b/libmemcachedutil/Makefile.am index 852dc5dc..bbb94ddd 100644 --- a/libmemcachedutil/Makefile.am +++ b/libmemcachedutil/Makefile.am @@ -1,8 +1,11 @@ -LIBS = @LIBS@ +EXTRA_DIST= libmemcachedutil.ver lib_LTLIBRARIES= + if BUILD_LIBMEMCACHEDUTIL lib_LTLIBRARIES+= libmemcachedutil.la endif libmemcachedutil_la_SOURCES= memcached_pool.c +libmemcachedutil_la_LDFLAGS= -version-info $(MEMCACHEDUTIL_LIBRARY_VERSION) $(LD_UTIL_VERSION_SCRIPT) +libmemcachedutil_la_LIBADD= ${top_builddir}/libmemcached/libmemcached.la diff --git a/libmemcachedutil/libmemcachedutil.ver b/libmemcachedutil/libmemcachedutil.ver new file mode 100644 index 00000000..1a6d5013 --- /dev/null +++ b/libmemcachedutil/libmemcachedutil.ver @@ -0,0 +1 @@ +libmemcachedutil_0 { global: *; }; -- 2.30.2