File tree Expand file tree Collapse file tree 1 file changed +11
-3
lines changed Expand file tree Collapse file tree 1 file changed +11
-3
lines changed Original file line number Diff line number Diff line change 1717 build test all \
1818 clean quickcheck check-defined-CYCLES
1919
20+ SHELL := /bin/bash
2021.DEFAULT_GOAL := build
22+
2123all : build
2224
2325W := $(EXEC_WRAPPER )
2426
27+ # Detect available SHA256 command
28+ SHA256SUM := $(shell command -v shasum >/dev/null 2>&1 && echo "shasum -a 256" || (command -v sha256sum >/dev/null 2>&1 && echo "sha256sum" || echo "") )
29+ ifeq ($(SHA256SUM ) ,)
30+ $(error Neither 'shasum' nor 'sha256sum' found. Please install one of these tools.)
31+ endif
32+
2533include test/mk/config.mk
2634include test/mk/components.mk
2735include test/mk/rules.mk
@@ -35,11 +43,11 @@ test: run_kat run_func run_acvp
3543 $(Q ) echo " Everything checks fine!"
3644
3745run_kat_44 : kat_44
38- $(W ) $(MLDSA44_DIR ) /bin/gen_KAT44 | sha256sum | cut -d " " -f 1 | xargs ./META.sh ML-DSA-44 kat-sha256
46+ set -o pipefail ; $(W ) $(MLDSA44_DIR ) /bin/gen_KAT44 | $( SHA256SUM ) | cut -d " " -f 1 | xargs ./META.sh ML-DSA-44 kat-sha256
3947run_kat_65 : kat_65
40- $(W ) $(MLDSA65_DIR ) /bin/gen_KAT65 | sha256sum | cut -d " " -f 1 | xargs ./META.sh ML-DSA-65 kat-sha256
48+ set -o pipefail ; $(W ) $(MLDSA65_DIR ) /bin/gen_KAT65 | $( SHA256SUM ) | cut -d " " -f 1 | xargs ./META.sh ML-DSA-65 kat-sha256
4149run_kat_87 : kat_87
42- $(W ) $(MLDSA87_DIR ) /bin/gen_KAT87 | sha256sum | cut -d " " -f 1 | xargs ./META.sh ML-DSA-87 kat-sha256
50+ set -o pipefail ; $(W ) $(MLDSA87_DIR ) /bin/gen_KAT87 | $( SHA256SUM ) | cut -d " " -f 1 | xargs ./META.sh ML-DSA-87 kat-sha256
4351run_kat : run_kat_44 run_kat_65 run_kat_87
4452
4553run_func_44 : func_44
You can’t perform that action at this time.
0 commit comments