-
Notifications
You must be signed in to change notification settings - Fork 21
51 lines (43 loc) · 1.4 KB
/
build-macos-amd64.yaml
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
name: Build macOS Amd64 Project
on:
push:
branches:
- automation
pull_request:
jobs:
build-macos-amd64:
runs-on: macos-latest
steps:
- name: Checkout Code
uses: actions/checkout@v4
with:
submodules: true
- name: Set up x86_64 Homebrew
run: |
sudo softwareupdate --install-rosetta --agree-to-license
arch -x86_64 /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
echo 'eval "$(/usr/local/bin/brew shellenv)"' >> ~/.zshrc
eval "$(/usr/local/bin/brew shellenv)"
- name: Install Dependencies (x86_64)
run: |
arch -x86_64 brew install cmake ninja llvm boost
- name: Configure Build
run: |
mkdir -p build
cd build
arch -x86_64 cmake .. -DCMAKE_BUILD_TYPE=Release -G "Ninja" \
-DCMAKE_OSX_ARCHITECTURES=x86_64 \
-DBOOST_ROOT=$(arch -x86_64 brew --prefix boost)
- name: Build Project
run: |
cd build
arch -x86_64 cmake --build .
- name: Prepare Artifacts
run: |
mkdir -p artifacts
cp build/bin/* artifacts/
- name: Archive Artifacts
uses: actions/upload-artifact@v4
with:
name: macos-amd64-artifacts
path: artifacts/