From: KO Myung-Hun Date: Tue, 2 Dec 2014 05:55:20 +0000 (+0900) Subject: git-version-gen: do not print new line characters X-Git-Tag: v1.0~7245 X-Git-Url: https://gitweb.git.savannah.gnu.org/gitweb/?a=commitdiff_plain;h=e5a15adc6db466ae9d7ea5d892f78e0390d032d0;p=gnulib.git git-version-gen: do not print new line characters On platforms with CRLF endings (such as OS/2), use of 'echo' may leave behind an unwanted CR. * build-aux/git-version-gen: Use printf instead of echo and tr. Signed-off-by: Eric Blake --- diff --git a/ChangeLog b/ChangeLog index 2398d79d23..7379fa6d78 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,8 @@ 2014-12-02 KO Myung-Hun + git-version-gen: do not print new line characters + * build-aux/git-version-gen: Use printf instead of echo and tr. + gnulib-tool: recognize x:* as an absolute path * gnulib-tool (func_gnulib_dir): Add ?:* case. (func_relconcat): Likewise. diff --git a/build-aux/git-version-gen b/build-aux/git-version-gen index 47d657674d..48769baa1f 100755 --- a/build-aux/git-version-gen +++ b/build-aux/git-version-gen @@ -1,6 +1,6 @@ #!/bin/sh # Print a version string. -scriptversion=2014-06-19.19; # UTC +scriptversion=2014-12-02.19; # UTC # Copyright (C) 2007-2014 Free Software Foundation, Inc. # @@ -215,7 +215,7 @@ if test "x$v_from_git" != x; then fi # Omit the trailing newline, so that m4_esyscmd can use the result directly. -echo "$v" | tr -d "$nl" +printf %s "$v" # Local variables: # eval: (add-hook 'write-file-hooks 'time-stamp)