-
Notifications
You must be signed in to change notification settings - Fork 88
66 lines (57 loc) · 1.82 KB
/
osx.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
name: OSX-build
on:
push:
branches:
- 'master'
- 'develop'
- 'release/**'
tags:
- '**'
pull_request:
types: [opened,synchronize]
workflow_dispatch:
inputs:
debug_enabled:
description: 'Run the build with tmate debugging enabled by `debug_enabled` keyword (https://github.com/marketplace/actions/debugging-with-tmate)'
required: false
default: false
concurrency:
group: ${{ github.workflow }}-${{ (github.head_ref && github.ref) || github.run_id }}
cancel-in-progress: true
jobs:
osx-clang-omp:
strategy:
fail-fast: false
matrix:
config:
- {shared: "ON", build_type: "Debug", name: "omp/debug/shared", "mixed": "OFF"}
- {shared: "OFF", build_type: "Release", name: "omp/release/static", "mixed": "ON"}
name: ${{ matrix.config.name }}
runs-on: [macos-latest]
steps:
- name: Checkout the latest code (shallow clone)
uses: actions/checkout@v4
- name: setup
run: |
brew install libomp
- name: info
run: |
g++ -v
cmake --version
- name: Debug over SSH (tmate)
uses: mxschmitt/action-tmate@v3.5
if: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.debug_enabled }}
- name: configure
run: |
mkdir build
mkdir install
export INSTALL_PREFIX=`pwd`/install
cd build
cmake .. -DCMAKE_PREFIX_PATH=/opt/homebrew/opt/libomp/ -DCMAKE_CXX_FLAGS=-Wpedantic -DBUILD_SHARED_LIBS=${{ matrix.config.shared }} -DCMAKE_INSTALL_PREFIX=${INSTALL_PREFIX} -DCMAKE_BUILD_TYPE=${{ matrix.config.build_type }} -DGINKGO_MIXED_PRECISION=${{ matrix.config.mixed }}
make -j8
ctest -j10 --output-on-failure
- name: install
run: |
cd build
make install
make test_install