Skip to content

#531 : reuse old style signal handler #789

#531 : reuse old style signal handler

#531 : reuse old style signal handler #789

Workflow file for this run

name: CI
on:
push:
branches: ["**"]
pull_request:
branches: [master]
jobs:
build-on-mac:
strategy:
matrix:
runs-on: [macos-latest]
runs-on: ${{ matrix.runs-on }}
steps:
- uses: actions/checkout@v2
- name: Configure Homebrew cache
uses: actions/cache@v2
with:
path: |
~/Library/Caches/Homebrew
key: ${{ runner.os }}-v1
- name: brew install
run: brew install --display-times meson gettext gtk+3 jsoncpp glog gtk-mac-integration libsigc++@2
- name: meson
run: meson setup build
- name: build
run: meson compile -C build
- name: install
run: meson install -C build
- name: test
run: |
sudo ifconfig lo0 alias 127.0.0.2 up
sudo ifconfig lo0 alias 127.0.0.3 up
sudo ifconfig lo0 alias 127.0.0.4 up
meson test -C build --verbose --no-stdsplit
build-on-linux:
strategy:
matrix:
runs-on: [ubuntu-20.04]
compiler: [g++, clang++]
runs-on: ${{ matrix.runs-on }}
steps:
- uses: actions/checkout@v2
- name: apt install
run: sudo apt update && sudo apt install -y libgoogle-glog-dev libgtk-3-dev libglib2.0-dev libjsoncpp-dev g++ meson xvfb libsigc++-2.0-dev appstream
- name: meson
run: |
meson --version
meson setup build
env:
CXX: ${{ matrix.compiler }}
- name: build
run: ninja -v -C build
- name: install
run: sudo meson install -C build
- name: test
run: |
xvfb-run -a meson test -C build --verbose --no-stdsplit
codecov:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
- name: apt install
run: sudo apt update && sudo apt install -y lcov libgoogle-glog-dev libgtk-3-dev libglib2.0-dev libjsoncpp-dev g++ meson xvfb libsigc++-2.0-dev appstream
- name: meson
run: meson setup -D b_coverage=true build
- name: build
run: ninja -v -C build
- name: install
run: sudo meson install -C build
- name: test
run: |
xvfb-run -a meson test -C build --verbose --no-stdsplit
- name: lcov
run: |
lcov --directory . --capture --output-file coverage.info; # capture coverage info
lcov --remove coverage.info '/usr/*' --output-file coverage.info; # filter out system
lcov --remove coverage.info '*Test*' --output-file coverage.info; # filter out system
lcov --remove coverage.info '*gtest*' --output-file coverage.info; # filter out system
lcov --list coverage.info; #debug info
- uses: codecov/codecov-action@v1
with:
fail_ci_if_error: true # optional (default = false)
verbose: true # optional (default = false)
build_job:
# The host should always be linux
runs-on: ubuntu-20.04
name: Build on ${{ matrix.distro }} ${{ matrix.arch }}
# Run steps on a matrix of 3 arch/distro combinations
strategy:
matrix:
include:
- arch: aarch64
distro: ubuntu20.04
- arch: ppc64le
distro: ubuntu20.04
#- arch: s390x
# distro: ubuntu20.04
- arch: armv7
distro: ubuntu20.04
steps:
- uses: actions/checkout@v2.1.0
- uses: uraimo/run-on-arch-action@v2.0.5
name: Build artifact
id: build
with:
arch: ${{ matrix.arch }}
distro: ${{ matrix.distro }}
# Not required, but speeds up builds
githubToken: ${{ github.token }}
# Create an artifacts directory
setup: |
mkdir -p "${PWD}/artifacts"
# Mount the artifacts directory as /artifacts in the container
dockerRunArgs: |
--volume "${PWD}/artifacts:/artifacts"
# Pass some environment variables to the container
env: | # YAML, but pipe character is necessary
artifact_name: git-${{ matrix.distro }}_${{ matrix.arch }}
# The shell to run commands with in the container
shell: /bin/sh
# Install some dependencies in the container. This speeds up builds if
# you are also using githubToken. Any dependencies installed here will
# be part of the container image that gets cached, so subsequent
# builds don't have to re-install them. The image layer is cached
# publicly in your project's package repository, so it is vital that
# no secrets are present in the container state or logs.
install: |
case "${{ matrix.distro }}" in
ubuntu*|jessie|stretch|buster)
apt-get update -q -y
apt-get install -q -y git libgoogle-glog-dev libgtk-3-dev libglib2.0-dev libjsoncpp-dev g++ meson xvfb libsigc++-2.0-dev appstream
;;
fedora*)
dnf -y update
dnf -y install git which
;;
alpine*)
apk update
apk add git
;;
esac
# Produce a binary artifact and place it in the mounted volume
run: |
meson setup build
ninja -v -C build
meson install -C build
xvfb-run -a meson test -C build --verbose --no-stdsplit
# - name: Show the artifact
# # Items placed in /artifacts in the container will be in
# # ${PWD}/artifacts on the host.
# run: |
# ls -al "${PWD}/artifacts"