check-all.sh

Sun, 22 Dec 2024 11:34:05 +0100

author
Mike Becker <universe@uap-core.de>
date
Sun, 22 Dec 2024 11:34:05 +0100
changeset 1043
256ea5a36b5a
parent 1017
b0098854071f
permissions
-rwxr-xr-x

add function prototypes and macros for string conversion function

issue #532

981
723bbd868f35 add script to invoke make check with different configurations
Mike Becker <universe@uap-core.de>
parents:
diff changeset
1 #!/bin/sh
723bbd868f35 add script to invoke make check with different configurations
Mike Becker <universe@uap-core.de>
parents:
diff changeset
2
987
53e22f112b11 add configure option for szmul
Mike Becker <universe@uap-core.de>
parents: 981
diff changeset
3 # backup config
53e22f112b11 add configure option for szmul
Mike Becker <universe@uap-core.de>
parents: 981
diff changeset
4 cp config.mk config.mk.bak
53e22f112b11 add configure option for szmul
Mike Becker <universe@uap-core.de>
parents: 981
diff changeset
5
53e22f112b11 add configure option for szmul
Mike Becker <universe@uap-core.de>
parents: 981
diff changeset
6 function perform_check
53e22f112b11 add configure option for szmul
Mike Becker <universe@uap-core.de>
parents: 981
diff changeset
7 {
53e22f112b11 add configure option for szmul
Mike Becker <universe@uap-core.de>
parents: 981
diff changeset
8 if ! make clean check > /dev/null ; then
981
723bbd868f35 add script to invoke make check with different configurations
Mike Becker <universe@uap-core.de>
parents:
diff changeset
9 echo "fail."
723bbd868f35 add script to invoke make check with different configurations
Mike Becker <universe@uap-core.de>
parents:
diff changeset
10 else
723bbd868f35 add script to invoke make check with different configurations
Mike Becker <universe@uap-core.de>
parents:
diff changeset
11 echo "ok."
723bbd868f35 add script to invoke make check with different configurations
Mike Becker <universe@uap-core.de>
parents:
diff changeset
12 fi
987
53e22f112b11 add configure option for szmul
Mike Becker <universe@uap-core.de>
parents: 981
diff changeset
13 }
53e22f112b11 add configure option for szmul
Mike Becker <universe@uap-core.de>
parents: 981
diff changeset
14
988
15b3ca7ee33f make ucx C++ compatible again (and add tests for it) - fixes #486
Mike Becker <universe@uap-core.de>
parents: 987
diff changeset
15 function perform_check_cxx
15b3ca7ee33f make ucx C++ compatible again (and add tests for it) - fixes #486
Mike Becker <universe@uap-core.de>
parents: 987
diff changeset
16 {
15b3ca7ee33f make ucx C++ compatible again (and add tests for it) - fixes #486
Mike Becker <universe@uap-core.de>
parents: 987
diff changeset
17 # we cannot mute the warnings, so throw every everything
15b3ca7ee33f make ucx C++ compatible again (and add tests for it) - fixes #486
Mike Becker <universe@uap-core.de>
parents: 987
diff changeset
18 if ! make check-cxx > /dev/null 2> /dev/null ; then
15b3ca7ee33f make ucx C++ compatible again (and add tests for it) - fixes #486
Mike Becker <universe@uap-core.de>
parents: 987
diff changeset
19 echo "fail."
15b3ca7ee33f make ucx C++ compatible again (and add tests for it) - fixes #486
Mike Becker <universe@uap-core.de>
parents: 987
diff changeset
20 else
15b3ca7ee33f make ucx C++ compatible again (and add tests for it) - fixes #486
Mike Becker <universe@uap-core.de>
parents: 987
diff changeset
21 echo "ok."
15b3ca7ee33f make ucx C++ compatible again (and add tests for it) - fixes #486
Mike Becker <universe@uap-core.de>
parents: 987
diff changeset
22 fi
15b3ca7ee33f make ucx C++ compatible again (and add tests for it) - fixes #486
Mike Becker <universe@uap-core.de>
parents: 987
diff changeset
23 }
15b3ca7ee33f make ucx C++ compatible again (and add tests for it) - fixes #486
Mike Becker <universe@uap-core.de>
parents: 987
diff changeset
24
987
53e22f112b11 add configure option for szmul
Mike Becker <universe@uap-core.de>
parents: 981
diff changeset
25 for cc in clang gcc; do
53e22f112b11 add configure option for szmul
Mike Becker <universe@uap-core.de>
parents: 981
diff changeset
26 CC=$cc ./configure --debug > /dev/null
53e22f112b11 add configure option for szmul
Mike Becker <universe@uap-core.de>
parents: 981
diff changeset
27 printf "Check $cc... "
53e22f112b11 add configure option for szmul
Mike Becker <universe@uap-core.de>
parents: 981
diff changeset
28 perform_check
988
15b3ca7ee33f make ucx C++ compatible again (and add tests for it) - fixes #486
Mike Becker <universe@uap-core.de>
parents: 987
diff changeset
29 printf "Check $cc (c++)... "
15b3ca7ee33f make ucx C++ compatible again (and add tests for it) - fixes #486
Mike Becker <universe@uap-core.de>
parents: 987
diff changeset
30 perform_check_cxx
981
723bbd868f35 add script to invoke make check with different configurations
Mike Becker <universe@uap-core.de>
parents:
diff changeset
31 done
723bbd868f35 add script to invoke make check with different configurations
Mike Becker <universe@uap-core.de>
parents:
diff changeset
32
987
53e22f112b11 add configure option for szmul
Mike Becker <universe@uap-core.de>
parents: 981
diff changeset
33 printf "Check w/o szmul builtin... "
53e22f112b11 add configure option for szmul
Mike Becker <universe@uap-core.de>
parents: 981
diff changeset
34 ./configure --debug --disable-szmul-builtin > /dev/null
53e22f112b11 add configure option for szmul
Mike Becker <universe@uap-core.de>
parents: 981
diff changeset
35 perform_check
988
15b3ca7ee33f make ucx C++ compatible again (and add tests for it) - fixes #486
Mike Becker <universe@uap-core.de>
parents: 987
diff changeset
36 printf "Check w/o szmul builtin (c++)... "
15b3ca7ee33f make ucx C++ compatible again (and add tests for it) - fixes #486
Mike Becker <universe@uap-core.de>
parents: 987
diff changeset
37 perform_check_cxx
981
723bbd868f35 add script to invoke make check with different configurations
Mike Becker <universe@uap-core.de>
parents:
diff changeset
38
1017
b0098854071f add check for C23 compatibility
Mike Becker <universe@uap-core.de>
parents: 988
diff changeset
39 printf "Check gcc C23 preview... "
b0098854071f add check for C23 compatibility
Mike Becker <universe@uap-core.de>
parents: 988
diff changeset
40 CC=gcc CFLAGS=-std=c23 ./configure --debug > /dev/null
b0098854071f add check for C23 compatibility
Mike Becker <universe@uap-core.de>
parents: 988
diff changeset
41 perform_check
b0098854071f add check for C23 compatibility
Mike Becker <universe@uap-core.de>
parents: 988
diff changeset
42
987
53e22f112b11 add configure option for szmul
Mike Becker <universe@uap-core.de>
parents: 981
diff changeset
43 # clean build files and restore config
53e22f112b11 add configure option for szmul
Mike Becker <universe@uap-core.de>
parents: 981
diff changeset
44 make clean > /dev/null
53e22f112b11 add configure option for szmul
Mike Becker <universe@uap-core.de>
parents: 981
diff changeset
45 mv config.mk.bak config.mk

mercurial