busybox 'find' now supports -quit so use it if the installed version

supports that option

Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
Tom Eastep 2024-04-15 21:15:38 -07:00
parent fba5847fa3
commit 59736620fe

View File

@ -382,20 +382,18 @@ uptodate() {
local dir local dir
local find local find
local quit local quit=-quit
local maxdepth local maxdepth
find=$(mywhich find) find=$(mywhich find)
[ -n "${find}" ] || return 1 [ -n "${find}" ] || return 1
if [ -h "${find}" ]; then if [ -h "${find}" ] && ! qt ${find} . -name foo -print -quit ; then
# #
# 'Find' is provided by Busybox and doesn't support -quit. # 'Find' is provided by Busybox and this old versions don't support -quit.
# #
quit= quit=
else
quit=-quit
fi fi
if [ "$AUTOMAKE" = recursive ]; then if [ "$AUTOMAKE" = recursive ]; then