qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v2 3/7] configure: Look for auxiliary Python installations


From: Peter Maydell
Subject: Re: [PATCH v2 3/7] configure: Look for auxiliary Python installations
Date: Fri, 10 Feb 2023 15:53:58 +0000

On Fri, 10 Feb 2023 at 15:28, John Snow <jsnow@redhat.com> wrote:
>
>
>
> On Fri, Feb 10, 2023, 5:46 AM Paolo Bonzini <pbonzini@redhat.com> wrote:
>>
>> On 2/10/23 01:31, John Snow wrote:
>> > +for binary in "${PYTHON-python3}" python python3.{11..6}
>>
>> This is not available in e.g. dash, so we need to use {11,10,9,8,7,6}.
>> Just a nit, I can fix it myself.
>
>
> What platforms use dash by default?

Ubuntu and Debian default to /bin/sh being dash. The BSDs will
also have some non-bash /bin/sh I expect.

shellcheck will catch this non-portability:

$ cat /tmp/foo.sh
#!/bin/sh

echo {11..6}
$ shellcheck /tmp/foo.sh

In /tmp/foo.sh line 3:
echo {11..6}
     ^-----^ SC3009 (warning): In POSIX sh, brace expansion is undefined.

For more information:
  https://www.shellcheck.net/wiki/SC3009 -- In POSIX sh, brace expansion is u...


though if you try it on configure right now there are a ton
of unaddressed warnings (some of which are harmless and some
of which are probably technically portability bugs) so it's
a bit tricky to use to sanity-check new changes.

thanks
-- PMM



reply via email to

[Prev in Thread] Current Thread [Next in Thread]