mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-03-16 04:20:49 +00:00
Merge pull request #8894 from daverodgman/quietbuild2
Follow-up non-verbose logs
This commit is contained in:
commit
68f46414cb
@ -12,8 +12,8 @@
|
||||
# export VERBOSE_LOGS=1
|
||||
|
||||
# don't silence invocations containing these arguments
|
||||
export NO_SILENCE=" --version "
|
||||
NO_SILENCE=" --version "
|
||||
|
||||
export TOOL="cmake"
|
||||
TOOL="cmake"
|
||||
|
||||
exec "$(dirname "$0")/quiet.sh" "$@"
|
||||
. "$(dirname "$0")/quiet.sh"
|
||||
|
@ -12,8 +12,8 @@
|
||||
# export VERBOSE_LOGS=1
|
||||
|
||||
# don't silence invocations containing these arguments
|
||||
export NO_SILENCE=" --version | test "
|
||||
NO_SILENCE=" --version | test "
|
||||
|
||||
export TOOL="make"
|
||||
TOOL="make"
|
||||
|
||||
exec "$(dirname "$0")/quiet.sh" "$@"
|
||||
. "$(dirname "$0")/quiet.sh"
|
||||
|
10
tests/scripts/quiet/quiet.sh
Executable file → Normal file
10
tests/scripts/quiet/quiet.sh
Executable file → Normal file
@ -22,9 +22,13 @@
|
||||
# be silenced, e.g. " --version | test ". In this example, "make lib test" will
|
||||
# not be silent, but "make lib" will be.
|
||||
|
||||
# Locate original tool
|
||||
TOOL_WITH_PATH=$(dirname "$0")/$TOOL
|
||||
ORIGINAL_TOOL=$(type -ap "${TOOL}" | grep -v -Fx "$TOOL_WITH_PATH" | head -n1)
|
||||
# Identify path to original tool. There is an edge-case here where the quiet wrapper is on the path via
|
||||
# a symlink or relative path, but "type -ap" yields the wrapper with it's normalised path. We use
|
||||
# the -ef operator to compare paths, to avoid picking the wrapper in this case (to avoid infinitely
|
||||
# recursing).
|
||||
while IFS= read -r ORIGINAL_TOOL; do
|
||||
if ! [[ $ORIGINAL_TOOL -ef "$0" ]]; then break; fi
|
||||
done < <(type -ap -- "$TOOL")
|
||||
|
||||
print_quoted_args() {
|
||||
# similar to printf '%q' "$@"
|
||||
|
Loading…
x
Reference in New Issue
Block a user