[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-block] [PATCH v2 02/18] configure: Disable W^X on OpenBSD
From: |
Thomas Huth |
Subject: |
Re: [Qemu-block] [PATCH v2 02/18] configure: Disable W^X on OpenBSD |
Date: |
Wed, 30 Jan 2019 08:17:41 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 |
On 2019-01-29 22:54, Eric Blake wrote:
> On 1/29/19 11:53 AM, Philippe Mathieu-Daudé wrote:
>> Since OpenBSD 6.0 [1], W^X is enforced by default [2].
>> TCG requires WX access. Disable W^X if it is available.
>> This fixes:
>>
>
>> configure | 11 +++++++++++
>> 1 file changed, 11 insertions(+)
>>
>> diff --git a/configure b/configure
>> index b18281c61f..799ec2013b 100755
>> --- a/configure
>> +++ b/configure
>> @@ -5795,6 +5795,17 @@ if test "$mingw32" = "yes" ; then
>> done
>> fi
>>
>> +# Disable OpenBSD W^X if available
>> +if test "$tcg" = "yes" -a "$targetos" = "OpenBSD"; then
>
> test ... -a ...
>
> is not portable (POSIX permits non-XSI systems to omit support for these
> operators, but even where they are supported, there are some inherently
> ambiguous inputs where you CANNOT predict whether the shell will parse
> -a as a binary operator or as an argument to some other operator).
> Instead, you should ALWAYS break dual tests into:
>
> test ... && test ...
>
> instead. (Same for '-o' vs '|| test')
$ grep 'test.* -a ' configure | wc -l
21
$ grep 'test.* && ' configure | wc -l
16
Looks like we do not really care?
Thomas
signature.asc
Description: OpenPGP digital signature
- [Qemu-block] [PATCH v2 00/18] OpenBSD: Enable qtesting, Philippe Mathieu-Daudé, 2019/01/29
- [Qemu-block] [PATCH v2 01/18] tests/vm: Be verbose while extracting compressed images, Philippe Mathieu-Daudé, 2019/01/29
- [Qemu-block] [PATCH v2 02/18] configure: Disable W^X on OpenBSD, Philippe Mathieu-Daudé, 2019/01/29
- [Qemu-block] [PATCH v2 03/18] tests/vm/openbsd: Disable the W^X protection on the build partition, Philippe Mathieu-Daudé, 2019/01/29
- [Qemu-block] [PATCH v2 04/18] ahci-test: Add dependency to qemu-img tool, Philippe Mathieu-Daudé, 2019/01/29
- [Qemu-block] [PATCH v2 05/18] qemu-iotests: Add dependency to qemu-nbd tool, Philippe Mathieu-Daudé, 2019/01/29
- [Qemu-block] [PATCH v2 07/18] tests/multiboot: Improve portability by searching bash in the $PATH, Philippe Mathieu-Daudé, 2019/01/29
- [Qemu-block] [PATCH v2 06/18] qemu-iotests: Improve portability by searching bash in the $PATH, Philippe Mathieu-Daudé, 2019/01/29