mirror of
https://github.com/aljazceru/breez-sdk-liquid.git
synced 2026-01-24 08:24:20 +01:00
Update selected built packages to Uniffi 0.28 (#766)
This commit is contained in:
71
.github/workflows/build-bindings-android.yml
vendored
71
.github/workflows/build-bindings-android.yml
vendored
@@ -21,14 +21,35 @@ on:
|
||||
required: false
|
||||
type: boolean
|
||||
default: false
|
||||
uniffi-25:
|
||||
description: 'If true, builds additional bindings for Uniffi 0.25'
|
||||
required: false
|
||||
type: boolean
|
||||
default: false
|
||||
|
||||
jobs:
|
||||
setup:
|
||||
name: Setup
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- id: set-matrix
|
||||
run: |
|
||||
if [ ${{ inputs.uniffi-25 }} == true ]; then
|
||||
echo "::set-output name=matrix::['', '-uniffi-25']"
|
||||
else
|
||||
echo "::set-output name=matrix::['']"
|
||||
fi
|
||||
outputs:
|
||||
uniffi-matrix: ${{ steps.set-matrix.outputs.matrix }}
|
||||
|
||||
build:
|
||||
if: ${{ !inputs.use-dummy-binaries }}
|
||||
runs-on: ubuntu-latest
|
||||
name: build ${{ matrix.target }}
|
||||
name: build ${{ matrix.target }}${{ matrix.uniffi }}
|
||||
needs: setup
|
||||
strategy:
|
||||
matrix:
|
||||
uniffi: ${{ fromJson(needs.setup.outputs.uniffi-matrix) }}
|
||||
target: [
|
||||
aarch64-linux-android,
|
||||
x86_64-linux-android,
|
||||
@@ -55,12 +76,18 @@ jobs:
|
||||
|
||||
- uses: Swatinem/rust-cache@v2
|
||||
with:
|
||||
key: ${{ matrix.uniffi }}
|
||||
workspaces: lib
|
||||
|
||||
- name: Build bindings
|
||||
if: matrix.uniffi != '-uniffi-25'
|
||||
working-directory: lib/bindings
|
||||
run: |
|
||||
cargo ndk -t ${{ matrix.target }} build --release
|
||||
run: cargo ndk -t ${{ matrix.target }} build --release
|
||||
|
||||
- name: Build bindings Uniffi 0.25
|
||||
if: matrix.uniffi == '-uniffi-25'
|
||||
working-directory: lib/bindings
|
||||
run: cargo ndk -t ${{ matrix.target }} build --no-default-features --features=uniffi-25 --release
|
||||
|
||||
- name: Copy build output
|
||||
run: |
|
||||
@@ -73,36 +100,43 @@ jobs:
|
||||
- name: Archive release
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: bindings-${{ matrix.target }}
|
||||
name: bindings-${{ matrix.target }}${{ matrix.uniffi }}
|
||||
path: dist/*
|
||||
|
||||
jnilibs:
|
||||
needs: build
|
||||
needs:
|
||||
- setup
|
||||
- build
|
||||
runs-on: ubuntu-latest
|
||||
name: build jniLibs
|
||||
name: build jniLibs${{ matrix.uniffi }}
|
||||
strategy:
|
||||
matrix:
|
||||
uniffi: ${{ fromJson(needs.setup.outputs.uniffi-matrix) }}
|
||||
steps:
|
||||
- uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: bindings-aarch64-linux-android
|
||||
name: bindings-aarch64-linux-android${{ matrix.uniffi }}
|
||||
path: arm64-v8a
|
||||
|
||||
- uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: bindings-x86_64-linux-android
|
||||
name: bindings-x86_64-linux-android${{ matrix.uniffi }}
|
||||
path: x86_64
|
||||
|
||||
- name: Archive jniLibs
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: bindings-android-jniLibs
|
||||
name: bindings-android-jniLibs${{ matrix.uniffi }}
|
||||
path: ./*
|
||||
|
||||
build-dummies:
|
||||
if: ${{ inputs.use-dummy-binaries }}
|
||||
runs-on: ubuntu-latest
|
||||
name: build android dummies
|
||||
name: build dummies ${{ matrix.target }}${{ matrix.uniffi }}
|
||||
needs: setup
|
||||
strategy:
|
||||
matrix:
|
||||
uniffi: ${{ fromJson(needs.setup.outputs.uniffi-matrix) }}
|
||||
target: [
|
||||
aarch64-linux-android,
|
||||
x86_64-linux-android,
|
||||
@@ -116,26 +150,31 @@ jobs:
|
||||
- name: Upload dummy Android ${{ matrix.target }} artifact
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: bindings-${{ matrix.target }}
|
||||
name: bindings-${{ matrix.target }}${{ matrix.uniffi }}
|
||||
path: ./*
|
||||
|
||||
jnilibs-dummy:
|
||||
needs: build-dummies
|
||||
needs:
|
||||
- setup
|
||||
- build-dummies
|
||||
runs-on: ubuntu-latest
|
||||
name: build jniLibs dummy
|
||||
name: build jniLibs dummy ${{ matrix.target }}${{ matrix.uniffi }}
|
||||
strategy:
|
||||
matrix:
|
||||
uniffi: ${{ fromJson(needs.setup.outputs.uniffi-matrix) }}
|
||||
steps:
|
||||
- uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: bindings-aarch64-linux-android
|
||||
name: bindings-aarch64-linux-android${{ matrix.uniffi }}
|
||||
path: arm64-v8a
|
||||
|
||||
- uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: bindings-x86_64-linux-android
|
||||
name: bindings-x86_64-linux-android${{ matrix.uniffi }}
|
||||
path: x86_64
|
||||
|
||||
- name: Archive jniLibs
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: bindings-android-jniLibs
|
||||
name: bindings-android-jniLibs${{ matrix.uniffi }}
|
||||
path: ./*
|
||||
54
.github/workflows/build-bindings-darwin.yml
vendored
54
.github/workflows/build-bindings-darwin.yml
vendored
@@ -21,14 +21,35 @@ on:
|
||||
required: false
|
||||
type: boolean
|
||||
default: false
|
||||
uniffi-25:
|
||||
description: 'If true, builds additional bindings for Uniffi 0.25'
|
||||
required: false
|
||||
type: boolean
|
||||
default: false
|
||||
|
||||
jobs:
|
||||
setup:
|
||||
name: Setup
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- id: set-matrix
|
||||
run: |
|
||||
if [ ${{ inputs.uniffi-25 }} == true ]; then
|
||||
echo "::set-output name=matrix::['', '-uniffi-25']"
|
||||
else
|
||||
echo "::set-output name=matrix::['']"
|
||||
fi
|
||||
outputs:
|
||||
uniffi-matrix: ${{ steps.set-matrix.outputs.matrix }}
|
||||
|
||||
build:
|
||||
if: ${{ !inputs.use-dummy-binaries }}
|
||||
runs-on: macOS-latest
|
||||
name: build ${{ matrix.target }}
|
||||
name: build ${{ matrix.target }}${{ matrix.uniffi }}
|
||||
needs: setup
|
||||
strategy:
|
||||
matrix:
|
||||
uniffi: ${{ fromJson(needs.setup.outputs.uniffi-matrix) }}
|
||||
target: [
|
||||
aarch64-apple-darwin,
|
||||
x86_64-apple-darwin,
|
||||
@@ -55,33 +76,45 @@ jobs:
|
||||
|
||||
- uses: Swatinem/rust-cache@v2
|
||||
with:
|
||||
key: ${{ matrix.uniffi }}
|
||||
workspaces: lib
|
||||
|
||||
- name: Build bindings
|
||||
if: matrix.uniffi != '-uniffi-25'
|
||||
working-directory: lib/bindings
|
||||
run: cargo lipo --release --targets ${{ matrix.target }}
|
||||
|
||||
- name: Build bindings Uniffi 0.25
|
||||
if: matrix.uniffi == '-uniffi-25'
|
||||
working-directory: lib/bindings
|
||||
run: cargo lipo --no-default-features --features=uniffi-25 --release --targets ${{ matrix.target }}
|
||||
|
||||
- name: Archive release
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: bindings-${{ matrix.target }}
|
||||
name: bindings-${{ matrix.target }}${{ matrix.uniffi }}
|
||||
path: |
|
||||
lib/target/${{ matrix.target }}/release/libbreez_sdk_liquid_bindings.dylib
|
||||
lib/target/${{ matrix.target }}/release/libbreez_sdk_liquid_bindings.a
|
||||
|
||||
merge:
|
||||
runs-on: macOS-latest
|
||||
needs: build
|
||||
name: build darwin-universal
|
||||
needs:
|
||||
- setup
|
||||
- build
|
||||
name: build darwin-universal${{ matrix.uniffi }}
|
||||
strategy:
|
||||
matrix:
|
||||
uniffi: ${{ fromJson(needs.setup.outputs.uniffi-matrix) }}
|
||||
steps:
|
||||
- uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: bindings-aarch64-apple-darwin
|
||||
name: bindings-aarch64-apple-darwin${{ matrix.uniffi }}
|
||||
path: aarch64-apple-darwin
|
||||
|
||||
- uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: bindings-x86_64-apple-darwin
|
||||
name: bindings-x86_64-apple-darwin${{ matrix.uniffi }}
|
||||
path: x86_64-apple-darwin
|
||||
|
||||
- name: Build Darwin universal
|
||||
@@ -93,7 +126,7 @@ jobs:
|
||||
- name: Archive release
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: bindings-darwin-universal
|
||||
name: bindings-darwin-universal${{ matrix.uniffi }}
|
||||
path: |
|
||||
darwin-universal/libbreez_sdk_liquid_bindings.dylib
|
||||
darwin-universal/libbreez_sdk_liquid_bindings.a
|
||||
@@ -101,9 +134,12 @@ jobs:
|
||||
build-dummies:
|
||||
if: ${{ inputs.use-dummy-binaries }}
|
||||
runs-on: ubuntu-latest
|
||||
name: build darwin dummies
|
||||
name: build dummies ${{ matrix.target }}${{ matrix.uniffi }}
|
||||
needs:
|
||||
- setup
|
||||
strategy:
|
||||
matrix:
|
||||
uniffi: ${{ fromJson(needs.setup.outputs.uniffi-matrix) }}
|
||||
target: [
|
||||
aarch64-apple-darwin,
|
||||
x86_64-apple-darwin,
|
||||
@@ -118,5 +154,5 @@ jobs:
|
||||
- name: Upload dummy darwin ${{ matrix.target }} artifact
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: bindings-${{ matrix.target }}
|
||||
name: bindings-${{ matrix.target }}${{ matrix.uniffi }}
|
||||
path: ./*
|
||||
57
.github/workflows/build-bindings-ios.yml
vendored
57
.github/workflows/build-bindings-ios.yml
vendored
@@ -21,14 +21,35 @@ on:
|
||||
required: false
|
||||
type: boolean
|
||||
default: false
|
||||
uniffi-25:
|
||||
description: 'If true, builds additional bindings for Uniffi 0.25'
|
||||
required: false
|
||||
type: boolean
|
||||
default: false
|
||||
|
||||
jobs:
|
||||
setup:
|
||||
name: Setup
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- id: set-matrix
|
||||
run: |
|
||||
if [ ${{ inputs.uniffi-25 }} == true ]; then
|
||||
echo "::set-output name=matrix::['', '-uniffi-25']"
|
||||
else
|
||||
echo "::set-output name=matrix::['']"
|
||||
fi
|
||||
outputs:
|
||||
uniffi-matrix: ${{ steps.set-matrix.outputs.matrix }}
|
||||
|
||||
build:
|
||||
if: ${{ !inputs.use-dummy-binaries }}
|
||||
runs-on: macOS-latest
|
||||
name: build ${{ matrix.target }}
|
||||
name: build ${{ matrix.target }}${{ matrix.uniffi }}
|
||||
needs: setup
|
||||
strategy:
|
||||
matrix:
|
||||
uniffi: ${{ fromJson(needs.setup.outputs.uniffi-matrix) }}
|
||||
target: [
|
||||
aarch64-apple-ios,
|
||||
x86_64-apple-ios,
|
||||
@@ -58,6 +79,7 @@ jobs:
|
||||
|
||||
- uses: Swatinem/rust-cache@v2
|
||||
with:
|
||||
key: ${{ matrix.uniffi }}
|
||||
workspaces: lib
|
||||
|
||||
- name: Install xcode
|
||||
@@ -66,33 +88,44 @@ jobs:
|
||||
xcode-version: latest-stable
|
||||
|
||||
- name: Build bindings
|
||||
if: matrix.uniffi != '-uniffi-25'
|
||||
working-directory: lib/bindings
|
||||
run: cargo build --release --target ${{ matrix.target }}
|
||||
|
||||
- name: Build bindings Uniffi 0.25
|
||||
if: matrix.uniffi == '-uniffi-25'
|
||||
working-directory: lib/bindings
|
||||
run: cargo build --no-default-features --features=uniffi-25 --release --target ${{ matrix.target }}
|
||||
|
||||
- name: Archive release
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: bindings-${{ matrix.target }}
|
||||
name: bindings-${{ matrix.target }}${{ matrix.uniffi }}
|
||||
path: lib/target/${{ matrix.target }}/release/libbreez_sdk_liquid_bindings.a
|
||||
|
||||
merge:
|
||||
runs-on: macOS-latest
|
||||
needs: build
|
||||
name: build ios-universal
|
||||
needs:
|
||||
- setup
|
||||
- build
|
||||
name: build ios-universal${{ matrix.uniffi }}
|
||||
strategy:
|
||||
matrix:
|
||||
uniffi: ${{ fromJson(needs.setup.outputs.uniffi-matrix) }}
|
||||
steps:
|
||||
- uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: bindings-aarch64-apple-ios
|
||||
name: bindings-aarch64-apple-ios${{ matrix.uniffi }}
|
||||
path: aarch64-apple-ios
|
||||
|
||||
- uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: bindings-x86_64-apple-ios
|
||||
name: bindings-x86_64-apple-ios${{ matrix.uniffi }}
|
||||
path: x86_64-apple-ios
|
||||
|
||||
- uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: bindings-aarch64-apple-ios-sim
|
||||
name: bindings-aarch64-apple-ios-sim${{ matrix.uniffi }}
|
||||
path: aarch64-apple-ios-sim
|
||||
|
||||
- name: Build ios-universal
|
||||
@@ -108,21 +141,23 @@ jobs:
|
||||
- name: Archive ios-universal
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: bindings-ios-universal
|
||||
name: bindings-ios-universal${{ matrix.uniffi }}
|
||||
path: ios-universal/libbreez_sdk_liquid_bindings.a
|
||||
|
||||
- name: Archive ios-universal-sim
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: bindings-ios-universal-sim
|
||||
name: bindings-ios-universal-sim${{ matrix.uniffi }}
|
||||
path: ios-universal-sim/libbreez_sdk_liquid_bindings.a
|
||||
|
||||
build-dummies:
|
||||
if: ${{ inputs.use-dummy-binaries }}
|
||||
runs-on: ubuntu-latest
|
||||
name: build ios dummies
|
||||
name: build dummies ${{ matrix.target }}${{ matrix.uniffi }}
|
||||
needs: setup
|
||||
strategy:
|
||||
matrix:
|
||||
uniffi: ${{ fromJson(needs.setup.outputs.uniffi-matrix) }}
|
||||
target: [
|
||||
aarch64-apple-ios,
|
||||
x86_64-apple-ios,
|
||||
@@ -138,5 +173,5 @@ jobs:
|
||||
- name: Upload dummy ios ${{ matrix.target }} artifact
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: bindings-${{ matrix.target }}
|
||||
name: bindings-${{ matrix.target }}{{ matrix.uniffi }}
|
||||
path: ./*
|
||||
|
||||
41
.github/workflows/build-bindings-linux.yml
vendored
41
.github/workflows/build-bindings-linux.yml
vendored
@@ -21,14 +21,35 @@ on:
|
||||
required: false
|
||||
type: boolean
|
||||
default: false
|
||||
uniffi-25:
|
||||
description: 'If true, builds additional bindings for Uniffi 0.25'
|
||||
required: false
|
||||
type: boolean
|
||||
default: false
|
||||
|
||||
jobs:
|
||||
setup:
|
||||
name: Setup
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- id: set-matrix
|
||||
run: |
|
||||
if [ ${{ inputs.uniffi-25 }} == true ]; then
|
||||
echo "::set-output name=matrix::['', '-uniffi-25']"
|
||||
else
|
||||
echo "::set-output name=matrix::['']"
|
||||
fi
|
||||
outputs:
|
||||
uniffi-matrix: ${{ steps.set-matrix.outputs.matrix }}
|
||||
|
||||
build:
|
||||
if: ${{ !inputs.use-dummy-binaries }}
|
||||
runs-on: ubuntu-20.04
|
||||
name: build ${{ matrix.target }}
|
||||
name: build ${{ matrix.target }}${{ matrix.uniffi }}
|
||||
needs: setup
|
||||
strategy:
|
||||
matrix:
|
||||
uniffi: ${{ fromJson(needs.setup.outputs.uniffi-matrix) }}
|
||||
target: [
|
||||
aarch64-unknown-linux-gnu,
|
||||
x86_64-unknown-linux-gnu,
|
||||
@@ -66,27 +87,39 @@ jobs:
|
||||
|
||||
- uses: Swatinem/rust-cache@v2
|
||||
with:
|
||||
key: ${{ matrix.uniffi }}
|
||||
workspaces: lib
|
||||
|
||||
- name: Build bindings
|
||||
if: matrix.uniffi != '-uniffi-25'
|
||||
working-directory: lib/bindings
|
||||
env:
|
||||
CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER: /usr/bin/aarch64-linux-gnu-gcc
|
||||
CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_LINKER: /usr/bin/x86_64-linux-gnu-gcc
|
||||
run: cargo build --release --target ${{ matrix.target }}
|
||||
|
||||
- name: Build bindings Uniffi 0.25
|
||||
if: matrix.uniffi == '-uniffi-25'
|
||||
working-directory: lib/bindings
|
||||
env:
|
||||
CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER: /usr/bin/aarch64-linux-gnu-gcc
|
||||
CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_LINKER: /usr/bin/x86_64-linux-gnu-gcc
|
||||
run: cargo build --no-default-features --features=uniffi-25 --release --target ${{ matrix.target }}
|
||||
|
||||
- name: Archive release
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: bindings-${{ matrix.target }}
|
||||
name: bindings-${{ matrix.target }}${{ matrix.uniffi }}
|
||||
path: lib/target/${{ matrix.target }}/release/libbreez_sdk_liquid_bindings.so
|
||||
|
||||
build-dummies:
|
||||
if: ${{ inputs.use-dummy-binaries }}
|
||||
runs-on: ubuntu-latest
|
||||
name: build linux dummies
|
||||
name: build dummies ${{ matrix.target }}${{ matrix.uniffi }}
|
||||
needs: setup
|
||||
strategy:
|
||||
matrix:
|
||||
uniffi: ${{ fromJson(needs.setup.outputs.uniffi-matrix) }}
|
||||
target: [
|
||||
aarch64-unknown-linux-gnu,
|
||||
x86_64-unknown-linux-gnu,
|
||||
@@ -99,5 +132,5 @@ jobs:
|
||||
- name: Upload dummy linux ${{ matrix.target }} artifact
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: bindings-${{ matrix.target }}
|
||||
name: bindings-${{ matrix.target }}${{ matrix.uniffi }}
|
||||
path: ./*
|
||||
38
.github/workflows/build-bindings-windows.yml
vendored
38
.github/workflows/build-bindings-windows.yml
vendored
@@ -21,14 +21,35 @@ on:
|
||||
required: false
|
||||
type: boolean
|
||||
default: false
|
||||
uniffi-25:
|
||||
description: 'If true, builds additional bindings for Uniffi 0.25'
|
||||
required: false
|
||||
type: boolean
|
||||
default: false
|
||||
|
||||
jobs:
|
||||
setup:
|
||||
name: Setup
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- id: set-matrix
|
||||
run: |
|
||||
if [ ${{ inputs.uniffi-25 }} == true ]; then
|
||||
echo "::set-output name=matrix::['', '-uniffi-25']"
|
||||
else
|
||||
echo "::set-output name=matrix::['']"
|
||||
fi
|
||||
outputs:
|
||||
uniffi-matrix: ${{ steps.set-matrix.outputs.matrix }}
|
||||
|
||||
build:
|
||||
if: ${{ !inputs.use-dummy-binaries }}
|
||||
runs-on: windows-latest
|
||||
name: build ${{ matrix.target }}
|
||||
name: build ${{ matrix.target }}${{ matrix.uniffi }}
|
||||
needs: setup
|
||||
strategy:
|
||||
matrix:
|
||||
uniffi: ${{ fromJson(needs.setup.outputs.uniffi-matrix) }}
|
||||
target: [
|
||||
x86_64-pc-windows-msvc,
|
||||
]
|
||||
@@ -53,24 +74,33 @@ jobs:
|
||||
|
||||
- uses: Swatinem/rust-cache@v2
|
||||
with:
|
||||
key: ${{ matrix.uniffi }}
|
||||
workspaces: lib
|
||||
|
||||
- name: Build bindings
|
||||
if: matrix.uniffi != '-uniffi-25'
|
||||
working-directory: lib/bindings
|
||||
run: cargo build --release --target ${{ matrix.target }}
|
||||
|
||||
- name: Build bindings Uniffi 0.25
|
||||
if: matrix.uniffi == '-uniffi-25'
|
||||
working-directory: lib/bindings
|
||||
run: cargo build --no-default-features --features=uniffi-25 --release --target ${{ matrix.target }}
|
||||
|
||||
- name: Archive release
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: bindings-${{ matrix.target }}
|
||||
name: bindings-${{ matrix.target }}${{ matrix.uniffi }}
|
||||
path: lib/target/${{ matrix.target }}/release/breez_sdk_liquid_bindings.dll
|
||||
|
||||
build-dummies:
|
||||
if: ${{ inputs.use-dummy-binaries }}
|
||||
runs-on: ubuntu-latest
|
||||
name: build windows dummies
|
||||
name: build dummies ${{ matrix.target }}${{ matrix.uniffi }}
|
||||
needs: setup
|
||||
strategy:
|
||||
matrix:
|
||||
uniffi: ${{ fromJson(needs.setup.outputs.uniffi-matrix) }}
|
||||
target: [
|
||||
x86_64-pc-windows-msvc,
|
||||
]
|
||||
@@ -82,5 +112,5 @@ jobs:
|
||||
- name: Upload dummy windows ${{ matrix.target }} artifact
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: bindings-${{ matrix.target }}
|
||||
name: bindings-${{ matrix.target }}${{ matrix.uniffi }}
|
||||
path: ./*
|
||||
57
.github/workflows/build-language-bindings.yml
vendored
57
.github/workflows/build-language-bindings.yml
vendored
@@ -60,6 +60,7 @@ on:
|
||||
jobs:
|
||||
build-language-bindings:
|
||||
runs-on: ubuntu-latest
|
||||
if: ${{ inputs.kotlin || inputs.swift || inputs.python }}
|
||||
steps:
|
||||
- name: Checkout breez-sdk-liquid repo
|
||||
uses: actions/checkout@v4
|
||||
@@ -77,12 +78,16 @@ jobs:
|
||||
with:
|
||||
version: "27.2"
|
||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- uses: Swatinem/rust-cache@v2
|
||||
with:
|
||||
workspaces: lib
|
||||
|
||||
- name: Build Kotlin binding
|
||||
if: ${{ inputs.kotlin }}
|
||||
working-directory: lib/bindings
|
||||
run: |
|
||||
cargo run --features=uniffi/cli --bin uniffi-bindgen generate src/breez_sdk_liquid.udl --language kotlin -o ffi/kotlin
|
||||
cargo run --bin uniffi-bindgen generate src/breez_sdk_liquid.udl --language kotlin -o ffi/kotlin
|
||||
|
||||
- name: Archive Kotlin binding
|
||||
if: ${{ inputs.kotlin }}
|
||||
@@ -90,19 +95,12 @@ jobs:
|
||||
with:
|
||||
name: bindings-kotlin
|
||||
path: lib/bindings/ffi/kotlin/breez_sdk_liquid/breez_sdk_liquid.kt
|
||||
|
||||
- name: Archive Kotlin multiplatform binding
|
||||
if: ${{ inputs.kotlin }}
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: bindings-kotlin-multiplatform
|
||||
path: lib/bindings/ffi/kmp/*
|
||||
|
||||
- name: Build Swift binding
|
||||
if: ${{ inputs.swift }}
|
||||
working-directory: lib/bindings
|
||||
run: |
|
||||
cargo run --features=uniffi/cli --bin uniffi-bindgen generate src/breez_sdk_liquid.udl --no-format --language swift --out-dir langs/swift/Sources/BreezSDKLiquid
|
||||
cargo run --bin uniffi-bindgen generate src/breez_sdk_liquid.udl --no-format --language swift --out-dir langs/swift/Sources/BreezSDKLiquid
|
||||
mv langs/swift/Sources/BreezSDKLiquid/breez_sdk_liquid.swift langs/swift/Sources/BreezSDKLiquid/BreezSDKLiquid.swift
|
||||
|
||||
- name: Archive Swift binding
|
||||
@@ -116,7 +114,7 @@ jobs:
|
||||
if: ${{ inputs.python }}
|
||||
working-directory: lib/bindings
|
||||
run: |
|
||||
cargo run --features=uniffi/cli --bin uniffi-bindgen generate src/breez_sdk_liquid.udl --language python -o ffi/python
|
||||
cargo run --bin uniffi-bindgen generate src/breez_sdk_liquid.udl --language python -o ffi/python
|
||||
|
||||
- name: Archive Python binding
|
||||
if: ${{ inputs.python }}
|
||||
@@ -125,6 +123,45 @@ jobs:
|
||||
name: bindings-python
|
||||
path: lib/bindings/ffi/python/breez_sdk_liquid.py
|
||||
|
||||
build-language-bindings-uniffi-25:
|
||||
runs-on: ubuntu-latest
|
||||
if: ${{ inputs.kotlin || inputs.csharp || inputs.golang }}
|
||||
steps:
|
||||
- name: Checkout breez-sdk-liquid repo
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
repository: ${{ inputs.repository || github.repository }}
|
||||
ref: ${{ inputs.ref || github.sha }}
|
||||
|
||||
- name: Install rust
|
||||
run: |
|
||||
rustup set auto-self-update disable
|
||||
rustup toolchain install stable --profile minimal
|
||||
|
||||
- name: Install Protoc
|
||||
uses: arduino/setup-protoc@v3
|
||||
with:
|
||||
version: "27.2"
|
||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- uses: Swatinem/rust-cache@v2
|
||||
with:
|
||||
key: uniffi-25
|
||||
workspaces: lib
|
||||
|
||||
- name: Build Kotlin binding
|
||||
if: ${{ inputs.kotlin }}
|
||||
working-directory: lib/bindings
|
||||
run: |
|
||||
cargo run --no-default-features --features=uniffi-25 --bin uniffi-bindgen generate src/breez_sdk_liquid.udl --language kotlin -o ffi/kotlin
|
||||
|
||||
- name: Archive Kotlin multiplatform binding
|
||||
if: ${{ inputs.kotlin }}
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: bindings-kotlin-multiplatform
|
||||
path: lib/bindings/ffi/kmp/*
|
||||
|
||||
- name: Build C# binding
|
||||
if: ${{ inputs.csharp }}
|
||||
working-directory: lib/bindings
|
||||
|
||||
65
.github/workflows/main.yml
vendored
65
.github/workflows/main.yml
vendored
@@ -153,15 +153,55 @@ jobs:
|
||||
version: "27.2"
|
||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Setup python
|
||||
uses: actions/setup-python@v4
|
||||
with:
|
||||
python-version: '3.11'
|
||||
|
||||
- name: Build bindings
|
||||
working-directory: lib/bindings
|
||||
run: cargo build
|
||||
|
||||
- name: Run bindings tests
|
||||
run: |
|
||||
curl -o jna-5.12.1.jar https://repo1.maven.org/maven2/net/java/dev/jna/jna/5.12.1/jna-5.12.1.jar
|
||||
export CLASSPATH=$(pwd)/jna-5.12.1.jar;
|
||||
cd lib/bindings
|
||||
cargo test
|
||||
|
||||
build-bindings-uniffi-25:
|
||||
name: Test bindings Uniffi 0.25
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout repo
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- uses: Swatinem/rust-cache@v2
|
||||
with:
|
||||
key: -uniffi-25
|
||||
workspaces: |
|
||||
lib -> target
|
||||
cli -> target
|
||||
|
||||
- name: Install Protoc
|
||||
uses: arduino/setup-protoc@v3
|
||||
with:
|
||||
version: "27.2"
|
||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Setup dotnet
|
||||
if: ${{ !inputs.skip-tests }}
|
||||
uses: actions/setup-dotnet@v3
|
||||
with:
|
||||
dotnet-version: '7.0.x'
|
||||
|
||||
- name: Setup go
|
||||
uses: actions/setup-go@v4
|
||||
with:
|
||||
go-version: '1.19.9'
|
||||
|
||||
- name: Build bindings
|
||||
working-directory: lib/bindings
|
||||
run: cargo build
|
||||
run: cargo build --no-default-features --features uniffi-25
|
||||
|
||||
- name: Build C# bindings
|
||||
working-directory: lib/bindings
|
||||
@@ -178,22 +218,9 @@ jobs:
|
||||
cp ../target/debug/libbreez_sdk_liquid_bindings.so ffi/golang
|
||||
cp -r ffi/golang/breez_sdk_liquid tests/bindings/golang/
|
||||
|
||||
- name: Setup go
|
||||
uses: actions/setup-go@v4
|
||||
with:
|
||||
go-version: '1.19.9'
|
||||
|
||||
- name: Setup python
|
||||
uses: actions/setup-python@v4
|
||||
with:
|
||||
python-version: '3.11'
|
||||
|
||||
- name: Run bindings tests
|
||||
run: |
|
||||
curl -o jna-5.12.1.jar https://repo1.maven.org/maven2/net/java/dev/jna/jna/5.12.1/jna-5.12.1.jar
|
||||
export CLASSPATH=$(pwd)/jna-5.12.1.jar;
|
||||
cd lib/bindings
|
||||
cargo test
|
||||
working-directory: lib/bindings
|
||||
run: cargo test --no-default-features --features uniffi-25
|
||||
|
||||
build-wasm:
|
||||
name: Test WASM
|
||||
@@ -255,7 +282,7 @@ jobs:
|
||||
- name: Build Android bindings
|
||||
working-directory: lib/bindings
|
||||
run: |
|
||||
cargo run --features=uniffi/cli --bin uniffi-bindgen generate src/breez_sdk_liquid.udl --no-format --language kotlin -o langs/android/lib/src/main/kotlin
|
||||
cargo run --bin uniffi-bindgen generate src/breez_sdk_liquid.udl --no-format --language kotlin -o langs/android/lib/src/main/kotlin
|
||||
|
||||
- name: Run Android build
|
||||
working-directory: lib/bindings/langs/android
|
||||
@@ -265,7 +292,7 @@ jobs:
|
||||
- name: Build Swift bindings
|
||||
working-directory: lib/bindings
|
||||
run: |
|
||||
cargo run --features=uniffi/cli --bin uniffi-bindgen generate src/breez_sdk_liquid.udl --no-format --language swift -o langs/swift/Sources/BreezSDKLiquid
|
||||
cargo run --bin uniffi-bindgen generate src/breez_sdk_liquid.udl --no-format --language swift -o langs/swift/Sources/BreezSDKLiquid
|
||||
mv langs/swift/Sources/BreezSDKLiquid/breez_sdk_liquid.swift langs/swift/Sources/BreezSDKLiquid/BreezSDKLiquid.swift
|
||||
cp langs/swift/Sources/BreezSDKLiquid/breez_sdk_liquidFFI.h langs/swift/breez_sdk_liquidFFI.xcframework/ios-arm64/breez_sdk_liquidFFI.framework/Headers
|
||||
cp langs/swift/Sources/BreezSDKLiquid/breez_sdk_liquidFFI.h langs/swift/breez_sdk_liquidFFI.xcframework/ios-arm64_x86_64-simulator/breez_sdk_liquidFFI.framework/Headers
|
||||
|
||||
6
.github/workflows/publish-all-platforms.yml
vendored
6
.github/workflows/publish-all-platforms.yml
vendored
@@ -121,6 +121,7 @@ jobs:
|
||||
swift-package-version: ${{ needs.pre-setup.outputs.swift-package-version || '0.0.2' }}
|
||||
publish: ${{ needs.pre-setup.outputs.publish }}
|
||||
use-dummy-binaries: ${{ needs.pre-setup.outputs.use-dummy-binaries }}
|
||||
uniffi-25: ${{ !!needs.pre-setup.outputs.csharp-package-version || !!needs.pre-setup.outputs.golang-package-version || !!needs.pre-setup.outputs.kotlin-multiplatform-package-version }}
|
||||
steps:
|
||||
- run: echo "set setup output variables"
|
||||
|
||||
@@ -132,6 +133,7 @@ jobs:
|
||||
repository: ${{ needs.setup.outputs.repository }}
|
||||
ref: ${{ needs.setup.outputs.ref }}
|
||||
use-dummy-binaries: ${{ needs.setup.outputs.use-dummy-binaries == 'true' }}
|
||||
uniffi-25: ${{ needs.setup.outputs.uniffi-25 == 'true' }}
|
||||
|
||||
build-bindings-darwin:
|
||||
needs: setup
|
||||
@@ -141,6 +143,7 @@ jobs:
|
||||
repository: ${{ needs.setup.outputs.repository }}
|
||||
ref: ${{ needs.setup.outputs.ref }}
|
||||
use-dummy-binaries: ${{ needs.setup.outputs.use-dummy-binaries == 'true' }}
|
||||
uniffi-25: ${{ needs.setup.outputs.uniffi-25 == 'true' }}
|
||||
|
||||
build-bindings-linux:
|
||||
needs: setup
|
||||
@@ -150,6 +153,7 @@ jobs:
|
||||
repository: ${{ needs.setup.outputs.repository }}
|
||||
ref: ${{ needs.setup.outputs.ref }}
|
||||
use-dummy-binaries: ${{ needs.setup.outputs.use-dummy-binaries == 'true' }}
|
||||
uniffi-25: ${{ needs.setup.outputs.uniffi-25 == 'true' }}
|
||||
|
||||
build-bindings-android:
|
||||
needs: setup
|
||||
@@ -159,6 +163,7 @@ jobs:
|
||||
repository: ${{ needs.setup.outputs.repository }}
|
||||
ref: ${{ needs.setup.outputs.ref }}
|
||||
use-dummy-binaries: ${{ needs.setup.outputs.use-dummy-binaries == 'true' }}
|
||||
uniffi-25: ${{ needs.setup.outputs.uniffi-25 == 'true' }}
|
||||
|
||||
build-bindings-ios:
|
||||
needs: setup
|
||||
@@ -168,6 +173,7 @@ jobs:
|
||||
repository: ${{ needs.setup.outputs.repository }}
|
||||
ref: ${{ needs.setup.outputs.ref }}
|
||||
use-dummy-binaries: ${{ needs.setup.outputs.use-dummy-binaries == 'true' }}
|
||||
uniffi-25: ${{ needs.setup.outputs.uniffi-25 == 'true' }}
|
||||
|
||||
build-language-bindings:
|
||||
needs: setup
|
||||
|
||||
10
.github/workflows/publish-csharp.yml
vendored
10
.github/workflows/publish-csharp.yml
vendored
@@ -46,27 +46,27 @@ jobs:
|
||||
|
||||
- uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: bindings-aarch64-apple-darwin
|
||||
name: bindings-aarch64-apple-darwin-uniffi-25
|
||||
path: lib/bindings/langs/csharp/src/runtimes/osx-arm64/native
|
||||
|
||||
- uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: bindings-x86_64-apple-darwin
|
||||
name: bindings-x86_64-apple-darwin-uniffi-25
|
||||
path: lib/bindings/langs/csharp/src/runtimes/osx-x64/native
|
||||
|
||||
- uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: bindings-aarch64-unknown-linux-gnu
|
||||
name: bindings-aarch64-unknown-linux-gnu-uniffi-25
|
||||
path: lib/bindings/langs/csharp/src/runtimes/linux-arm64/native
|
||||
|
||||
- uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: bindings-x86_64-unknown-linux-gnu
|
||||
name: bindings-x86_64-unknown-linux-gnu-uniffi-25
|
||||
path: lib/bindings/langs/csharp/src/runtimes/linux-x64/native
|
||||
|
||||
- uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: bindings-x86_64-pc-windows-msvc
|
||||
name: bindings-x86_64-pc-windows-msvc-uniffi-25
|
||||
path: lib/bindings/langs/csharp/src/runtimes/win-x64/native
|
||||
|
||||
- name: Update package version
|
||||
|
||||
14
.github/workflows/publish-golang.yml
vendored
14
.github/workflows/publish-golang.yml
vendored
@@ -38,37 +38,37 @@ jobs:
|
||||
|
||||
- uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: bindings-aarch64-linux-android
|
||||
name: bindings-aarch64-linux-android-uniffi-25
|
||||
path: breez_sdk_liquid/lib/android-aarch64
|
||||
|
||||
- uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: bindings-x86_64-linux-android
|
||||
name: bindings-x86_64-linux-android-uniffi-25
|
||||
path: breez_sdk_liquid/lib/android-amd64
|
||||
|
||||
- uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: bindings-aarch64-apple-darwin
|
||||
name: bindings-aarch64-apple-darwin-uniffi-25
|
||||
path: breez_sdk_liquid/lib/darwin-aarch64
|
||||
|
||||
- uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: bindings-x86_64-apple-darwin
|
||||
name: bindings-x86_64-apple-darwin-uniffi-25
|
||||
path: breez_sdk_liquid/lib/darwin-amd64
|
||||
|
||||
- uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: bindings-aarch64-unknown-linux-gnu
|
||||
name: bindings-aarch64-unknown-linux-gnu-uniffi-25
|
||||
path: breez_sdk_liquid/lib/linux-aarch64
|
||||
|
||||
- uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: bindings-x86_64-unknown-linux-gnu
|
||||
name: bindings-x86_64-unknown-linux-gnu-uniffi-25
|
||||
path: breez_sdk_liquid/lib/linux-amd64
|
||||
|
||||
- uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: bindings-x86_64-pc-windows-msvc
|
||||
name: bindings-x86_64-pc-windows-msvc-uniffi-25
|
||||
path: breez_sdk_liquid/lib/windows-amd64
|
||||
|
||||
- name: Archive Go release
|
||||
|
||||
@@ -44,7 +44,7 @@ jobs:
|
||||
|
||||
- uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: bindings-android-jniLibs
|
||||
name: bindings-android-jniLibs-uniffi-25
|
||||
path: lib/bindings/langs/kotlin-multiplatform/breez-sdk-liquid-kmp/src/androidMain/jniLibs
|
||||
|
||||
- uses: actions/download-artifact@v4
|
||||
@@ -59,17 +59,17 @@ jobs:
|
||||
|
||||
- uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: bindings-aarch64-apple-ios
|
||||
name: bindings-aarch64-apple-ios-uniffi-25
|
||||
path: lib/bindings/langs/kotlin-multiplatform/breez-sdk-liquid-kmp/src/lib/ios-arm64
|
||||
|
||||
- uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: bindings-aarch64-apple-ios-sim
|
||||
name: bindings-aarch64-apple-ios-sim-uniffi-25
|
||||
path: lib/bindings/langs/kotlin-multiplatform/breez-sdk-liquid-kmp/src/lib/ios-simulator-arm64
|
||||
|
||||
- uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: bindings-x86_64-apple-ios
|
||||
name: bindings-x86_64-apple-ios-uniffi-25
|
||||
path: lib/bindings/langs/kotlin-multiplatform/breez-sdk-liquid-kmp/src/lib/ios-simulator-x64
|
||||
|
||||
- name: Build Kotlin Multiplatform project
|
||||
|
||||
Reference in New Issue
Block a user