-
-
Notifications
You must be signed in to change notification settings - Fork 178
112 lines (110 loc) · 3.29 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
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
106
107
108
109
110
111
112
name: CI
on: [push, pull_request]
# cancel older workflow runs
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
linux:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
CMAKE_ARGS:
-
- -DCMAKE_BUILD_TYPE=Debug
- -DCMAKE_CXX_COMPILER=clang++ -DCMAKE_C_COMPILER=clang
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 1
submodules: recursive
- run: "grep -m 1 'flags' /proc/cpuinfo | cut -d: -f2 | tr ' ' '\n'"
- run: cmake ${{ matrix.CMAKE_ARGS }} .
- run: make -j4 VERBOSE=1
- if: ${{ ! contains(matrix.CMAKE_ARGS, 'CMAKE_BUILD_TYPE') }}
run: make -j4 test ARGS=-V
- if: ${{ contains(matrix.CMAKE_ARGS, 'CMAKE_BUILD_TYPE') }}
run: ./SMHasher --test=Sanity,Speed,Cyclic,Zeroes,Seed
aarch64:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 1
submodules: recursive
- run: sudo gem install apt-spy2 && sudo apt-spy2 fix
- run: sudo apt-get update -y
- run: sudo apt-get install -o Acquire::Retries=5 -y gcc-aarch64-linux-gnu g++-aarch64-linux-gnu
- run: cmake -DCMAKE_TOOLCHAIN_FILE=CMakeARM64Cross.txt
- run: make -j4 VERBOSE=1
armv7:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 1
submodules: recursive
- run: sudo gem install apt-spy2 && sudo apt-spy2 fix
- run: sudo apt-get update -y
- run: sudo apt-get install -o Acquire::Retries=5 -y gcc-arm-linux-gnueabihf g++-arm-linux-gnueabihf
- run: cmake -DCMAKE_TOOLCHAIN_FILE=CMakeARMCross.txt
- run: make -j4 VERBOSE=1
macOS:
name: macOS
runs-on: macOS-latest
steps:
#- name: init
# run: brew install automake
- uses: actions/checkout@v3
with:
fetch-depth: 1
submodules: true
- run: CXXFLAGS='-std=c++17' cmake .
- run: make -j4 VERBOSE=1
- run: make -j4 test ARGS=-V
windows:
runs-on: windows-2019
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 1
submodules: recursive
- run: cmake -G "Visual Studio 16 2019" -A x64 -DCMAKE_BUILD_TYPE=Release .
- run: cmake --build . --config Release --verbose
- run: Release\SMHasher.exe --test=VerifyAll,Sanity,Speed,Cyclic,Zeroes,Seed
mingw:
name: mingw
runs-on: windows-latest
env:
MSYS2_DIR: msys64
MSYS2_ARCH: x86_64
MSYSTEM: MINGW64
ARCH: win64
PLATFORM: x64
#PATH: "C:\%MSYS2_DIR%\%MSYSTEM%\bin;C:\%MSYS2_DIR%\usr\bin;%PATH%"
steps:
# see https://github.com/msys2/setup-msys2
- name: setup-msys2
uses: msys2/setup-msys2@v2
with:
path-type: minimal
update: true
install: >-
git
cmake
base-devel
mingw-w64-x86_64-toolchain
- run: reg add "HKLM\Software\Microsoft\Windows\Windows Error Reporting" /f /v DontShowUI /d 1
- uses: actions/checkout@v3
with:
fetch-depth: 1
submodules: recursive
- shell: msys2 {0}
run: cmake .
- shell: msys2 {0}
run: make -j4 VERBOSE=1
continue-on-error: true
- shell: msys2 {0}
run: make -j4 test ARGS=-V
continue-on-error: true