From: Russell L Friesenhahn Date: Fri, 26 Aug 2016 16:15:36 +0000 (-0500) Subject: Relax test to see if yosys dir is a git repository in Makefile X-Git-Tag: yosys-0.7~101^2^2 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=ee620c6a24a62725f6f41b43728fe7ce4112e130;p=yosys.git Relax test to see if yosys dir is a git repository in Makefile This prevents the test from failing in the case that yosys is a submodule of a repository since for a submodule the .git is actually a file containing the location of the submodule's .git directory --- diff --git a/Makefile b/Makefile index c76838565..55cd13158 100644 --- a/Makefile +++ b/Makefile @@ -72,7 +72,7 @@ else LDLIBS += -lrt endif -YOSYS_VER := 0.6+$(shell test -d .git && { git log --author=clifford@clifford.at --oneline 5869d26da021.. | wc -l; }) +YOSYS_VER := 0.6+$(shell test -e .git && { git log --author=clifford@clifford.at --oneline 5869d26da021.. | wc -l; }) GIT_REV := $(shell cd $(YOSYS_SRC) && git rev-parse --short HEAD 2> /dev/null || echo UNKNOWN) OBJS = kernel/version_$(GIT_REV).o