1.1 --- a/libgnomevfs2-mythtv/m4/as-version.m4 Mon Oct 23 14:41:30 2006 +0100
1.2 +++ b/libgnomevfs2-mythtv/m4/as-version.m4 Mon Oct 15 19:00:20 2007 +0100
1.3 @@ -1,12 +1,18 @@
1.4 -dnl version.m4 0.0.5
1.5 +dnl as-version.m4 0.1.0
1.6 +
1.7 dnl autostars m4 macro for versioning
1.8 -dnl thomas@apestaart.org
1.9 -dnl
1.10 -dnl AS_VERSION(PACKAGE, PREFIX, MAJOR, MINOR, MICRO, NANO, ACTION_IF_NO_NANO, ACTION_IF_NANO)
1.11 +
1.12 +dnl Thomas Vander Stichele <thomas at apestaart dot org>
1.13 +
1.14 +dnl $Id: as-version.m4,v 1.1 2005/06/18 18:02:46 burgerman Exp $
1.15 +
1.16 +dnl AS_VERSION(PACKAGE, PREFIX, MAJOR, MINOR, MICRO, NANO,
1.17 +dnl ACTION-IF-NO-NANO, [ACTION-IF-NANO])
1.18 +
1.19 dnl example
1.20 dnl AS_VERSION(gstreamer, GST_VERSION, 0, 3, 2,)
1.21 dnl for a 0.3.2 release version
1.22 -dnl
1.23 +
1.24 dnl this macro
1.25 dnl - defines [$PREFIX]_MAJOR, MINOR and MICRO
1.26 dnl - if NANO is empty, then we're in release mode, else in cvs/dev mode
1.27 @@ -18,15 +24,16 @@
1.28 dnl maintainer mode from running ok
1.29 dnl
1.30 dnl don't forget to put #undef [$2] and [$2]_RELEASE in acconfig.h
1.31 +dnl if you use acconfig.h
1.32
1.33 AC_DEFUN([AS_VERSION],
1.34 [
1.35 PACKAGE=[$1]
1.36 - [$2]_MAJOR_VERSION=[$3]
1.37 - [$2]_MINOR_VERSION=[$4]
1.38 - [$2]_MICRO_VERSION=[$5]
1.39 + [$2]_MAJOR=[$3]
1.40 + [$2]_MINOR=[$4]
1.41 + [$2]_MICRO=[$5]
1.42 NANO=[$6]
1.43 - [$2]_NANO_VERSION=$NANO
1.44 + [$2]_NANO=$NANO
1.45 if test "x$NANO" = "x" || test "x$NANO" = "x0";
1.46 then
1.47 AC_MSG_NOTICE(configuring [$1] for release)
1.48 @@ -37,23 +44,24 @@
1.49 else
1.50 AC_MSG_NOTICE(configuring [$1] for development with nano $NANO)
1.51 VERSION=[$3].[$4].[$5].$NANO
1.52 - [$2]_RELEASE=`date +%Y%m%d_%H%M%S`
1.53 + [$2]_RELEASE=0.`date +%Y%m%d.%H%M%S`
1.54 dnl execute action
1.55 ifelse([$8], , :, [$8])
1.56 fi
1.57
1.58 - [$2]_VERSION=$VERSION
1.59 - AC_DEFINE_UNQUOTED([$2]_VERSION, "$[$2]_VERSION", [Define the version])
1.60 - AC_SUBST([$2]_VERSION)
1.61 -
1.62 + [$2]=$VERSION
1.63 + AC_DEFINE_UNQUOTED([$2], "$[$2]", [Define the version])
1.64 + AC_SUBST([$2])
1.65 + AC_DEFINE_UNQUOTED([$2]_RELEASE, "$[$2]_RELEASE", [Define the release version])
1.66 AC_SUBST([$2]_RELEASE)
1.67
1.68 - AC_SUBST([$2]_MAJOR_VERSION)
1.69 - AC_SUBST([$2]_MINOR_VERSION)
1.70 - AC_SUBST([$2]_MICRO_VERSION)
1.71 - AC_SUBST([$2]_NANO_VERSION)
1.72 + AC_SUBST([$2]_MAJOR)
1.73 + AC_SUBST([$2]_MINOR)
1.74 + AC_SUBST([$2]_MICRO)
1.75 + AC_SUBST([$2]_NANO)
1.76 AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Define the package name])
1.77 AC_SUBST(PACKAGE)
1.78 AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Define the version])
1.79 AC_SUBST(VERSION)
1.80 ])
1.81 +