-
Notifications
You must be signed in to change notification settings - Fork 92
105 lines (105 loc) · 3.59 KB
/
cmake.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
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
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
name: CMake build
on:
push:
paths:
- '.github/**/*.yml'
- 'CMakeLists.txt'
- 'cmake/**'
- '**.cc'
- '**.h'
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.ref }}
cancel-in-progress: true
jobs:
cmake-linux-x86_64:
runs-on: ubuntu-20.04
timeout-minutes: 15
steps:
- uses: actions/checkout@v4
- name: Update apt
run: sudo apt update
- name: Install ninja
run: sudo apt install ninja-build
- name: Configure
run: cmake -Bbuild -S. -G Ninja -DCMAKE_BUILD_TYPE=Release -DFP16_BUILD_COMPARATIVE_BENCHMARKS=ON
- name: Build
run: cmake --build build --parallel
- name: Test
run: ctest --test-dir build --parallel --output-on-failure
cmake-linux-x86:
runs-on: ubuntu-20.04
timeout-minutes: 15
steps:
- uses: actions/checkout@v4
- name: Update apt
run: sudo apt update
- name: Install multilib gcc
run: sudo apt install gcc-multilib g++-multilib
- name: Install ninja
run: sudo apt install ninja-build
- name: Configure
run: cmake -Bbuild -S. -G Ninja -DCMAKE_BUILD_TYPE=Release -DFP16_BUILD_COMPARATIVE_BENCHMARKS=ON
env:
CFLAGS: "-m32 -mfpmath=387"
CXXFLAGS: "-m32 -mfpmath=387"
LDFLAGS: "-m32"
- name: Build
run: cmake --build build --parallel
- name: Test
run: ctest --test-dir build --parallel --output-on-failure
cmake-macos-x86_64:
runs-on: macos-12
timeout-minutes: 15
steps:
- uses: actions/checkout@v4
- name: Configure
run: cmake -Bbuild -S. -G Xcode -DCMAKE_OSX_ARCHITECTURES=x86_64 -DFP16_BUILD_COMPARATIVE_BENCHMARKS=ON
- name: Build
run: cmake --build build --config Release --parallel -- -quiet
- name: Test
run: ctest --test-dir build --build-config Release --parallel --output-on-failure
cmake-macos-arm64:
runs-on: macos-14
timeout-minutes: 15
steps:
- uses: actions/checkout@v4
- name: Configure
run: cmake -Bbuild -S. -G Xcode -DCMAKE_OSX_ARCHITECTURES=arm64 -DFP16_BUILD_COMPARATIVE_BENCHMARKS=ON
- name: Build
run: cmake --build build --config Release --parallel -- -quiet
- name: Test
run: ctest --test-dir build --build-config Release --parallel --output-on-failure
cmake-windows-x86:
runs-on: windows-2019
timeout-minutes: 15
steps:
- uses: actions/checkout@v4
- name: Configure
run: cmake -Bbuild -S. -G "Visual Studio 16 2019" -A Win32 -DFP16_BUILD_COMPARATIVE_BENCHMARKS=ON
env:
CFLAGS: "/arch:IA32"
CXXFLAGS: "/arch:IA32"
- name: Build
run: cmake --build build --config Release --parallel
- name: Test
run: ctest --test-dir build --build-config Release --parallel --output-on-failure
cmake-windows-x64:
runs-on: windows-2019
timeout-minutes: 15
steps:
- uses: actions/checkout@v4
- name: Configure
run: cmake -Bbuild -S. -G "Visual Studio 16 2019" -A x64 -DFP16_BUILD_COMPARATIVE_BENCHMARKS=ON
- name: Build
run: cmake --build build --config Release --parallel
- name: Test
run: ctest --test-dir build --build-config Release --parallel --output-on-failure
cmake-windows-arm64:
runs-on: windows-2019
timeout-minutes: 15
steps:
- uses: actions/checkout@v4
- name: Configure
run: cmake -Bbuild -S. -G "Visual Studio 16 2019" -A ARM64 -DFP16_BUILD_COMPARATIVE_BENCHMARKS=ON
- name: Build
run: cmake --build build --config Release --parallel