7 FILES_TO_PRINT="build/meson-logs/testlog.txt build/.ninja_log build/meson-logs/meson-log.txt"
9 for pr_file in $FILES_TO_PRINT; do
10 if [ -e "$pr_file" ]; then
15 # We capture the error logs as artifacts in Github Actions, no need to dump
16 # them via a EXIT handler.
17 [ -n "$GITHUB_WORKFLOW" ] || trap on_error EXIT
19 install_libabigail() {
23 wget -q "http://mirrors.kernel.org/sourceware/libabigail/${version}.tar.gz"
24 tar -xf ${version}.tar.gz
25 cd $version && autoreconf -vfi && cd -
27 cd $version/build && ../configure --prefix=$instdir && cd -
28 make -C $version/build all install
33 if [ "$AARCH64" = "true" ]; then
34 # convert the arch specifier
35 OPTS="$OPTS --cross-file config/arm/arm64_armv8_linux_gcc"
38 if [ "$BUILD_DOCS" = "true" ]; then
39 OPTS="$OPTS -Denable_docs=true"
42 if [ "$BUILD_32BIT" = "true" ]; then
43 OPTS="$OPTS -Dc_args=-m32 -Dc_link_args=-m32"
44 export PKG_CONFIG_LIBDIR="/usr/lib32/pkgconfig"
47 if [ "$DEF_LIB" = "static" ]; then
48 OPTS="$OPTS -Dexamples=l2fwd,l3fwd"
50 OPTS="$OPTS -Dexamples=all"
53 OPTS="$OPTS -Dmachine=default"
54 OPTS="$OPTS --default-library=$DEF_LIB"
55 OPTS="$OPTS --buildtype=debugoptimized"
56 meson build --werror $OPTS
59 if [ "$AARCH64" != "true" ]; then
63 if [ "$ABI_CHECKS" = "true" ]; then
64 LIBABIGAIL_VERSION=${LIBABIGAIL_VERSION:-libabigail-1.6}
66 if [ "$(cat libabigail/VERSION 2>/dev/null)" != "$LIBABIGAIL_VERSION" ]; then
68 # if we change libabigail, invalidate existing abi cache
72 if [ ! -d libabigail ]; then
73 install_libabigail $LIBABIGAIL_VERSION $(pwd)/libabigail
74 echo $LIBABIGAIL_VERSION > libabigail/VERSION
77 export PATH=$(pwd)/libabigail/bin:$PATH
79 REF_GIT_REPO=${REF_GIT_REPO:-https://dpdk.org/git/dpdk}
80 REF_GIT_TAG=${REF_GIT_TAG:-v19.11}
82 if [ "$(cat reference/VERSION 2>/dev/null)" != "$REF_GIT_TAG" ]; then
86 if [ ! -d reference ]; then
87 refsrcdir=$(readlink -f $(pwd)/../dpdk-$REF_GIT_TAG)
88 git clone --single-branch -b $REF_GIT_TAG $REF_GIT_REPO $refsrcdir
89 meson $OPTS -Dexamples= $refsrcdir $refsrcdir/build
90 ninja -C $refsrcdir/build
91 DESTDIR=$(pwd)/reference ninja -C $refsrcdir/build install
92 devtools/gen-abi.sh reference
93 find reference/usr/local -name '*.a' -delete
94 rm -rf reference/usr/local/bin
95 rm -rf reference/usr/local/share
96 echo $REF_GIT_TAG > reference/VERSION
99 DESTDIR=$(pwd)/install ninja -C build install
100 devtools/gen-abi.sh install
101 devtools/check-abi.sh reference install ${ABI_CHECKS_WARN_ONLY:-}
104 if [ "$RUN_TESTS" = "true" ]; then
105 sudo meson test -C build --suite fast-tests -t 3