Project

General

Profile

Bug #2173

[patch] version number picks up unrelated git describe

Added by ncopa almost 6 years ago. Updated almost 6 years ago.

Status:
Fixed
Priority:
Normal
Assignee:
-
Category:
-
Target version:
Start date:
2010-03-12
Due date:
% Done:

100%

Estimated time:
0.10 h
Missing in 1.5.x:
No

Description

The build scripts for my alpine-linux distro are in git. When building lighttpd it picks up the git description tag for the distro build scripts and says lighttpd is a development version.

Fix is easy, just check if there is a .git dir in $top_srcdir like you do with svn.

ncdev:~/src/lighttpd-1.4.x$ svn diff
Index: src/Makefile.am
===================================================================
--- src/Makefile.am    (revision 2717)
+++ src/Makefile.am    (working copy)
@@ -19,7 +19,7 @@
             REVISION=""; \
         fi; \
     fi; \
-    if test -z "$$REVISION" -a -x "`which git`"; then \
+    if test -z "$$REVISION" -a -d "$(top_srcdir)/.git" -a -x "`which git`"; then \
         REVISION="$$(cd "$(top_srcdir)"; LANG= LC_ALL=C git describe --always 2>/dev/null || echo)"; \
     fi; \
     if test -n "$$REVISION"; then \

reference: http://redmine.alpinelinux.org/issues/323

Thanks!

Associated revisions

Revision 2722
Added by stbuehler almost 6 years ago

Fix detecting git repository (fixes #2173, thx ncopa)

History

#1 Updated by stbuehler almost 6 years ago

  • Status changed from New to Fixed
  • % Done changed from 0 to 100

Applied in changeset r2722.

Also available in: Atom