File: ci.yml

package info (click to toggle)
cgif 0.5.2-1
  • links: PTS
  • area: main
  • in suites: forky, sid
  • size: 440 kB
  • sloc: ansic: 3,943; python: 45; makefile: 2
file content (56 lines) | stat: -rw-r--r-- 2,035 bytes parent folder | download | duplicates (2)
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
48
49
50
51
52
53
54
55
56
name: CI
on:
  - push
  - pull_request
jobs:
  build:
    name: ${{ matrix.name }}
    runs-on: ${{ matrix.os }}
    strategy:
      matrix:
        include:
          - name: "Linux x64 (Ubuntu 22.04)"
            os: ubuntu-22.04
            config: {}
          - name: "Linux 32-bit (Ubuntu 22.04)"
            os: ubuntu-22.04
            config: { cflags: "-m32"}
          - name: "macOS 14"
            os: macos-14
            config: {}
          - name: "Windows 2022"
            os: windows-2022
            config: {}
    env:
      CFLAGS: ${{ matrix.config.cflags }}
    steps:
      - uses: actions/checkout@v4
      - uses: actions/setup-python@v5
      - name: Dependencies (ubuntu)
        if: contains(matrix.os, 'ubuntu')
        run: sudo apt update && sudo apt install -y gifsicle valgrind meson
      - name: Dependencies (ubuntu 32-bit)
        if: contains(matrix.name, '32-bit')
        run: sudo apt update && sudo apt install -y gcc-multilib
      - name: Dependencies (macos)
        if: contains(matrix.os, 'macos')
        run: brew install gifsicle meson
      - name: Dependencies (windows)
        if: contains(matrix.os, 'windows')
        run: choco install gifsicle && pip3 install meson ninja
      - name: Setup
        run: meson setup build -Dtests=true -Dfuzzer=true
      - name: Build
        run: meson compile -C build
      - name: Test
        run: meson test -C build
      - name: Verify GIF test output (gifsicle)
        run: for f in build/*.gif; do gifsicle --no-ignore-errors --info $f || exit 1; done
        shell: bash
      - name: Valgrind
        if: contains(matrix.name, 'Linux x64')
        run: meson test -C build --list | grep -v zip | grep -v checksums | sed 's/^/"/;s/$/"/' | xargs meson test -C build/ --wrap "valgrind --memcheck:leak-check=full --memcheck:show-leak-kinds=definite --memcheck:error-exitcode=1"
        shell: bash
      - name: Valgrind output
        if: contains(matrix.name, 'Linux x64')
        run: cat build/meson-logs/testlog-valgrind.txt