File tree Expand file tree Collapse file tree 2 files changed +5
-34
lines changed Expand file tree Collapse file tree 2 files changed +5
-34
lines changed Original file line number Diff line number Diff line change 11AC_PREREQ ( 2.64 )
2- AC_INIT ( [ openocd] , [ 0.10.0+dev ] ,
2+ AC_INIT ( [ openocd] , [ ] ,
33 [ OpenOCD Mailing List <[email protected] >] ) 44AC_CONFIG_SRCDIR ( [ src/openocd.c] )
55
Original file line number Diff line number Diff line change @@ -14,39 +14,10 @@ usage() {
1414
1515cd " ${1:- .} " || usage
1616
17- # Check for git and a git repo.
18- if head=` git rev-parse --verify --short HEAD 2> /dev/null` ; then
19-
20- # If we are at a tagged commit (like "v2.6.30-rc6"), we ignore it,
21- # because this version is defined in the top level Makefile.
22- if [ -z " ` git describe --exact-match 2> /dev/null` " ]; then
23-
24- # If we are past a tagged commit (like "v2.6.30-rc5-302-g72357d5"),
25- # we pretty print it.
26- if atag=" ` git describe 2> /dev/null` " ; then
27- echo " $atag " | awk -F- ' {printf("-%05d-%s", $(NF-1),$(NF))}'
28-
29- # If we don't have a tag at all we print -g{commitish}.
30- else
31- printf ' %s%s' -g $head
32- fi
33- fi
34-
35- # Is this git on svn?
36- if git config --get svn-remote.svn.url > /dev/null; then
37- printf -- ' -svn%s' " ` git svn find-rev $head ` "
38- fi
39-
40- # Update index only on r/w media
41- [ -w . ] && git update-index --refresh --unmerged > /dev/null
42-
43- # Check for uncommitted changes
44- if git diff-index --name-only HEAD | grep -v " ^scripts/package" \
45- | read dummy; then
46- printf ' %s' -dirty
47- fi
48-
49- # All done with git
17+ # Check for git and a git repo, use 'git describe' output as version.
18+ desc=` git describe --always --tags --dirty --abbrev=8 2> /dev/null`
19+ if [ -n " $desc " ]; then
20+ printf ' %s' $desc
5021 exit
5122fi
5223
You can’t perform that action at this time.
0 commit comments