From a4698cf24b5210854b5cca51cfce32b63ce66724 Mon Sep 17 00:00:00 2001 From: Martin Craig Date: Tue, 6 Jun 2017 14:25:13 +0100 Subject: [PATCH] Use @ substitution as works better with cmake --- CMakeLists.txt | 2 +- Makefile | 2 +- verbena.in | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 60fa310..5d79c2a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -13,6 +13,6 @@ execute_process(COMMAND OUTPUT_VARIABLE GIT_DATE ERROR_QUIET OUTPUT_STRIP_TRAILING_WHITESPACE) -configure_file(verbena.in verbena) +configure_file(verbena.in verbena @ONLY) INSTALL(PROGRAMS ${CMAKE_CURRENT_BINARY_DIR}/verbena DESTINATION bin) diff --git a/Makefile b/Makefile index 61b3eda..8716ded 100644 --- a/Makefile +++ b/Makefile @@ -15,7 +15,7 @@ all: ${SCRIPTS} .PHONY: FORCE $(SCRIPTS): %: %.in FORCE - sed -e "s/\$${GIT_SHA1}/${GIT_SHA1}/" -e "s/\$${GIT_DATE}/${GIT_DATE}/" $< >$@ + sed -e "s/@GIT_SHA1@/${GIT_SHA1}/" -e "s/@GIT_DATE@/${GIT_DATE}/" $< >$@ clean: rm ${SCRIPTS} diff --git a/verbena.in b/verbena.in index bbe859e..cbfc273 100644 --- a/verbena.in +++ b/verbena.in @@ -13,8 +13,8 @@ # to be used, possibly with bundled dependencies PATH=`dirname $0`:${FSLDIR}/bin:${PATH} -echo "VERBENA version tag '${GIT_SHA1}'" -echo "last commit '${GIT_DATE}'" +echo "VERBENA version tag '@GIT_SHA1@'" +echo "last commit '@GIT_DATE@'" echo Usage() {