-
Notifications
You must be signed in to change notification settings - Fork 0
81 lines (67 loc) · 2.58 KB
/
Copy pathbuild-macos.yml
File metadata and controls
81 lines (67 loc) · 2.58 KB
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
name: Build macOS
on:
push:
pull_request:
permissions:
contents: read
jobs:
build:
name: ${{ matrix.name }}
runs-on: macos-15
timeout-minutes: 90
strategy:
fail-fast: false
matrix:
include:
- name: Path of Building
lua_tree: PathOfBuilding
version: "2.63.0"
bundle_name: "Path of Building"
bundle_id: ch.spidy.PathOfBuildingMac
app_support_dir: PathOfBuildingMac
dmg_name: PathOfBuilding-Mac
- name: Path of Building - PoE2
lua_tree: PathOfBuilding-PoE2
version: "0.15.0"
bundle_name: "Path of Building - PoE2"
bundle_id: ch.spidy.PathOfBuildingMacPoE2
app_support_dir: PathOfBuildingMacPoE2
dmg_name: PathOfBuilding-Mac-PoE2
steps:
- name: Checkout (with submodules)
uses: actions/checkout@v4
with:
submodules: recursive
- name: Cache vcpkg archives
uses: actions/cache@v4
with:
path: ~/.cache/vcpkg/archives
key: vcpkg-${{ hashFiles('SimpleGraphic/vcpkg.json', 'SimpleGraphic/vcpkg-configuration.json', 'vcpkg-triplets/arm64-osx-pob.cmake') }}
restore-keys: vcpkg-
# Stop pkg-config from leaking Homebrew's openssl into the curl build.
- name: Isolate from Homebrew
run: echo "PKG_CONFIG_PATH=" >> $GITHUB_ENV
- name: Configure
run: >
cmake -B build -DCMAKE_BUILD_TYPE=Release
-DPOB_LUA_TREE="${{ github.workspace }}/${{ matrix.lua_tree }}"
-DPOB_BUNDLE_VERSION="${{ matrix.version }}"
-DPOB_BUNDLE_NAME="${{ matrix.bundle_name }}"
-DPOB_BUNDLE_ID="${{ matrix.bundle_id }}"
-DPOB_APP_SUPPORT_DIR="${{ matrix.app_support_dir }}"
- name: Build
run: cmake --build build
- name: Install
run: cmake --install build --prefix "${{ runner.temp }}/stage"
- name: Ad-hoc sign
run: macos/sign.sh "${{ runner.temp }}/stage/${{ matrix.bundle_name }}.app"
- name: Verify signature
run: codesign --verify --deep --strict --verbose=2 "${{ runner.temp }}/stage/${{ matrix.bundle_name }}.app"
- name: Package DMG
run: macos/make-dmg.sh "${{ runner.temp }}/stage/${{ matrix.bundle_name }}.app" "${{ runner.temp }}/${{ matrix.dmg_name }}.dmg"
- name: Upload DMG artifact
uses: actions/upload-artifact@v4
with:
name: ${{ matrix.bundle_name }}-${{ github.sha }}
path: ${{ runner.temp }}/${{ matrix.dmg_name }}.dmg
if-no-files-found: error