Include git branch name in the version string
This commit is contained in:
parent
169e541101
commit
f2148ffa0b
|
@ -7,7 +7,8 @@ SYSCONFDIR=/etc
|
||||||
else
|
else
|
||||||
SYSCONFDIR=$(PREFIX)/etc
|
SYSCONFDIR=$(PREFIX)/etc
|
||||||
endif
|
endif
|
||||||
GIT_VERSION:="$(shell git describe --tags --always) ($(shell git log --pretty=format:%cd --date=short -n1))"
|
# The escaping is absurd, but we need to escape for shell, sed, make, define
|
||||||
|
GIT_VERSION:="$(shell git describe --tags --always) ($(shell git log --pretty=format:%cd --date=short -n1), branch $(shell [ -f .git/HEAD ] && sed 's/ref: refs\/heads\/\(.*\)/\\\\\\"\1\\\\\\"/g' .git/HEAD || echo 'unknown'))"
|
||||||
VERSION:=$(shell git describe --tags --abbrev=0)
|
VERSION:=$(shell git describe --tags --abbrev=0)
|
||||||
|
|
||||||
CFLAGS += -std=c99
|
CFLAGS += -std=c99
|
||||||
|
|
Loading…
Reference in New Issue