blob: 8330211cce3677532c849a3b72d44d32ca101df5 (
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
|
name: OSB
on: [workflow_call, workflow_dispatch]
jobs:
cmake:
name: ${{ matrix.name }}
runs-on: ${{ matrix.os }}
timeout-minutes: 80
strategy:
fail-fast: false
matrix:
include:
- name: Ubuntu GCC OSB
os: ubuntu-latest
compiler: gcc
cxx-compiler: g++
build-dir: ../build
build-src-dir: ../zlib-ng
cmake-args: -DWITH_BENCHMARKS=ON
- name: Ubuntu GCC OSB add_subdirectory
os: ubuntu-latest
compiler: gcc
cxx-compiler: g++
build-dir: ../build
build-src-dir: ../zlib-ng/test/add-subdirectory-project
cmake-args: -DWITH_BENCHMARKS=ON
steps:
- name: Checkout repository
uses: actions/checkout@v6
with:
show-progress: false
- name: Make source tree read-only
shell: bash
run: chmod -R a-w .
- name: Generate project files
shell: bash
run: |
cmake -S ${{ matrix.build-src-dir || '.' }} -B ${{ matrix.build-dir || '.' }} \
${{ matrix.cmake-args }} \
-DWITH_MAINTAINER_WARNINGS=ON
env:
CC: ${{ matrix.compiler }}
CXX: ${{ matrix.cxx-compiler }}
CI: true
- name: Compile source code
run: cmake --build ${{ matrix.build-dir || '.' }} --verbose -j5
- name: Run test cases
run: ctest --verbose -C Release --output-on-failure --max-width 120 -j 5
working-directory: ${{ matrix.build-dir || '.' }}
- name: Make source tree writable
shell: bash
run: chmod -R +w .
- name: Upload build errors
uses: actions/upload-artifact@v7
if: failure()
with:
name: ${{ matrix.name }}
path: |
**/CMakeFiles/CMakeOutput.log
**/CMakeFiles/CMakeError.log
**/Testing/Temporary/*
retention-days: 30
|