|
4 | 4 | name: macOS builds |
5 | 5 | on: |
6 | 6 | workflow_call: |
7 | | - # inputs: |
8 | | - # organizeAndRelease: |
9 | | - # description: "Should we organize and release our artifacts?" |
10 | | - # type: boolean |
11 | | - # default: false |
12 | 7 | workflow_dispatch: |
13 | 8 |
|
14 | 9 | jobs: |
15 | 10 | build-macos: |
16 | 11 | runs-on: macos-latest |
17 | 12 |
|
18 | 13 | steps: |
19 | | - # Step 1: Checkout the repository |
20 | 14 | - name: Checkout Repository |
21 | 15 | uses: actions/checkout@v4 |
22 | 16 |
|
23 | | - # Step 2: Set up Homebrew and install dependencies |
24 | 17 | - name: Install Dependencies |
25 | 18 | run: | |
26 | 19 | brew update |
27 | 20 | brew install cmake ninja |
28 | 21 | # Add any additional dependencies here |
29 | 22 | |
30 | | - # Step 3: Configure the build with CMake |
31 | 23 | - name: Configure Build |
32 | 24 | run: | |
33 | 25 | mkdir build |
34 | 26 | cd build |
35 | 27 | cmake -G Ninja \ |
36 | 28 | -DCMAKE_BUILD_TYPE=RelWithDebInfo \ |
| 29 | + -DCMAKE_OSX_ARCHITECTURES="x86_64;arm64" \ |
37 | 30 | -DCMAKE_INSTALL_PREFIX=../install \ |
38 | 31 | .. |
39 | 32 |
|
40 | | - # Step 4: Build the project |
41 | 33 | - name: Build OpenXR Loader |
42 | 34 | run: | |
43 | 35 | cd build |
44 | 36 | cmake --build . --target install |
45 | 37 |
|
46 | | - # Step 5: Package the build artifacts |
| 38 | + - name: Add a note about the Quarantine flag |
| 39 | + run: | |
| 40 | + cd install |
| 41 | + echo "After unzipping the package, run 'xattr -d com.apple.quarantine lib/libopenxr_loader.dylib' to allow using the pre-built loader on macOS computers" > README.md |
| 42 | +
|
47 | 43 | - name: Package Artifacts |
48 | 44 | run: | |
49 | 45 | cd install |
50 | | - tar -czvf OpenXR-Loader-macos-package.tar.gz * |
| 46 | + tar -czvf openxr_loader_macos.tar.gz * |
51 | 47 |
|
52 | | - # Step 6: Upload the build artifacts |
53 | 48 | - name: Upload Artifact |
54 | 49 | uses: actions/upload-artifact@v4 |
55 | 50 | with: |
56 | | - name: OpenXR-Loader-macos-package |
57 | | - path: install/OpenXR-Loader-macos-package.tar.gz |
| 51 | + name: openxr_loader_macos |
| 52 | + path: install/openxr_loader_macos.tar.gz |
0 commit comments