Bad substitution when CONFIG_SHELL=/bin/dash
Alessandro-Barbieri opened this issue · 0 comments
Alessandro-Barbieri commented
If you set a POSIX shell CONFIG_SHELL=/bin/dash
and then configure, it will fail with
checking for pkg-conf ruby-3.1 var ruby_version... ./configure: 3751: Bad substitution
relevant piece of configure
if test "x$RUBY_VER" = x""
then :
fi
if test "x$RUBY_VER" = x""
then :
if test "x$default" = x""
then :
as_fn_error $? "not found" "$LINENO" 5
else $as_nop
eval $varname=\$default && { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not found, using default ${!varname}" >&5
printf "%s\n" "not found, using default ${!varname}" >&6; }
fi
else $as_nop
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes (detected: ${!varname})" >&5
printf "%s\n" "yes (detected: ${!varname})" >&6; }
fi
${!varname}
is a bashism
see also https://mywiki.wooledge.org/Bashism