-
Notifications
You must be signed in to change notification settings - Fork 4
47 lines (44 loc) · 1.55 KB
/
ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
name: CI
on: [push, pull_request]
jobs:
build:
strategy:
matrix:
os: [ubuntu-20.04, ubuntu-22.04]
compiler: [gcc]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 1
- uses: actions/cache@v4
with:
path: |
/home/runner/.ccache
/home/runner/.cache/ccache
key: ccache:${{ matrix.os }}:${{ github.sha }}
restore-keys: 'ccache:${{ matrix.os }}:'
- name: update
run: |
echo deb https://psha.org.ru/debian/ `echo ${{ matrix.os }} | tr -d -` contrib backports | sudo tee /etc/apt/sources.list.d/psha.org.ru.list
sudo wget -O/etc/apt/trusted.gpg.d/psha.org.ru.gpg https://psha.org.ru/debian/pubkey.gpg
sudo apt update
- name: install deps
run: sudo apt install ccache cmake meson pkg-config libfmt-dev libyaml-dev zlib1g-dev liblz4-dev libspdlog-dev rapidjson-dev libgtest-dev googletest librhash-dev python3-dev cython3 python3-pytest python3-yaml python3-lz4 python3-decorator
- name: configure
# env:
# CC: ccache ${{ matrix.compiler }}
# CXX: ccache ${{ matrix.compiler }} -xc++
run: meson build
- name: build
run: ninja -vC build -j2
- name: pybuild
run: |
cd python
python3 setup.py build_ext --inplace --library-dirs=../build/src --rpath=`pwd`/../build/src
- name: test
run: |
meson test -C build --no-rebuild --print-errorlogs -v
cd python
python3 -m pytest --log-level=DEBUG -v
# vim: sts=2 sw=2 et