From 16a907530751ed953575ed10d599b368fcc17515 Mon Sep 17 00:00:00 2001 From: Sylvestre Ledru Date: Wed, 8 Jul 2020 16:26:53 +0200 Subject: [PATCH] improve the update-binfmts test --- debian/qualify-clang.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/debian/qualify-clang.sh b/debian/qualify-clang.sh index 0b55a8d3..dd4faca8 100755 --- a/debian/qualify-clang.sh +++ b/debian/qualify-clang.sh @@ -294,7 +294,8 @@ fi clang-$VERSION -O3 -emit-llvm foo.c -c -o foo.bc chmod +x foo.bc # only run if the binfmt is installed correctly -if /usr/sbin/update-binfmts --display llvm-$VERSION-runtime.binfmt &> /dev/null; then +/usr/sbin/update-binfmts --display llvm-$VERSION-runtime.binfmt &> foo.log || true +if grep -q "interpreter = /usr/bin/lli-" foo.log; then if ! ./foo.bc|grep -q "lli foo"; then echo "executing ./foo.bc failed" ./foo.bc