Commit 8424aafc authored by Martin Nordholts's avatar Martin Nordholts
Browse files

Bug 659084 - git-version.h can't be generated from shallow repositories

Pass --always to git describe so git-version.h can be generated also
from shallow (--depth 1) repositories. Cause found by Kenny Stuart.
parent 3484309e
......@@ -40,7 +40,7 @@ Developer documentation:
Source and build system:
- <item>
- Make git-version.h generation work in shallow git clones
......@@ -273,7 +273,7 @@ dist-hook: dist-check-gimp-console dist-dump-gimprc
# in which case the git-version.h we ship is correct.
git-version.h: update-git-version-header
@if test -d "$(top_srcdir)/.git"; then \
git_version="`git --git-dir=$(top_srcdir)/.git describe`"; \
git_version="`git --git-dir=$(top_srcdir)/.git describe --always`"; \
git_last_commit_timestamp="`git --git-dir=$(top_srcdir)/.git log -n1 --reverse --pretty=%ct`"; \
git_last_commit_year="`date --utc -d \"1970-01-01 + $$git_last_commit_timestamp seconds\" '+%Y'`"; \
elif test ! -f "$@"; then \
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment