DBUS_VERSION is always three numbers
authorTor Lillqvist <tml@iki.fi>
Wed, 21 Oct 2009 23:25:19 +0000 (02:25 +0300)
committerRalf Habacker <ralf.habacker@freenet.de>
Tue, 1 Dec 2009 08:20:36 +0000 (09:20 +0100)
No *-rc* possible. So drop strange crap manipulating it for
BUILD_FILEVERSION. Drop duplicate AC_SUBST.

configure.in

index 30b7252..05fe061 100644 (file)
@@ -82,13 +82,9 @@ if test "$dbus_win" = yes; then
     AC_DEFINE(DBUS_WIN,1,[Defined if we run on a W32 API based system])
     BUILD_TIMESTAMP=`date --iso-8601=minutes`
     AC_SUBST(BUILD_TIMESTAMP)
-    changequote(,)dnl
-    BUILD_FILEVERSION=`echo "$DBUS_VERSION" | sed 's/\([0-9.]*\).*/\1./;s/\./,/g'`
-    changequote([,])dnl
-    case "$DBUS_VERSION" in
-      *-rc*)  BUILD_FILEVERSION="${BUILD_FILEVERSION}1" ;;
-      *)      BUILD_FILEVERSION="${BUILD_FILEVERSION}2" ;;
-    esac
+    # Assume DBUS_VERSION is always three numbers
+    BUILD_FILEVERSION=`echo "$DBUS_VERSION" | sed -e 's/\./,/g'`,0
+    AC_SUBST(BUILD_FILEVERSION)
     AC_CHECK_TOOL(WINDRES, windres, no)
     if test "$WINDRES" = no; then
       AC_MSG_ERROR([*** Could not find an implementation of windres in your PATH.])
@@ -96,12 +92,10 @@ if test "$dbus_win" = yes; then
 else
     AC_DEFINE(DBUS_UNIX,1,[Defined if we run on a Unix-based system])
 fi
-AC_SUBST(BUILD_TIMESTAMP)
-AC_SUBST(BUILD_FILEVERSION)
+
 AM_CONDITIONAL(DBUS_WIN, test "$dbus_win" = yes)
 AM_CONDITIONAL(DBUS_UNIX, test "$dbus_unix" = yes)
 
-
 AC_ARG_ENABLE(tests, AS_HELP_STRING([--enable-tests],[enable unit test code]),enable_tests=$enableval,enable_tests=$USE_MAINTAINER_MODE)
 AC_ARG_ENABLE(ansi, AS_HELP_STRING([--enable-ansi],[enable -ansi -pedantic gcc flags]),enable_ansi=$enableval,enable_ansi=no)
 AC_ARG_ENABLE(verbose-mode, AS_HELP_STRING([--enable-verbose-mode],[support verbose debug mode]),enable_verbose_mode=$enableval,enable_verbose_mode=$USE_MAINTAINER_MODE)