workflows: build: Add Meson build job

This commit adds a parallel job to run Meson test builds.
This commit is contained in:
Ernestas Kulik 2023-07-28 21:19:46 +03:00
parent 6df5328a90
commit 2ed38ed822
2 changed files with 27 additions and 5 deletions

View file

@ -9,7 +9,7 @@ name: Build test
- main
jobs:
build:
build-make:
runs-on: ubuntu-latest
strategy:
@ -35,3 +35,25 @@ jobs:
- name: Run check
run: |
SETUPTOOLS_SCM_PRETEND_VERSION="0" make check
build-meson:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
os: [ "alpine", "archlinux", "fedora", "ubuntu" ]
container:
image: ${{ matrix.os }}
steps:
- name: Check out source
uses: actions/checkout@v3
- name: Install dependencies
run: "${GITHUB_WORKSPACE}/scripts/install-deps.sh"
- name: Build
run: |
meson setup . _build
meson compile -C _build

View file

@ -12,20 +12,20 @@ fi
if [ "$NAME" = "Arch Linux" ]
then
pacman -Syu --needed --noconfirm bison diffutils flex gcc git libyaml \
make pkgconf python python-setuptools-scm swig valgrind which
make meson pkgconf python python-setuptools-scm swig valgrind which
elif [ "$NAME" = "Alpine Linux" ]
then
apk add build-base bison coreutils flex git yaml yaml-dev python3-dev \
py3-setuptools_scm swig valgrind
meson py3-setuptools_scm swig valgrind
elif [ "$NAME" = "Fedora Linux" ]
then
dnf install -y bison diffutils flex gcc git libyaml libyaml-devel \
make python3-devel python3-setuptools swig valgrind which
make meson python3-devel python3-setuptools swig valgrind which
elif [ "$NAME" = "Ubuntu" ]
then
apt update
apt install -yq build-essential bison flex git libyaml-dev pkg-config \
python3-dev python3-setuptools python3-setuptools-scm swig valgrind
meson python3-dev python3-setuptools python3-setuptools-scm swig valgrind
else
echo "ERROR: OS name is not provided."
exit 1