Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build packages for Mac Catalyst #333

Open
wants to merge 1 commit into
base: trunk
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
72 changes: 72 additions & 0 deletions .github/workflows/cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -275,6 +275,78 @@ jobs:
path: dist
name: dist

# -----
maccatalyst-x86_64:
# Config
name: release - maccatalyst-x86_64
runs-on: macos-latest
env:
TARGET: x86_64-apple-ios-macabi
ARCHIVE_NAME: wgpu-maccatalyst-x86_64
MACOSX_DEPLOYMENT_TARGET: "10.13"
RUSTFLAGS: "-C link-args=-Wl,-install_name,@rpath/libwgpu_native.dylib"
steps:
# Common part (same for each build)
- uses: actions/checkout@v3
with:
submodules: true
- name: Set WGPU_NATIVE_VERSION
run: echo "WGPU_NATIVE_VERSION=${GITHUB_REF/refs\/tags\//}" >> $GITHUB_ENV
shell: bash
- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@stable
with:
targets: ${{ env.TARGET }}
- name: Setup caching
uses: Swatinem/rust-cache@v2
with:
key: build-${{ env.TARGET }}-${{ env.CACHE_SUFFIX }}
# Build
- name: Build
run: make package
# Upload (same for each build)
- name: Upload
uses: actions/upload-artifact@v3
with:
path: dist
name: dist

# -----
maccatalyst-aarch64:
# Config
name: release - maccatalyst-aarch64
runs-on: macos-latest
env:
TARGET: aarch64-apple-ios-macabi
ARCHIVE_NAME: wgpu-maccatalyst-aarch64
MACOSX_DEPLOYMENT_TARGET: "11.0"
RUSTFLAGS: "-C link-args=-Wl,-install_name,@rpath/libwgpu_native.dylib"
steps:
# Common part (same for each build)
- uses: actions/checkout@v3
with:
submodules: true
- name: Set WGPU_NATIVE_VERSION
run: echo "WGPU_NATIVE_VERSION=${GITHUB_REF/refs\/tags\//}" >> $GITHUB_ENV
shell: bash
- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@stable
with:
targets: ${{ env.TARGET }}
- name: Setup caching
uses: Swatinem/rust-cache@v2
with:
key: build-${{ env.TARGET }}-${{ env.CACHE_SUFFIX }}
# Build
- name: Build
run: make package
# Upload (same for each build)
- name: Upload
uses: actions/upload-artifact@v3
with:
path: dist
name: dist

# Create a Github release and upload the binary libs that we just built.
# There should be a release and debug build for each platform (win32, win64, MacOS64, Linux64),
# plus a file containing the commit sha.
Expand Down
Loading