From 306ee04ffd027e021cf2b495bedbc7e088c710d0 Mon Sep 17 00:00:00 2001 From: David Sterba Date: Tue, 7 Mar 2023 20:47:57 +0100 Subject: [PATCH] btrfs-progs: tests: add more build tests for old microarchitectures As reported in #588, build fails on some microarchitectures when the blake2 macros do not coverall combinations. Extend the build tests and add some uarchs to test. Signed-off-by: David Sterba --- tests/build-tests.sh | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/tests/build-tests.sh b/tests/build-tests.sh index 5ee958c6..80609908 100755 --- a/tests/build-tests.sh +++ b/tests/build-tests.sh @@ -26,7 +26,7 @@ check_result() { ret=$1 - str="RESULT of target($target) conf($conf): " + str="RESULT of target($target) conf($conf) CFLAGS($CFLAGS): " case $ret in 0) str="$str OK";; *) str="$str FAIL";; @@ -39,13 +39,19 @@ $str" buildme() { make clean-all - ./autogen.sh && configure "$conf" || die "configure not working with: $@" + ./autogen.sh && CFLAGS="$CFLAGS" configure "$conf" || die "configure not working with: $@" $make clean $make $opts $target check_result "$?" echo "VERDICT: $verdict" } +buildme_cflags() { + CFLAGS="$1" + buildme + CFLAGS='' +} + build_make_targets() { # defaults target= @@ -85,6 +91,8 @@ jobs=16 opts="-j${jobs} $@" verdict= target= +export CLFAGS +CFLAGS= conf= build_make_targets @@ -122,6 +130,13 @@ build_make_targets conf='--with-crypto=libkcapi' build_make_targets +# Old architectures +conf='--with-crypto=builtin' +buildme_cflags '-march=core2' + +conf='--with-crypto=builtin' +buildme_cflags '-march=x86-64-v3' + # debugging builds, just the default targets target='D=1' buildme