From 4b322784fcff787831f11d0f5fd4a77efacab0d9 Mon Sep 17 00:00:00 2001 From: Dario Mazza Date: Wed, 25 Jul 2012 17:50:05 +0200 Subject: [PATCH] using m4 to define major,minor and revision number in configure.ac and send version number to libtool and AC_INIT --- configure.ac | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/configure.ac b/configure.ac index ee50c221..67ec363a 100644 --- a/configure.ac +++ b/configure.ac @@ -20,8 +20,13 @@ # Process this file with autoconf to produce a configure script. AC_PREREQ(2.57) -AC_INIT([libhttpserver], 0.2, [electrictwister2000@gmail.com]) -AM_INIT_AUTOMAKE([libhttpserver], 0.2) +m4_define([libhttpserver_MAJOR_VERSION],[0])dnl +m4_define([libhttpserver_MINOR_VERSION],[2])dnl +m4_define([libhttpserver_REVISION],[0])dnl +m4_define([libhttpserver_PKG_VERSION],[libhttpserver_MAJOR_VERSION.libhttpserver_MINOR_VERSION.libhttpserver_REVISION])dnl +m4_define([libhttpserver_LDF_VERSION],[libhttpserver_MAJOR_VERSION:libhttpserver_MINOR_VERSION:libhttpserver_REVISION])dnl +AC_INIT([libhttpserver], libhttpserver_PKG_VERSION, [electrictwister2000@gmail.com]) +AM_INIT_AUTOMAKE([libhttpserver], libhttpserver_PKG_VERSION) AC_CONFIG_HEADERS([config.h]) AC_CONFIG_MACRO_DIR([m4]) @@ -378,6 +383,8 @@ if test x$guile = xtrue; then fi GUILE_AUTOGENERATION=$srcdir/src/autogen_helpers/support_command +LDFLAGS="$LDFLAGS -version-number libhttpserver_LDF_VERSION" + AC_SUBST(LHT_LIBDEPS) AC_SUBST(AM_CXXFLAGS) AC_SUBST(CPPFLAGS)