]> git.proxmox.com Git - mirror_qemu.git/commit - configure
configure: Avoid non-portable 'test -o/-a'
authorEric Blake <eblake@redhat.com>
Tue, 5 Feb 2019 02:39:37 +0000 (20:39 -0600)
committerLaurent Vivier <laurent@vivier.eu>
Wed, 6 Feb 2019 14:51:55 +0000 (15:51 +0100)
commite633a5c6619feab5323f71b5c37c3602e3818687
tree7601e15f33af12c08a1cf62563a2111c19a4c390
parent70c9483a3041a4db9741d23ff75380e08216c3c6
configure: Avoid non-portable 'test -o/-a'

POSIX says that it is better to use &&/|| and two separate test
invocations than it is to try and use -a and -o (in fact, there
are some tests that are inherently ambiguous to parse if the
user passes in corner-case input like "(").

Since we cannot guarantee which shell runs configure, we cannot
rely on -o/-a always following bash's parser rules.

Signed-off-by: Eric Blake <eblake@redhat.com>
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Tested-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Message-Id: <20190205023937.18245-1-eblake@redhat.com>
Signed-off-by: Laurent Vivier <laurent@vivier.eu>
configure