Skip to content

Commit a0d60f4

Browse files
committed
Fixed an incorrect use of the RUNNER_NAME environment variable in the
build_all script.
1 parent 80da58a commit a0d60f4

File tree

1 file changed

+24
-8
lines changed

1 file changed

+24
-8
lines changed

build/build_all

Lines changed: 24 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -304,10 +304,8 @@ EOF
304304
if [ -n "$RUNNER_OS" ]; then
305305
echo "RUNNER_NAME: $RUNNER_NAME"
306306
echo "RUNNER_OS: $RUNNER_OS"
307-
echo "RUNNER_ACTION: $RUNNER_ACTION"
308307
fi
309308

310-
311309
os=unknown
312310
if [ -n "$RUNNER_OS" ]; then
313311
case "$RUNNER_OS" in
@@ -324,6 +322,7 @@ fi
324322
ubuntu_clang_hack=0
325323
# If invoked by GitHub Actions CI...
326324
if [ -n "$RUNNER_OS" ]; then
325+
327326
if [ "$os" = linux ]; then
328327
# Assume that the OS being Linux means Ubuntu.
329328
case "$CC" in
@@ -333,14 +332,31 @@ if [ -n "$RUNNER_OS" ]; then
333332
esac
334333
fi
335334

336-
# Disable conformance tests for ARM since these tests take too long.
337-
# Do similarly for Windows.
338-
case "$RUNNER_NAME" in
339-
ubuntu-*-arm|windows-*)
340-
echo "WARNING: disabling conformance tests"
341-
enable_conformance_test=0
335+
# Disable conformance tests in the following situations since the tests
336+
# take too long:
337+
# - on the ARM architecture
338+
# - on Windows
339+
case "$os" in
340+
linux)
341+
arch="$(uname -m)" || panic "uname failed"
342+
echo "architecture: $arch"
343+
case "$arch" in
344+
aarch*|arm*)
345+
is_arm=1;;
346+
*)
347+
is_arm=0;;
348+
esac
349+
;;
350+
windows)
351+
is_arm=0
342352
;;
343353
esac
354+
echo "ARM architecture: $is_arm"
355+
if [ "$is_arm" -ne 0 ]; then
356+
echo "WARNING: disabling conformance tests"
357+
enable_conformance_test=0
358+
fi
359+
344360
fi
345361
#ubuntu_clang_hack=0
346362

0 commit comments

Comments
 (0)