Skip to content

Commit 7ad5991

Browse files
committed
makefile: add version variable quotes in git case
Add quotes to the VERSION variable, when they are determined by invoking git. While git describe doesn't seem to output spaces. But the fallback case of just echoing the VERSION variable may contain spaces, as every release includes a space separated release date in the version variable. This fixes the issue that if the .git directory is present on a release, but the git command isn't available or fails, the VERSION variable isn't escaped anymore and the release date contained causes a build failure.
1 parent 5b86352 commit 7ad5991

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ include config.mk
55

66
VERSION := "1.13.0-non-git"
77
ifneq ($(wildcard ./.git/),)
8-
VERSION := $(shell ${GIT} describe --tags 2>/dev/null || echo ${VERSION})
8+
VERSION := "$(shell ${GIT} describe --tags 2>/dev/null || echo ${VERSION})"
99
endif
1010

1111
SYSTEMD ?= $(shell $(PKG_CONFIG) --silence-errors ${SYSTEMDAEMON} || echo 0)

0 commit comments

Comments
 (0)