From 659c4fad56da8d285060c8d0edd3918e8c5a1575 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tobias=20M=C3=BCller?= Date: Sat, 11 Jan 2020 11:04:07 +0100 Subject: Change version to git describe and make set-able from outside Change version to use git describe instead of git log as this will also work if tags are present and make the version string set-able from outside as a parameter to cmake, so that package managers can set this if building outside of a git working tree. --- json/jsonwrite.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'json') diff --git a/json/jsonwrite.cc b/json/jsonwrite.cc index 9723d3b2..477bfca5 100644 --- a/json/jsonwrite.cc +++ b/json/jsonwrite.cc @@ -214,7 +214,7 @@ void write_context(std::ostream &f, Context *ctx) { f << stringf("{\n"); f << stringf(" \"creator\": %s,\n", - get_string("Next Generation Place and Route (git sha1 " GIT_COMMIT_HASH_STR ")").c_str()); + get_string("Next Generation Place and Route (Version " GIT_DESCRIBE_STR ")").c_str()); f << stringf(" \"modules\": {\n"); write_module(f, ctx); f << stringf("\n }"); -- cgit v1.2.3