[Openais] [corosync] [RFE] - Support for -v (version) option
Steven Dake
sdake at redhat.com
Thu Jul 30 09:48:10 PDT 2009
On Thu, 2009-07-30 at 18:28 +0200, Fabio M. Di Nitto wrote:
> On Thu, 2009-07-30 at 16:34 +0200, Jan Friesse wrote:
> > Patch version 3. Uses approach of
> > - delete exec/version.h from svn control
> > - generate it from configure.ac AND svnversion in autogen.sh
> >
> > Regards,
> > Honza
> >
> > Jan Friesse wrote:
> > > Steve,
> > > I'm looking on tagging script (I hope it's Makefile in root).
> > >
> > > First thing:
> > > - Do we really need patch to show revision? Becase line 101 (and 40 for
> > > flatron):
> > >
> > > # set version
> > > echo "#define RELEASE_RELVERSION \"subrev $(REV) corosync
> > > version $(RELVERSION)\"" \
> > > > tags/corosync-$(RELVERSION)/version.h
> > >
> > > should generate correct informations to version.h file. But this
> > > version.h is never published to SVN so we can't use it.
> > >
> > > What this file is good for?
> > >
> > > I really don't understand, what tag version you want to set. RELVERSION?
> > > In this case, can? we:
> > > - change line 102-103 (41-42) to generate exec/version.h
> > > - use RELVERSION in all VERSION outputs
> > >
> > > or
> > >
> > > - remove line 101-103 (40-43) from tagging script
> > > - remove exec/version.h from svn (I totally agree with Fabio, that
> > > rewriting something what is in version system control is ugly)
> > > - use only autogen.sh to generate exec/version.h
> > >
> > > Regards,
> > > Honza
> > >
> > > Steven Dake napsal(a):
> > >> autogen.sh should detect the tag version or honor that which is done in
> > >> the tagging script. Have you looked at how the tagging script sets the
> > >> version variable?
> > >>
> > >> Regards
> > >> -steve
> > >> On Tue, 2009-07-28 at 12:17 +0200, Jan Friesse wrote:
> > >>> See SUBJ and Patch.
> > >>>
> > >>> Regards,
> > >>> Honza
> > >>> _______________________________________________
> > >>> Openais mailing list
> > >>> Openais at lists.linux-foundation.org
> > >>> https://lists.linux-foundation.org/mailman/listinfo/openais
> > >>
> > >
> > >
> >
> > plain text document attachment (corosync-version-take3.patch)
> > commit 061d6bedcc36623f606bc9eb4ccb7327e60498cb
> > Author: Jan Friesse <jfriesse at redhat.com>
> > Date: Tue Jul 28 11:56:15 2009 +0200
> >
> > Added support for -v (version) feature
> >
> > This can be usefull for easier way to get informations
> > of the corosync version from users. Version and SVN
> > revision (get by svninfo -c) are displayed.
> >
> > diff --git a/trunk/autogen.sh b/trunk/autogen.sh
> > index 83770a1..920f36d 100755
> > --- a/trunk/autogen.sh
> > +++ b/trunk/autogen.sh
> > @@ -3,3 +3,9 @@
> >
> > echo Building configuration system...
> > autoreconf -i && echo Now run ./configure and make
> > +
> > +# Generate version and SVN revision
> > +version=`sed -n 's/AC_INIT[^,]*, \[\([[:alnum:].]*\)\].*/\1/p' configure.ac`
> > +revision=`svnversion -c`
> > +echo '#define RELEASE_VERSION "'$version'"' > exec/version.h
>
> You don't need the RELEASE_VERSION. The one stored in configure.ac is
> the same that shows up as VERSION from config.h.
>
Fabio,
The change here is to create version.h from autogen.sh vs the tagging
script which creates it now. We will remove the creation of version.h
from the tagging script entirely.
Regards
-steve
> > + printf ("Corosync Cluster Engine, version '%s' SVN revision '%s'\n", VERSION, SVN_REVISION);
>
> ^^^ here.
>
> Fabio
>
More information about the Openais
mailing list