From 75c97d271047f1e6041d49a9a96e3aca2de4cc60 Mon Sep 17 00:00:00 2001 From: Francesco Chemolli <5175948+kinkie@users.noreply.github.com> Date: Tue, 17 Dec 2024 15:06:29 +0000 Subject: [PATCH] CI: Add OpenBSD build tests for staged commits (#1964) Use a GitHub-hosted VM to create OpenBSD test environment. Requires GitHub repository configuration that permits the use of `vmactions/openbsd-vm@v1` Action. We have not enabled ccache optimization for OpenBSD tests because we do not know how to copy updated ccache files from VM back into runner. --- .github/workflows/slow.yaml | 58 +++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) diff --git a/.github/workflows/slow.yaml b/.github/workflows/slow.yaml index 534b293543..728445b656 100644 --- a/.github/workflows/slow.yaml +++ b/.github/workflows/slow.yaml @@ -181,3 +181,61 @@ jobs: with: name: build-logs-freebsd-${{ matrix.osversion }} path: btlayer-*.log + + openbsd: + runs-on: ubuntu-22.04 + + steps: + - name: Checkout Sources + uses: actions/checkout@v4 + + - name: Run test-builds + id: test-builds + uses: vmactions/openbsd-vm@v1 + with: + usesh: true + prepare: | + pkg_add \ + autoconf-2.72p0 \ + autoconf-archive \ + automake-1.16.5 \ + bash \ + coreutils \ + cppunit \ + git \ + ggrep \ + gmake \ + libltdl \ + libtool \ + libnettle \ + libxml \ + libtool \ + m4 \ + metaauto + + mkdir $HOME/bin + ln -s /usr/local/bin/ggrep $HOME/bin/grep + + run: | + export MAKE=gmake + export pjobs="-j`gnproc`" + export AUTOMAKE_VERSION=1.16 + export amver=${AUTOMAKE_VERSION} + export ACLOCAL_AUTOMAKE_DIR="/usr/local/share/aclocal-${AUTOMAKE_VERSION}" + export ACLOCAL_PATH="/usr/local/share/aclocal:/usr/local/share/aclocal-${AUTOMAKE_VERSION}" + export AUTOCONF_VERSION=2.72 + export acver=${AUTOCONF_VERSION} + export ltver=2.4.2 + export CFLAGS='-Wno-compound-token-split-by-macro' + export LDFLAGS="-L/usr/local/lib" + # until we remove GNUisms from our grep commands, + # shadow system `grep` with `ggrep` installed/linked earlier + export PATH="$HOME/bin:$PATH" + ./test-builds.sh + + - name: Publish build logs + if: success() || failure() + uses: actions/upload-artifact@v4 + with: + name: build-logs-openbsd + path: btlayer-*.log -- 2.47.2