8243656: Shell built-in test in configure depends on help

Help might not be available to check for built-ins: Use 'command -v' instead

Reviewed-by: erikj
This commit is contained in:
Michael Zucchi 2020-04-27 11:00:29 +02:00 committed by Severin Gehwolf
parent 5b066096a4
commit a3443d0fd1

View File

@ -573,7 +573,7 @@ AC_DEFUN([UTIL_REQUIRE_BUILTIN_PROGS],
UTIL_SETUP_TOOL($1, [AC_PATH_PROGS($1, $2, , $3)])
if test "x[$]$1" = x; then
AC_MSG_NOTICE([Required tool $2 not found in PATH, checking built-in])
if help $2 > /dev/null 2>&1; then
if command -v $2 > /dev/null 2>&1; then
AC_MSG_NOTICE([Found $2 as shell built-in. Using it])
$1="$2"
else