-
Notifications
You must be signed in to change notification settings - Fork 269
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #3334 from matrix-org/valere/fix_crypto_binding_ap…
…ple_script crypto: Apple Crypto Bindings | Fix crypto xcframework script
- Loading branch information
Showing
4 changed files
with
123 additions
and
43 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -116,3 +116,42 @@ jobs: | |
with: | ||
use_rust_sdk: "." # use local checkout | ||
use_complement_crypto: "MATCHING_BRANCH" | ||
|
||
test-crypto-apple-framework-generation: | ||
name: Generate Crypto FFI Apple XCFramework | ||
runs-on: macos-12 | ||
if: github.event_name == 'push' || !github.event.pull_request.draft | ||
|
||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
|
||
# install protoc in case we end up rebuilding opentelemetry-proto | ||
- name: Install protoc | ||
uses: taiki-e/install-action@v2 | ||
with: | ||
tool: [email protected] | ||
|
||
- name: Install Rust | ||
uses: dtolnay/rust-toolchain@stable | ||
|
||
- name: Add rust targets | ||
run: | | ||
rustup target add aarch64-apple-ios | ||
# Cargo config can screw with caching and is only used for alias config | ||
# and extra lints, which we don't care about here | ||
- name: Delete cargo config | ||
run: rm .cargo/config.toml | ||
|
||
- name: Load cache | ||
uses: Swatinem/rust-cache@v2 | ||
with: | ||
save-if: ${{ github.ref == 'refs/heads/main' }} | ||
|
||
- name: Run the Build Framework script | ||
run: ./bindings/apple/build_crypto_xcframework.sh -i | ||
|
||
- name: Is XCFramework generated? | ||
if: ${{ hashFiles('generated/MatrixSDKCryptoFFI.zip') != '' }} | ||
run: echo "XCFramework exists" |
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
fn main() { | ||
uniffi::uniffi_bindgen_main() | ||
} |