Skip to content
This repository was archived by the owner on Feb 1, 2023. It is now read-only.

Commit 4328c62

Browse files
author
Release Manager
committed
Trac #29501: spkg-check.in: Do not use sdh_make to do 'make check', to avoid misleading messages
`sdh_make`, even when used for `make check`, prints the misleading message "Error building $PKG_NAME" {{{ $ grep sdh_make build/pkgs/*/spkg-check.in build/pkgs/awali/spkg-check.in:sdh_make check build/pkgs/barvinok/spkg-check.in:sdh_make check build/pkgs/cocoalib/spkg-check.in:sdh_make check build/pkgs/e_antic/spkg-check.in:sdh_make check build/pkgs/fflas_ffpack/spkg-check.in:sdh_make check build/pkgs/isl/spkg-check.in:sdh_make check build/pkgs/openblas/spkg-check.in:sdh_make tests $OPENBLAS_CONFIGURE build/pkgs/openblas/spkg-check.in: sdh_make tests $OPENBLAS_CONFIGURE build/pkgs/polylib/spkg-check.in:sdh_make check build/pkgs/polymake/spkg-check.in:sdh_make test build/pkgs/symengine/spkg-check.in:sdh_make test build/pkgs/tides/spkg-check.in:sdh_make check AM_CFLAGS="" AM_FFLAGS="" }}} In the present ticket, we fix this. We note that when `sdh_make` is used for building in `spkg-install.in`, there is duplication with a message printed by `sage-spkg` afterwards. For example in https://github.com/mkoeppe/sage/runs/581877049: {{{ [python3-3.7.3.p1] TypeError: can only concatenate str (not "NoneType") to str [python3-3.7.3.p1] make[2]: *** [Makefile:626: sharedmods] Error 1 [python3-3.7.3.p1] make[2]: Target 'all' not remade because of errors. [python3-3.7.3.p1] make[2]: Leaving directory '/home/runner/work/sage/sage/.tox/local-conda-forge-ubuntu- minimal/local/var/tmp/sage/build/python3-3.7.3.p1/src' [python3-3.7.3.p1] ************************************************* ******************************* [python3-3.7.3.p1] Error building python3-3.7.3.p1 [python3-3.7.3.p1] ************************************************* ******************************* [python3-3.7.3.p1] [python3-3.7.3.p1] real 3m37.614s [python3-3.7.3.p1] user 1m37.298s [python3-3.7.3.p1] sys 0m11.320s [python3-3.7.3.p1] ************************************************************************ [python3-3.7.3.p1] Error building package python3-3.7.3.p1 [python3-3.7.3.p1] ************************************************************************ [python3-3.7.3.p1] Full log file: /home/runner/work/sage/sage/logs/pkgs/python3-3.7.3.p1.log }}} However, as this does not have the potential to mislead, we will take care of this on another ticket. URL: https://trac.sagemath.org/29501 Reported by: mkoeppe Ticket author(s): Matthias Koeppe Reviewer(s): Dima Pasechnik, John Palmieri
2 parents 9ad1188 + c53ddc7 commit 4328c62

File tree

12 files changed

+24
-20
lines changed

12 files changed

+24
-20
lines changed

build/bin/sage-dist-helpers

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -184,6 +184,11 @@ sdh_make() {
184184
}
185185

186186

187+
sdh_make_check() {
188+
echo "Checking $PKG_NAME"
189+
${MAKE:-make} check "$@" || sdh_die "Failures checking $PKG_NAME"
190+
}
191+
187192
sdh_make_install() {
188193
echo "Installing $PKG_NAME"
189194
if [ -n "$SAGE_DESTDIR" ]; then

build/bin/sage-spkg

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1024,7 +1024,7 @@ if [ "$SAGE_CHECK" = "yes" -o "$SAGE_CHECK" = "warn" ]; then
10241024
if [ $? -ne 0 ]; then
10251025
TEST_SUITE_RESULT="failed"
10261026
if [ "$SAGE_CHECK" = "warn" ]; then
1027-
error_msg "Warning: Error testing package $PKG_NAME (ignored)" "make check"
1027+
error_msg "Warning: Failures testing package $PKG_NAME (ignored)" "make check"
10281028
else
10291029
error_msg "Error testing package $PKG_NAME" "make check"
10301030
exit 1

build/pkgs/awali/spkg-check.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
cd src/_build
2-
sdh_make check
2+
sdh_make_check

build/pkgs/barvinok/spkg-check.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
cd src
2-
sdh_make check
2+
sdh_make_check

build/pkgs/cocoalib/spkg-check.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
cd src/
2-
sdh_make check
2+
sdh_make_check

build/pkgs/e_antic/spkg-check.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@
55
###############################################################################
66

77
cd src
8-
sdh_make check
8+
sdh_make_check
Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
cd src
2-
sdh_make check
2+
# Do not use sdh_make or sdh_make_check here because we are doing our own error
3+
# handling below
4+
${MAKE:-make} check
35

46
if [ $? -ne 0 ]; then
5-
cat tests/test-suite.log
6-
exit 1
7+
cat tests/test-suite.log
8+
exit 1
79
fi

build/pkgs/isl/spkg-check.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
cd src
2-
sdh_make check
2+
sdh_make_check

build/pkgs/openblas/spkg-check.in

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -17,20 +17,17 @@ if [ "x$SAGE_FAT_BINARY" = "xyes" ]; then
1717
OPENBLAS_CONFIGURE="$OPENBLAS_CONFIGURE TARGET=PRESCOTT"
1818
fi
1919

20-
sdh_make tests $OPENBLAS_CONFIGURE
20+
${MAKE:-make} tests $OPENBLAS_CONFIGURE
2121
if [ $? -ne 0 ]; then
2222
# First make sure we already didn't set a target
2323
if [[ $OPENBLAS_CONFIGURE == *"TARGET"* ]]; then
24-
sdh_die "Error while running the OpenBlas testsuite ... exiting"
24+
sdh_die "Failures while running the OpenBLAS testsuite ... exiting"
2525
else
2626
# The recommended TARGET is ATOM if CPU fails
2727
# See https://github.com/xianyi/OpenBLAS/issues/1204
2828
OPENBLAS_CONFIGURE="$OPENBLAS_CONFIGURE TARGET=ATOM"
29-
echo "Error while testing the OpenBLAS testsuite"
30-
echo "Retrying the OpenBAS testsuit with TARGET=ATOM"
31-
sdh_make tests $OPENBLAS_CONFIGURE
32-
if [ $? -ne 0 ]; then
33-
sdh_die "Error while running the OpenBLAS testsuite ... exiting"
34-
fi
29+
echo "Failures while testing the OpenBLAS testsuite"
30+
echo "Retrying the OpenBLAS testsuite with TARGET=ATOM"
31+
${MAKE:-make} tests $OPENBLAS_CONFIGURE
3532
fi
3633
fi

build/pkgs/polylib/spkg-check.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
cd src
2-
sdh_make check
2+
sdh_make_check

0 commit comments

Comments
 (0)