X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;f=.github%2Fworkflows%2Fbuild.yml;h=9862a58ed2ffbfffaeb9def1ef372d038eef3fbe;hb=refs%2Fheads%2Fmain;hp=b9a7287eeb5e79d1d2ba98b8639eb681bfc42189;hpb=48e3445a78b643c837e7d489d90588eb877d0319;p=ldk-c-bindings diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index b9a7287..1f474f5 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -4,18 +4,27 @@ on: [push, pull_request] jobs: check_bindings: + strategy: + fail-fast: false + matrix: + # Ubuntu's version of rustc uses its own LLVM instead of being a real native package. + # This leaves us with an incompatible LLVM version when linking. Instead, use a real OS. + distro: [ "debian:bookworm", "fedora:39" ] runs-on: ubuntu-latest - # Ubuntu's version of rustc uses its own LLVM instead of being a real native package. - # This leaves us with an incompatible LLVM version when linking. Instead, use a real OS. - container: debian:bullseye + container: ${{ matrix.distro }} env: TOOLCHAIN: stable steps: - name: Install native Rust toolchain, Valgrind, and build utilitis + if: "matrix.distro == 'debian:bookworm'" run: | apt-get update apt-get -y dist-upgrade - apt-get -y install cargo libstd-rust-dev-wasm32 valgrind lld git g++ clang wget + apt-get -y install cargo libstd-rust-dev-wasm32 wasi-libc valgrind lld git g++ clang wget + - name: Install native Rust toolchain, Valgrind, and build utilitis + if: "matrix.distro == 'fedora:39'" + run: | + dnf -y install cargo rust-std-static-wasm32-wasi valgrind lld git g++ clang wget which diffutils - name: Checkout source code uses: actions/checkout@v2 with: @@ -25,7 +34,7 @@ jobs: run: | # Note that the version tags aren't checked into git touch src/version.rs - RUSTFLAGS="--cfg=c_bindings" cargo check --features std + RUSTFLAGS="--cfg=c_bindings" cargo check - name: Install cbindgen run: | git clone https://github.com/eqrion/cbindgen @@ -37,7 +46,7 @@ jobs: run: | git clone https://github.com/rust-bitcoin/rust-lightning cd rust-lightning - git checkout 0.0.116-bindings + git checkout 0.0.123-bindings - name: Fix Github Actions to not be broken run: git config --global --add safe.directory /__w/ldk-c-bindings/ldk-c-bindings - name: Pin proc-macro and quote to meet MSRV @@ -85,7 +94,7 @@ jobs: run: | # Note that the version tags aren't checked into git touch src/version.rs - RUSTFLAGS="--cfg=c_bindings" cargo check --features std + RUSTFLAGS="--cfg=c_bindings" cargo check - name: Install cbindgen run: | git clone https://github.com/eqrion/cbindgen @@ -97,7 +106,7 @@ jobs: run: | git clone https://github.com/rust-bitcoin/rust-lightning cd rust-lightning - git checkout 0.0.116-bindings + git checkout 0.0.123-bindings - name: Fix Github Actions to not be broken run: git config --global --add safe.directory /__w/ldk-c-bindings/ldk-c-bindings - name: Fetch MacOS SDK @@ -144,7 +153,7 @@ jobs: run: | git clone https://github.com/rust-bitcoin/rust-lightning cd rust-lightning - git checkout 0.0.116-bindings + git checkout 0.0.123-bindings - name: Rebuild bindings using Apple clang, and check the sample app builds + links run: ./genbindings.sh ./rust-lightning true - name: Rebuild bindings using upstream clang, and check the sample app builds + links