[gnumeric] Configuration: reduce the number of places we have the version numbers.



commit 8be584f5be2d9d659f0110cce0294ef018d70e2e
Author: Morten Welinder <terra gnome org>
Date:   Thu Feb 28 10:47:02 2013 -0500

    Configuration: reduce the number of places we have the version numbers.

 configure.ac |   24 +++++++++++++++---------
 1 files changed, 15 insertions(+), 9 deletions(-)
---
diff --git a/configure.ac b/configure.ac
index d5c8d35..81215ac 100644
--- a/configure.ac
+++ b/configure.ac
@@ -36,10 +36,23 @@ m4_define([version_iface],
 AC_SUBST([VERSION_INFO], [version_iface:gnumeric_version_minor:0])
 AC_SUBST([VERSION_IFACE], [version_iface])
 
+if test `expr gnumeric_version_major % 2` -eq 1; then
+    AC_MSG_NOTICE([NOTE: This is a development release])
+    gnumeric_devel=yes
+    gnumeric_api_ver=gnumeric_version_epoch.`expr gnumeric_version_major + 1`
+    dnl An explicit version number should be used in place of the above
+    dnl if the epoch is to change.
+    dnl gnumeric_api_ver=2_0
+else
+    gnumeric_devel=no
+    gnumeric_api_ver=gnumeric_version_epoch.gnumeric_version_major
+fi
+gnumeric_api_ver_=`echo $gnumeric_api_ver | sed -e 's/\./_/g'`
+
 dnl Almost like epoch.major but development versions look forward to the next
 dnl stable release.
-AC_SUBST([GNUMERIC_API_VER], [1.12])
-AC_SUBST([GNUMERIC_API_VER_], [1_12])
+AC_SUBST([GNUMERIC_API_VER], [$gnumeric_api_ver])
+AC_SUBST([GNUMERIC_API_VER_], [$gnumeric_api_ver_])
 
 dnl This one is created by autoheader, ...
 AC_CONFIG_HEADERS(gnumeric-config.h)
@@ -60,13 +73,6 @@ dnl We use a LINGUAS file, so we need intltool >= 0.35:
 IT_PROG_INTLTOOL([0.35.0])
 IT_PO_SUBDIR(po-functions)
 
-if test `expr gnumeric_version_major % 2` -eq 1; then
-    AC_MSG_NOTICE([NOTE: This is a development release])
-    gnumeric_devel=yes
-else
-    gnumeric_devel=no
-fi
-
 dnl We use $host and $host_os:
 AC_CANONICAL_HOST
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]