Suppress expected output from commands when support_xxx is false

Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
This commit is contained in:
Gilles Peskine 2025-11-03 19:34:56 +01:00
parent 9540bfd9e1
commit c3e6cf2995
2 changed files with 3 additions and 3 deletions

View File

@ -229,7 +229,7 @@ support_build_baremetal () {
# Older Glibc versions include time.h from other headers such as stdlib.h,
# which makes the no-time.h-in-baremetal check fail. Ubuntu 16.04 has this
# problem, Ubuntu 18.04 is ok.
! grep -q -F time.h /usr/include/x86_64-linux-gnu/sys/types.h
! grep -s -q -F time.h /usr/include/x86_64-linux-gnu/sys/types.h
}
component_test_no_psa_crypto_full_cmake_asan () {

View File

@ -19,7 +19,7 @@ support_test_aesni () {
# in component_test_aesni_m32.
(gcc -v 2>&1 | grep Target | grep -q x86_64) &&
[[ "$HOSTTYPE" == "x86_64" && "$OSTYPE" == "linux-gnu" ]] &&
(lscpu | grep -qw aes)
(lscpu | grep -qw aes) 2>/dev/null
}
component_test_aesni () { # ~ 60s
@ -73,7 +73,7 @@ component_test_aesni () { # ~ 60s
}
support_test_aesni_m32 () {
support_test_m32_no_asm && (lscpu | grep -qw aes)
support_test_m32_no_asm && (lscpu | grep -qw aes) 2>/dev/null
}
component_test_aesni_m32 () { # ~ 60s