gui/Makefile.am: add conclusive description with last tag and branch

This commit is contained in:
2014-11-04 19:42:03 +01:00
parent 8929255e9e
commit c7a40bb6dc

View File

@@ -6,9 +6,10 @@ version.h:
echo '#define BUILT_DATE "'`date`'"' > $@ echo '#define BUILT_DATE "'`date`'"' > $@
@if test -d $(top_srcdir)/.git ; then \ @if test -d $(top_srcdir)/.git ; then \
pushd $(top_srcdir) ; \ pushd $(top_srcdir) ; \
GITDESCRIBE=$$(git describe --always --dirty || echo 'VCS failed') ; \ GITBRANCH=$$(git rev-parse --abbrev-ref HEAD) ; \
GITDESCRIBE=$$(git describe --always --tags --dirty || echo 'VCS failed') ; \
popd ; \ popd ; \
echo '#define VCS "'$${GITDESCRIBE}'"' >> $@ ; \ echo '#define VCS "'$${GITDESCRIBE} [$${GITBRANCH}]'"' >> $@ ; \
fi fi
noinst_HEADERS = version.h noinst_HEADERS = version.h
.PHONY: version.h .PHONY: version.h