summaryrefslogtreecommitdiff
path: root/tools/ci/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'tools/ci/scripts')
-rwxr-xr-xtools/ci/scripts/azure/mxetest.sh2
-rwxr-xr-xtools/ci/scripts/circleci/gcc6_sanitize_tests.sh4
-rwxr-xr-xtools/ci/scripts/circleci/gcc6_tests.sh8
-rwxr-xr-xtools/ci/scripts/circleci/gcc7_sanitize_tests.sh4
-rwxr-xr-xtools/ci/scripts/circleci/gcc7_tests.sh8
-rwxr-xr-xtools/ci/scripts/exit.sh2
-rwxr-xr-xtools/ci/scripts/init.sh57
-rwxr-xr-xtools/ci/scripts/runtest.sh8
-rwxr-xr-xtools/ci/scripts/runtests.sh8
9 files changed, 61 insertions, 40 deletions
diff --git a/tools/ci/scripts/azure/mxetest.sh b/tools/ci/scripts/azure/mxetest.sh
index 30cf8342e..5745b69a0 100755
--- a/tools/ci/scripts/azure/mxetest.sh
+++ b/tools/ci/scripts/azure/mxetest.sh
@@ -6,7 +6,7 @@ echo docker login registry.gitlab.com -u azure -p TOKEN
docker login registry.gitlab.com -u azure -p $GITLABTOKEN || exit 1
export IMAGE="registry.gitlab.com/manaplus/mxe:gcc6_shared_${BITS}"
-export COMMAND="./tools/ci/jobs/mxe_gcc6_tests.sh --without-manaplusgame --without-dyecmd"
+export COMMAND="./tools/ci/jobs/mxe_gcc6_tests.sh --without-gameclient --without-dyecmd"
export PACKAGES="bash"
./tools/ci/scripts/docker_run_cross.sh || exit 1
mkdir dlls || true
diff --git a/tools/ci/scripts/circleci/gcc6_sanitize_tests.sh b/tools/ci/scripts/circleci/gcc6_sanitize_tests.sh
index afaae9234..2f0d5684c 100755
--- a/tools/ci/scripts/circleci/gcc6_sanitize_tests.sh
+++ b/tools/ci/scripts/circleci/gcc6_sanitize_tests.sh
@@ -6,7 +6,7 @@ echo "Current node: ${CIRCLE_NODE_INDEX}"
case $CIRCLE_NODE_INDEX in
0)
export IMAGE=debian:stretch
- export COMMAND="./tools/ci/jobs/gcc6_sanitize_tests.sh --enable-unittests=yes --without-dyecmd --without-manaplusgame --without-opengl --with-sdl2"
+ export COMMAND="./tools/ci/jobs/gcc6_sanitize_tests.sh --enable-unittests=yes --without-dyecmd --without-gameclient --without-opengl --with-sdl2"
export PACKAGES="gcc-6 g++-6 ${LIBS_PACKAGES} ${SDL2} valgrind"
./tools/ci/scripts/docker_run.sh
;;
@@ -15,7 +15,7 @@ case $CIRCLE_NODE_INDEX in
;;
2)
export IMAGE=debian:stretch
- export COMMAND="./tools/ci/jobs/gcc6_sanitize_tests.sh --enable-unittests=yes --without-dyecmd --without-manaplusgame --without-opengl"
+ export COMMAND="./tools/ci/jobs/gcc6_sanitize_tests.sh --enable-unittests=yes --without-dyecmd --without-gameclient --without-opengl"
export PACKAGES="gcc-6 g++-6 ${LIBS_PACKAGES} ${SDL1} valgrind"
./tools/ci/scripts/docker_run.sh
;;
diff --git a/tools/ci/scripts/circleci/gcc6_tests.sh b/tools/ci/scripts/circleci/gcc6_tests.sh
index 644f4b75f..d15a7dad9 100755
--- a/tools/ci/scripts/circleci/gcc6_tests.sh
+++ b/tools/ci/scripts/circleci/gcc6_tests.sh
@@ -6,25 +6,25 @@ echo "Current node: ${CIRCLE_NODE_INDEX}"
case $CIRCLE_NODE_INDEX in
0)
export IMAGE=i386/debian:stretch
- export COMMAND="./tools/ci/jobs/gcc6_tests.sh --without-dyecmd --without-manaplusgame --without-opengl"
+ export COMMAND="./tools/ci/jobs/gcc6_tests.sh --without-dyecmd --without-gameclient --without-opengl"
export PACKAGES="gcc-6 g++-6 ${LIBS_PACKAGES} ${SDL1} valgrind"
./tools/ci/scripts/docker_run.sh
;;
1)
export IMAGE=debian:stretch
- export COMMAND="./tools/ci/jobs/gcc6_tests.sh --without-dyecmd --without-manaplusgame --without-opengl --enable-glibcdebug --with-sdl2"
+ export COMMAND="./tools/ci/jobs/gcc6_tests.sh --without-dyecmd --without-gameclient --without-opengl --enable-glibcdebug --with-sdl2"
export PACKAGES="gcc-6 g++-6 ${LIBS_PACKAGES} ${SDL2} valgrind"
./tools/ci/scripts/docker_run.sh
;;
2)
export IMAGE=i386/debian:stretch
- export COMMAND="./tools/ci/jobs/gcc6_tests.sh --without-dyecmd --without-manaplusgame --without-opengl --enable-glibcdebug --with-sdl2"
+ export COMMAND="./tools/ci/jobs/gcc6_tests.sh --without-dyecmd --without-gameclient --without-opengl --enable-glibcdebug --with-sdl2"
export PACKAGES="gcc-6 g++-6 ${LIBS_PACKAGES} ${SDL2} valgrind"
./tools/ci/scripts/docker_run.sh
;;
3)
export IMAGE=debian:stretch
- export COMMAND="./tools/ci/jobs/gcc6_tests.sh --without-dyecmd --without-manaplusgame --without-opengl --enable-glibcdebug"
+ export COMMAND="./tools/ci/jobs/gcc6_tests.sh --without-dyecmd --without-gameclient --without-opengl --enable-glibcdebug"
export PACKAGES="gcc-6 g++-6 ${LIBS_PACKAGES} ${SDL1} valgrind"
./tools/ci/scripts/docker_run.sh
;;
diff --git a/tools/ci/scripts/circleci/gcc7_sanitize_tests.sh b/tools/ci/scripts/circleci/gcc7_sanitize_tests.sh
index 1b3c9a8fa..c6b9e9e05 100755
--- a/tools/ci/scripts/circleci/gcc7_sanitize_tests.sh
+++ b/tools/ci/scripts/circleci/gcc7_sanitize_tests.sh
@@ -9,7 +9,7 @@ case $CIRCLE_NODE_INDEX in
;;
1)
export IMAGE=debian:buster
- export COMMAND="./tools/ci/jobs/gcc7_sanitize_tests.sh --enable-unittests=yes --without-dyecmd --without-manaplusgame --without-opengl"
+ export COMMAND="./tools/ci/jobs/gcc7_sanitize_tests.sh --enable-unittests=yes --without-dyecmd --without-gameclient --without-opengl"
export PACKAGES="gcc-7 g++-7 ${LIBS_PACKAGES} ${SDL1} valgrind"
./tools/ci/scripts/docker_run.sh
;;
@@ -18,7 +18,7 @@ case $CIRCLE_NODE_INDEX in
;;
3)
export IMAGE=debian:buster
- export COMMAND="./tools/ci/jobs/gcc7_sanitize_tests.sh --enable-unittests=yes --without-dyecmd --without-manaplusgame --without-opengl --with-sdl2"
+ export COMMAND="./tools/ci/jobs/gcc7_sanitize_tests.sh --enable-unittests=yes --without-dyecmd --without-gameclient --without-opengl --with-sdl2"
export PACKAGES="gcc-7 g++-7 ${LIBS_PACKAGES} ${SDL2} valgrind"
./tools/ci/scripts/docker_run.sh
;;
diff --git a/tools/ci/scripts/circleci/gcc7_tests.sh b/tools/ci/scripts/circleci/gcc7_tests.sh
index 0acab9a7b..dae8188fc 100755
--- a/tools/ci/scripts/circleci/gcc7_tests.sh
+++ b/tools/ci/scripts/circleci/gcc7_tests.sh
@@ -6,25 +6,25 @@ echo "Current node: ${CIRCLE_NODE_INDEX}"
case $CIRCLE_NODE_INDEX in
0)
export IMAGE=debian:buster
- export COMMAND="./tools/ci/jobs/gcc7_tests.sh --without-dyecmd --without-manaplusgame --without-opengl --enable-glibcdebug --with-sdl2"
+ export COMMAND="./tools/ci/jobs/gcc7_tests.sh --without-dyecmd --without-gameclient --without-opengl --enable-glibcdebug --with-sdl2"
export PACKAGES="gcc-7 g++-7 ${LIBS_PACKAGES} ${SDL2} valgrind"
./tools/ci/scripts/docker_run.sh
;;
1)
export IMAGE=i386/debian:buster
- export COMMAND="./tools/ci/jobs/gcc7_tests.sh --without-dyecmd --without-manaplusgame --without-opengl --enable-glibcdebug --with-sdl2"
+ export COMMAND="./tools/ci/jobs/gcc7_tests.sh --without-dyecmd --without-gameclient --without-opengl --enable-glibcdebug --with-sdl2"
export PACKAGES="gcc-7 g++-7 ${LIBS_PACKAGES} ${SDL2} valgrind"
./tools/ci/scripts/docker_run.sh
;;
2)
export IMAGE=debian:buster
- export COMMAND="./tools/ci/jobs/gcc7_tests.sh --without-dyecmd --without-manaplusgame --without-opengl --enable-glibcdebug"
+ export COMMAND="./tools/ci/jobs/gcc7_tests.sh --without-dyecmd --without-gameclient --without-opengl --enable-glibcdebug"
export PACKAGES="gcc-7 g++-7 ${LIBS_PACKAGES} ${SDL1} valgrind"
./tools/ci/scripts/docker_run.sh
;;
3)
export IMAGE=i386/debian:buster
- export COMMAND="./tools/ci/jobs/gcc7_tests.sh --without-dyecmd --without-manaplusgame --without-opengl"
+ export COMMAND="./tools/ci/jobs/gcc7_tests.sh --without-dyecmd --without-gameclient --without-opengl"
export PACKAGES="gcc-7 g++-7 ${LIBS_PACKAGES} ${SDL1} valgrind"
./tools/ci/scripts/docker_run.sh
;;
diff --git a/tools/ci/scripts/exit.sh b/tools/ci/scripts/exit.sh
index 1f13618c1..5c63a1d1b 100755
--- a/tools/ci/scripts/exit.sh
+++ b/tools/ci/scripts/exit.sh
@@ -1,3 +1,3 @@
#!/usr/bin/env bash
-rm $ERRFILE
+rm -f "$ERRFILE"
diff --git a/tools/ci/scripts/init.sh b/tools/ci/scripts/init.sh
index 9512e9b66..396dae182 100755
--- a/tools/ci/scripts/init.sh
+++ b/tools/ci/scripts/init.sh
@@ -2,8 +2,10 @@
export dir=$(pwd)
export ERRFILE=${dir}/logs/${LOGFILE}
+export ERRFILE_UNFILTERED=${ERRFILE%.log}.unfiltered.log
-rm ${ERRFILE}
+rm -f "$ERRFILE"
+rm -f "$ERRFILE_UNFILTERED"
function do_init {
$CC --version
@@ -104,11 +106,11 @@ function check_error {
}
function run_configure_simple {
- rm $ERRFILE
+ rm -f "$ERRFILE"
echo "autoreconf -i"
autoreconf -i 2>$ERRFILE
check_error $?
- rm $ERRFILE
+ rm -f "$ERRFILE"
echo "./configure $*"
./configure $* 2>$ERRFILE
check_error $?
@@ -117,14 +119,14 @@ function run_configure_simple {
function run_configure {
run_configure_simple $*
- rm $ERRFILE
+ rm -f "$ERRFILE"
cd po
echo "make update-gmo"
make update-gmo 2>$ERRFILE
check_error $?
cd ..
- rm $ERRFILE
+ rm -f "$ERRFILE"
cd po
echo "make update-po"
make update-po 2>$ERRFILE
@@ -133,14 +135,14 @@ function run_configure {
}
function run_cmake {
- rm $ERRFILE
+ rm -f "$ERRFILE"
echo "cmake ."
cmake . 2>$ERRFILE
check_error $?
}
function run_make {
- rm $ERRFILE
+ rm -f "$ERRFILE"
if [ "$JOBS" == "" ]; then
export JOBS=2
echo "No JOBS defined"
@@ -150,10 +152,20 @@ function run_make {
echo "make -j${JOBS} V=0 $*"
make -j${JOBS} V=0 $* 2>$ERRFILE
check_error $?
+
+ for path in "src/manaplus" "src/dyecmd"; do
+ if [[ -f "$path" ]]; then
+ stat -c '%s %n' "$path"
+ strip -o "$path.stripped" "$path"
+ stat -c '%s %n' "$path.stripped"
+ else
+ printf "%s does not exist, no strip & exe size summary\n" "$path"
+ fi
+ done
}
function run_make_check {
- rm $ERRFILE
+ rm -f "$ERRFILE"
if [ "$JOBS" == "" ]; then
export JOBS=2
echo "No JOBS defined"
@@ -205,13 +217,19 @@ function run_gcov {
function run_check_warnings {
if [[ -s "$ERRFILE" ]]; then
+ printf "Warnings detected in %s:\n" "$ERRFILE"
cat $ERRFILE
exit 1
fi
+
+ if [[ -s "$ERRFILE_UNFILTERED" ]]; then
+ printf "Warnings detected in %s. The maintainer might want to take a peek, sometimes.\n" \
+ "$ERRFILE_UNFILTERED"
+ fi
}
function run_h {
- rm $ERRFILE
+ rm -f "$ERRFILE"
echo "$CC -c -x c++ $* $includes */*/*/*/*.h */*/*/*.h */*/*.h */*.h *.h"
$CC -c -x c++ $* $includes */*/*/*/*.h */*/*/*.h */*/*.h */*.h *.h 2>$ERRFILE
if [[ -s "$ERRFILE" ]]; then
@@ -221,7 +239,7 @@ function run_h {
}
function run_tarball {
- rm $ERRFILE
+ rm -f "$ERRFILE"
echo "make dist-xz"
make dist-xz 2>$ERRFILE
check_error $?
@@ -234,14 +252,17 @@ function run_tarball {
}
function run_mplint {
- rm $ERRFILE
- echo "mplint/src/mplint $*"
- mplint/src/mplint "$@" \
- | grep -v \
- -e "src/unittests/doctest.h" \
- -e "src/unittests/catch.hpp" \
- -e "src/debug/" \
- > "$ERRFILE"
+ rm -f "$ERRFILE"
+ echo "\$ ./mplint $*"
+
+ ./mplint "$@" > "$ERRFILE.unfiltered"
+
+ # if grep does not find any messages, it exits non-zero
+ grep -v \
+ -e "src/unittests/doctest.h" \
+ -e "src/unittests/catch.hpp" \
+ -e "src/debug/" \
+ < "$ERRFILE.unfiltered" > "$ERRFILE" || true
run_check_warnings
}
diff --git a/tools/ci/scripts/runtest.sh b/tools/ci/scripts/runtest.sh
index e629fc514..622e04da0 100755
--- a/tools/ci/scripts/runtest.sh
+++ b/tools/ci/scripts/runtest.sh
@@ -18,7 +18,7 @@ function check_is_run {
}
function check_assert {
- grep -A 20 "Assert:" "${HOME}/.local/share/mana/manaplus.log"
+ grep -A 20 "Assert:" "${HOME}/.local/share/mana/manaverse.log"
if [ "$?" == 0 ]; then
echo "Assert found in log"
exit 1
@@ -31,9 +31,9 @@ function wait_for_servers_list {
echo "wait for servers list ${n}"
check_is_run
# check here
- grep "Skipping servers list update" "${HOME}/.local/share/mana/manaplus.log" && return
- grep "Servers list updated" "${HOME}/.local/share/mana/manaplus.log" && return
- grep "Error: servers list updating error" "${HOME}/.local/share/mana/manaplus.log"
+ grep "Skipping servers list update" "${HOME}/.local/share/mana/manaverse.log" && return
+ grep "Servers list updated" "${HOME}/.local/share/mana/manaverse.log" && return
+ grep "Error: servers list updating error" "${HOME}/.local/share/mana/manaverse.log"
if [ "$?" == 0 ]; then
echo "Servers list downloading error"
exit 1
diff --git a/tools/ci/scripts/runtests.sh b/tools/ci/scripts/runtests.sh
index 1263521f9..1afe5815f 100755
--- a/tools/ci/scripts/runtests.sh
+++ b/tools/ci/scripts/runtests.sh
@@ -26,8 +26,8 @@ while true; do
rm "/root/.config/mana/mana/config.xml"
rm "${HOME}/.config/mana/mana/serverlistplus.xml"
rm "/root/.config/mana/mana/serverlistplus.xml"
- rm "${HOME}/.local/share/mana/manaplus.log"
- rm "/root/.local/share/mana/manaplus.log"
+ rm "${HOME}/.local/share/mana/manaverse.log"
+ rm "/root/.local/share/mana/manaverse.log"
./tools/ci/scripts/runtest.sh
if [ "$?" != 0 ]; then
exit 1
@@ -45,8 +45,8 @@ echo "existing config runs"
n=0
while true; do
echo "run test ${n}"
- rm "${HOME}/.local/share/mana/manaplus.log"
- rm "/root/.local/share/mana/manaplus.log"
+ rm "${HOME}/.local/share/mana/manaverse.log"
+ rm "/root/.local/share/mana/manaverse.log"
./tools/ci/scripts/runtest.sh
if [ "$?" != 0 ]; then
exit 1