git-version-gen: avoid test -z portability glitch
authorEric Blake <eblake@redhat.com>
Mon, 31 Dec 2012 23:01:13 +0000 (16:01 -0700)
committerEric Blake <eblake@redhat.com>
Mon, 31 Dec 2012 23:01:13 +0000 (16:01 -0700)
commitd4d4aa2ee0869eebacf0322d35dcd12b576eeef3
tree1eaaa2d0399b3475974ce8d6807c0e16eee9ff8e
parentb679574e3ac7d53c20778854719043c2c4a2dc9e
git-version-gen: avoid test -z portability glitch

Autoconf warns that there are some broken shells where 'test -z "$x"'
gives 0 exit status if $x is ')'.  Since some of our strings come
from command-line arguments, and since git-version-gen is run on
end-user machines where sh might be broken, we should be robust to
abuse.  Some of the instances replaced here are provably safe,
and could not confuse even broken 'test', but it is easier to
replace all instances of test -[nz].

* build-aux/git-version-gen: Prefer portable test spelling, since
git-version-gen is run on more than just developer machines.

Signed-off-by: Eric Blake <eblake@redhat.com>
ChangeLog
build-aux/git-version-gen