Add a git revision number
This commit is contained in:
parent
ce1d166ef7
commit
5fd3ef55d0
@ -1,3 +1,7 @@
|
|||||||
|
2010-12-30 Werner Koch <wk@g10code.com>
|
||||||
|
|
||||||
|
* configure.ac: Support a git revision.
|
||||||
|
|
||||||
2010-11-03 Werner Koch <wk@g10code.com>
|
2010-11-03 Werner Koch <wk@g10code.com>
|
||||||
|
|
||||||
* configure.ac (AC_CHECK_HEADERS): Check for sys/types.h and
|
* configure.ac (AC_CHECK_HEADERS): Check for sys/types.h and
|
||||||
|
@ -37,8 +37,11 @@ m4_define(my_issvn, [yes])
|
|||||||
|
|
||||||
m4_define([svn_revision], m4_esyscmd([printf "%d" $( (svn info 2>/dev/null \
|
m4_define([svn_revision], m4_esyscmd([printf "%d" $( (svn info 2>/dev/null \
|
||||||
|| echo 'Revision: 0')|sed -n '/^Revision:/ {s/[^0-9]//gp;q;}')]))
|
|| echo 'Revision: 0')|sed -n '/^Revision:/ {s/[^0-9]//gp;q;}')]))
|
||||||
|
m4_define([git_revision], m4_esyscmd([git branch -v 2>/dev/null \
|
||||||
|
| awk '/^\* / {printf "%s",$3}']))
|
||||||
AC_INIT([gpgme],
|
AC_INIT([gpgme],
|
||||||
[my_version[]m4_if(my_issvn,[yes],[-svn[]svn_revision])],
|
[my_version[]m4_if(my_issvn,[yes],
|
||||||
|
[m4_if(git_revision,[],[-svn[]svn_revision],[-git[]git_revision])])],
|
||||||
[bug-gpgme@gnupg.org])
|
[bug-gpgme@gnupg.org])
|
||||||
|
|
||||||
|
|
||||||
@ -62,7 +65,7 @@ NEED_LIBASSUAN_API=2
|
|||||||
NEED_LIBASSUAN_VERSION=2.0.0
|
NEED_LIBASSUAN_VERSION=2.0.0
|
||||||
|
|
||||||
|
|
||||||
BUILD_REVISION=svn_revision
|
BUILD_REVISION=m4_if(git_revision,[],[svn_revision],[git_revision])
|
||||||
PACKAGE=$PACKAGE_NAME
|
PACKAGE=$PACKAGE_NAME
|
||||||
VERSION=$PACKAGE_VERSION
|
VERSION=$PACKAGE_VERSION
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user