Skip to content

Commit 5bf5d16

Browse files
author
Caspar van Leeuwen
committed
Switch order
1 parent 7c9c9f9 commit 5bf5d16

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

bot/build.sh

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -171,16 +171,16 @@ else
171171
fi
172172
echo "bot/build.sh: EESSI_ACCELERATOR_TARGET_OVERRIDE='${EESSI_ACCELERATOR_TARGET_OVERRIDE}'"
173173

174-
# check if CPU architecture of the build host matches our expectation
174+
# Log the full lscpu and os-release info:
175+
lscpu > _bot_job${SLURM_JOB_ID}.lscpu
176+
cat /etc/os-release > _bot_job${SLURM_JOB_ID}.os
177+
178+
# Also: fetch CPU flags into an array, so that we can implement a hard check against a reference
175179
lscpu_flags_line=$(lscpu | grep "Flags:")
176180
# strip leading "Flags:" and spaces, and put result in a bash array
177181
if [[ $lscpu_flags =~ Flags:\ (.*) ]]; then lscpu_flags=(${BASH_REMATCH[1]}); fi
178182
# for now, just print
179183
echo "bot/build.sh: CPU flags=${lscpu_flags[@]}"
180-
# Also, log the full lscpu and os-release info:
181-
lscpu > _bot_job${SLURM_JOB_ID}.lscpu
182-
cat /etc/os-release > _bot_job${SLURM_JOB_ID}.os
183-
184184
# TODO: an actual comparison with a reference bash array, e.g. through
185185
# diff_result=$(diff <(printf "%s\n" "${lscpu_flags[@]}" | sort) <(printf "%s\n" "${lscpu_flags_ref[@]}" | sort))
186186
# if [ ! -z "$diff_result" ]; then

0 commit comments

Comments
 (0)