summaryrefslogtreecommitdiff
path: root/.github/workflows/neozip-pkgcheck.yml
blob: 8325f3da4b54b5bed4724ea643b61ad8da8f25c7 (plain)
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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
name: "neozip: Package Check"

on:
  workflow_call:
  workflow_dispatch:

jobs:
  pkgcheck:
    name: ${{ matrix.name }}
    runs-on: ${{ matrix.os }}
    strategy:
      fail-fast: false
      matrix:
        include:
          - name: Ubuntu GCC
            os: ubuntu-latest
            compiler: gcc
            cxx-compiler: g++

          - name: Ubuntu GCC AARCH64
            os: ubuntu-24.04-arm
            compiler: gcc
            cxx-compiler: g++

          - name: macOS Clang
            os: macOS-latest
            compiler: clang
            cxx-compiler: clang++

    steps:
      - name: Checkout repository
        uses: actions/checkout@v6
        with:
          show-progress: 'false'

      - name: Install packages (Ubuntu)
        if: runner.os == 'Linux'
        run: |
          sudo apt-get update
          sudo apt-get install -y --no-install-recommends \
            abigail-tools \
            diffoscope \
            ninja-build

      - name: Install packages (macOS)
        if: runner.os == 'macOS'
        run: brew install ninja diffoscope
        env:
          HOMEBREW_NO_INSTALL_CLEANUP: 1

      - name: Compare builds
        working-directory: neozip
        run: sh test/pkgcheck.sh
        env:
          CC: ${{ matrix.compiler }}
          CXX: ${{ matrix.cxx-compiler }}

      - name: Compare builds (compat)
        working-directory: neozip
        run: sh test/pkgcheck.sh --zlib-compat
        env:
          CC: ${{ matrix.compiler }}

      - name: Check ABI
        if: runner.os != 'macOS'
        working-directory: neozip
        run: sh test/abicheck.sh --refresh-if
        env:
          CC: ${{ matrix.compiler }}
          CXX: ${{ matrix.cxx-compiler }}

      - name: Check ABI (compat)
        if: runner.os != 'macOS'
        working-directory: neozip
        run: sh test/abicheck.sh --zlib-compat --refresh-if
        env:
          CC: ${{ matrix.compiler }}
          CXX: ${{ matrix.cxx-compiler }}

      - name: Upload build errors
        uses: actions/upload-artifact@v7
        if: failure()
        with:
          name: ${{ matrix.name }}
          path: |
            neozip/**/*.abi
            neozip/btmp1/configure.log
            neozip/btmp2/configure.log
          retention-days: 30