forked from ImageMagick/ImageMagick
-
Notifications
You must be signed in to change notification settings - Fork 3
52 lines (41 loc) · 1.13 KB
/
cmake-build.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
name: CMake portable build
on:
push:
branches:
- cmake
- cmake2
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Get Conan
id : conan
uses: turtlebrowser/get-conan@main
- name: Cache conan artifacts
id: conan-artifacts
uses: actions/cache@v4
with:
path: ~/.conan2
key: ${{ runner.os }}-conan
- name: Create default profile
run: conan profile detect || echo ok
shell: bash
- name: Install all delegates
run: conan install . -of build
- name: Generate CMake build (POSIX)
run: cd build && cmake .. -DCMAKE_TOOLCHAIN_FILE=conan_toolchain.cmake -DCMAKE_BUILD_TYPE=Release
if: runner.os != 'Windows'
- name: Generate CMake build (Windows)
run: |
cd build
conanbuild.bat
cmake .. -G "Visual Studio 15 2017" -DCMAKE_TOOLCHAIN_FILE="conan_toolchain.cmake"
shell: cmd
if: runner.os == 'Windows'
- name: Build
run: cmake --build build