From c46bdbde18629f0a0613c776c13a79fea0ec6093 Mon Sep 17 00:00:00 2001 From: Guus Sliepen Date: Tue, 5 May 2015 23:03:41 +0200 Subject: [PATCH] Remove "release-" from displayed git version. Also make sure that version_git.h is only written to if the "git describe" command succeeds. --- src/Makefile.am | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Makefile.am b/src/Makefile.am index cc512b1c..3b9843af 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -6,7 +6,7 @@ sbin_PROGRAMS = tincd tinc sptps_test sptps_keypair .PHONY: version.c version_git.h version_git.h: echo >$@ - -GIT_DESCRIPTION="`cd $(@D) && git describe`" && echo "#define GIT_DESCRIPTION \"$$GIT_DESCRIPTION\"" >$@ + -git describe && echo '#define GIT_DESCRIPTION "'`git describe | sed 's/release-//'`'"' >$@ version.c: version_git.h if LINUX -- 2.20.1