Skip to content

Commit 8bbb4fa

Browse files
committed
Makefile: Improve gitrev.h generation.
1 parent 5d04b66 commit 8bbb4fa

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

Makefile.am

+3-1
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,9 @@ EXTRA_DIST = gitrev.h dump.hh expr.hh grammar.hh log.hh prod.hh \
3131
dut.hh postgres.hh monetdb.hh log-v1.0-to-v1.2.sql
3232

3333
gitrev.h: $(HEADERS) $(SOURCES)
34-
echo "#define GITREV \"$$(git describe --dirty --tags --always)\"" > $@
34+
-if git describe --dirty --tags --always > /dev/null ; then \
35+
echo "#define GITREV \"$$(git describe --dirty --tags --always)\"" > $@ ;\
36+
fi
3537

3638
filterdump:
3739
psql -c 'copy (select error from known) to stdout' smith|sort -u > known.txt

0 commit comments

Comments
 (0)