summaryrefslogtreecommitdiffabout
path: root/am
authorSergey Poznyakoff <gray@gnu.org.ua>2011-05-08 12:13:59 (GMT)
committer Sergey Poznyakoff <gray@gnu.org.ua>2011-05-08 12:13:59 (GMT)
commit79f6b2c923d1c2366b68a431756bde6e4a04ae86 (patch) (side-by-side diff)
tree75087c12a3b763634bd5ea9ae616e6dd447b3f9d /am
parentced98e1b1e040bd0f50b2ebd146a22e74f5913c0 (diff)
downloadgrecs-79f6b2c923d1c2366b68a431756bde6e4a04ae86.tar.gz
grecs-79f6b2c923d1c2366b68a431756bde6e4a04ae86.tar.bz2
Redo versioning support.
* am/grecs.m4: Define GRECS_VEROK_AT if package version matches the standard scheme. Define GRECS_DISTCK_AT if install flag is set. * src/grecs.h (GRECS_VERSION_MAJOR) (GRECS_VERSION_MINOR): New defines. (grecs_version_info)<buffer>: New member. (grecs_version): Return allocated grecs_version_info structure. (grecs_version_cmp): Change prototype. (grecs_version_ok) (grecs_version_info_cmp) (grecs_version_split) (grecs_version_info_free): New protos. * src/version.c: Rewrite. * src/libgrecs.m4 (AM_LIBGRECS): Use grecs_version_ok * tests/.gitignore: Add distck. * tests/Makefile.am: Add new tests. * tests/testsuite.at: Add new tests. * tests/gcfver.c: Update. * tests/vercmp.at: Rewrite. * tests/verok.at: New file (from old vercmp.at). * tests/distck.at: New file. * tests/distck.c: New file.
Diffstat (limited to 'am') (more/less context) (ignore whitespace changes)
-rw-r--r--am/grecs.m410
1 files changed, 6 insertions, 4 deletions
diff --git a/am/grecs.m4 b/am/grecs.m4
index 81a6ee5..e4f8671 100644
--- a/am/grecs.m4
+++ b/am/grecs.m4
@@ -149,26 +149,28 @@ AC_DEFUN([GRECS_SETUP],[
])
_GRECS_IF_OPTION_SET([git2chg],[GRECS_BUILD_AUX="$GRECS_BUILD_AUX build-aux/git2chg.awk"])
- # Make sure package versioning is compatible with vercmp.at:
- s=`echo $PACKAGE_VERSION | sed 's/[0-9][0-9]*\.[0-9][0-9]*\(\.[0-9][0-9]\)\?\([^a-zA-Z_0-9].*\)\?//'`
+ # Make sure package versioning is compatible with version.at:
+ s=`echo $PACKAGE_VERSION | [sed 's/[0-9][0-9]*\.[0-9][0-9]*\(\.[0-9][0-9]\)\?\([^a-zA-Z_0-9].*\)\?//'`]
if test -z "$s"; then
- GRECS_VERCMP_AT=vercmp.at
+ GRECS_VEROK_AT=verok.at
fi
AC_SUBST([GRECS_SRCDIR],$1)
- AC_SUBST([GRECS_VERCMP_AT])
+ AC_SUBST([GRECS_VEROK_AT])
AC_SUBST([GRECS_BUILD_AUX])
AC_SUBST([GRECS_INCLUDES])
AC_SUBST([GRECS_TESTDIR])
AC_SUBST([GRECS_LDADD])
AC_SUBST([GRECS_DOCDIR])
AC_SUBST([GRECS_CHANGELOG])
+ AC_SUBST([GRECS_DISTCK_AT])
AC_SUBST([GRECS_INCLUDES],['-I$(top_srcdir)/]grecsdir[src]')
_GRECS_OPTION_SWITCH([install],[
LT_INIT
GRECS_LDADD=['$(top_builddir)/]grecsdir[src/libgrecs.la']
GRECS_DOCDIR='doc'
GRECS_CHANGELOG=
+ GRECS_DISTCK_AT=distck.at
AC_CONFIG_FILES(grecsdir[src/Makefile]:grecsdir[src/Make-inst.in]
grecsdir[doc/Makefile])
],[shared],[

Return to:

Send suggestions and report system problems to the System administrator.