8310369: UTIL_ARG_WITH fails when arg is disabled
Reviewed-by: mikael
This commit is contained in:
parent
01623f6a57
commit
7ea22cd385
@ -1,5 +1,5 @@
|
||||
#
|
||||
# Copyright (c) 2011, 2022, Oracle and/or its affiliates. All rights reserved.
|
||||
# Copyright (c) 2011, 2023, Oracle and/or its affiliates. All rights reserved.
|
||||
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
#
|
||||
# This code is free software; you can redistribute it and/or modify it
|
||||
@ -509,7 +509,7 @@ AC_DEFUN([UTIL_CHECK_TYPE_directory],
|
||||
FAILURE="Directory $1 does not exist or is not readable"
|
||||
fi
|
||||
|
||||
if test "[x]ARG_CHECK_FOR_FILES" != x; then
|
||||
if test "[x]ARG_CHECK_FOR_FILES" != "x:"; then
|
||||
for file in ARG_CHECK_FOR_FILES; do
|
||||
found_files=$($ECHO $(ls $1/$file 2> /dev/null))
|
||||
if test "x$found_files" = x; then
|
||||
@ -781,7 +781,6 @@ UTIL_DEFUN_NAMED([UTIL_ARG_WITH],
|
||||
else
|
||||
AC_MSG_RESULT([$ARG_RESULT, $REASON])
|
||||
fi
|
||||
fi
|
||||
|
||||
# Verify value
|
||||
# First use our dispatcher to verify that type requirements are satisfied
|
||||
@ -801,6 +800,7 @@ UTIL_DEFUN_NAMED([UTIL_ARG_WITH],
|
||||
AC_MSG_NOTICE([$FAILURE])
|
||||
AC_MSG_ERROR([Cannot continue])
|
||||
fi
|
||||
fi
|
||||
|
||||
# Execute result payloads, if present
|
||||
if test x$ARG_GIVEN = xtrue; then
|
||||
|
Loading…
x
Reference in New Issue
Block a user