[DTrace-devel] [PATCH] test: Use #!/usr/bin/bash explicitly when using BASH-features

Nick Alcock nick.alcock at oracle.com
Wed May 17 19:11:12 UTC 2023


On 17 May 2023, Tomasz Kłoczko via DTrace-devel uttered the following:

> On Wed, 17 May 2023 at 16:35, Kris Van Hees via DTrace-devel <
> dtrace-devel at oss.oracle.com> wrote:
>
>> Signed-off-by: Kris Van Hees <kris.van.hees at oracle.com>

Reviewed-by: Nick Alcock <nick.alcock at oracle.com>

>> ---
>>  test/unittest/arrays/err.D_UNKNOWN.uregs_toobig.aarch64.x | 2 +-
>>  test/unittest/arrays/err.D_UNKNOWN.uregs_toobig.x86_64.x  | 2 +-
>>  2 files changed, 2 insertions(+), 2 deletions(-)
>>
>
> Why not rewrite that script as POSIX sh compliant?

We could, but it doesn't actually gain us anything: runtest.sh itself is
a bash script, after all, and there are hundreds of others in the
testsuite and the build system.

Doing this much keeps things working on machines on which /bin/sh is not
bash, which is worthwhile. I don't think running the testsuite on
machines with *no bash installed at all* is something that has ever been
tried, at least not in the past decade.

-- 
NULL && (void)



More information about the DTrace-devel mailing list