Use git describe to determine build version
authorSimon Wilkinson <sxw@inf.ed.ac.uk>
Sat, 26 Jun 2010 18:35:18 +0000 (19:35 +0100)
committerRuss Allbery <rra@stanford.edu>
Mon, 28 Jun 2010 22:19:23 +0000 (15:19 -0700)
commit5158766dce97570e51fc3abb2c8b3405fe7c299e
treeca60bb4d7cf87849337b62bf90e75cb8bca8aa2e
parent020c2284250cd26eb3b45fdbd7b96a84c0c58f5f
Use git describe to determine build version

This patch makes the configure and build system use the output
from 'git describe' to determine the version of the software being
built. This means that all that is necessary to create a new release
is to tag the repository - removing the double sources of version
information.

There are a couple of fallbacks for systems which do not have git
available for builds. Firstly, if a file called '.version' exists
in the top level of the repository, then the version information is
pulled from this file. The intention is that those packaging up
git checkouts for onwards distribution will use
'git describe > .version' before producing their tarballs.

Secondly, if we cannot find any version information then the version
will default to 'UNKNOWN'

This all mirrors the way that many others have integrated git with
automake and friends - although the implementation is independent.

Change-Id: I7fa4605e52181d60657ad794ca8efdb5a9fb1449
Reviewed-on: http://gerrit.openafs.org/1824
Tested-by: Derrick Brashear <shadow@dementia.org>
Reviewed-by: Andrew Deason <adeason@sinenomine.net>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
Reviewed-by: Russ Allbery <rra@stanford.edu>
.gitignore
build-tools/git-version [new file with mode: 0755]
build-tools/libafsdep [new file with mode: 0644]
configure-libafs.in
configure.in
src/config/Makefile.version-NOCML.in
src/config/make_libafs_tree.pl