1 name: Linux Valgrind Tests Build
5 # Pushes to the valgrind branch get the valgrind treatment
10 # Changing this build also gets it to run
12 - '.github/workflows/valgrind.yml'
16 runs-on: ${{ matrix.os }}
26 - name: Clone repository
27 uses: actions/checkout@v1
28 - name: Install packages
29 if: startsWith(matrix.os, 'ubuntu')
31 sudo apt-get update -qq
32 sudo apt-get install -y bison comerr-dev flex libcap-ng-dev lmdb-utils liblmdb-dev libdb-dev libedit-dev libjson-perl libldap2-dev libncurses5-dev libperl4-corelibs-perl libsqlite3-dev libkeyutils-dev pkg-config python3 ss-dev texinfo unzip netbase keyutils ldap-utils gdb apport curl libmicrohttpd-dev jq valgrind
33 # Temporary workaround for:
34 # https://github.com/actions/virtual-environments/issues/3185
35 sudo hostname localhost
38 CC: ${{ matrix.compiler }}
39 MAKEVARS: ${{ matrix.makevars }}
40 CONFIGURE_OPTS: ${{ matrix.configureopts }}
41 CHECK_TESTER_NO_VALGRIND: 'no-valgrind'
46 ../configure --srcdir=`dirname "$PWD"` --enable-maintainer-mode --enable-developer --with-ldap $CONFIGURE_OPTS --prefix=$HOME/inst CFLAGS="-g -ggdb3 -O0 -Wno-error=shadow -Wno-error=bad-function-cast -Wno-error=unused-function -Wno-error=unused-result -Wno-error=deprecated-declarations"
50 CC: ${{ matrix.compiler }}
51 MAKEVARS: ${{ matrix.makevars }}
56 - name: Valgrind output
58 find . -name \*.log -print0|xargs -0 grep '^==[0-9]*== ' || true
61 find build -depth -name \*.log | sed -e 's/trs$/log/' | tar -czf $HOME/logs-linux-valgrind.tgz --verbatim-files-from --files-from -
62 find build -name \*.trs|xargs grep -lw FAIL | sed -e 's/trs$/log/' | xargs cat
63 - name: Failed Test logs
66 find build -name \*.trs|xargs grep -lw FAIL | sed -e 's/trs$/log/' | xargs cat
67 - name: Upload Artifacts
68 uses: actions/upload-artifact@v2
71 path: '~/logs-linux-valgrind.tgz'