This repository has been archived by the owner on Dec 12, 2024. It is now read-only.
Build as dylib but w/ openssl #11
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build Rust Crate for macOS | |
on: | |
push: | |
branches: | |
- kendall/build-both-macs_staticlib | |
jobs: | |
build-intel: | |
runs-on: macos-13 | |
name: Build on Intel (x86) macOS | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Install Rust | |
run: rustup toolchain install stable | |
- name: Set Target | |
run: rustup target add x86_64-apple-darwin | |
- name: Build | |
run: cargo build --target x86_64-apple-darwin -p tbdex_uniffi --release | |
# - name: Convert to Dynamic Library | |
# run: | | |
# gcc -dynamiclib -o target/x86_64-apple-darwin/release/libtbdex_uniffi.dylib \ | |
# -Wl,-all_load target/x86_64-apple-darwin/release/libtbdex_uniffi.a | |
- name: Upload Artifacts | |
uses: actions/upload-artifact@v3 | |
with: | |
name: intel-build-artifacts | |
# target/x86_64-apple-darwin/release/libtbdex_uniffi.a | |
path: | | |
target/x86_64-apple-darwin/release/libtbdex_uniffi.dylib | |
build-apple-silicon: | |
runs-on: macos-latest | |
name: Build on Apple Silicon (ARM) macOS | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Install Rust | |
run: rustup toolchain install stable | |
- name: Build | |
run: cargo build -p tbdex_uniffi --release | |
- name: Upload .dylib | |
uses: actions/upload-artifact@v3 | |
with: | |
name: apple-silicon-build-dylib | |
path: target/release/libtbdex_uniffi.dylib |