diff --git a/.github/workflows/builds.yml b/.github/workflows/builds.yml index ad21a85a..b62ce001 100644 --- a/.github/workflows/builds.yml +++ b/.github/workflows/builds.yml @@ -32,12 +32,20 @@ jobs: fail-fast: false matrix: include: - - os: ubuntu-latest - name: linux-x64 + - os: ubuntu-22.04 + name: ubuntu-22.04-x64 + build_cmd: ./build.sh release-examples + build_dir: build-release + - os: ubuntu-22.04-arm + name: ubuntu-22.04-arm64 + build_cmd: ./build.sh release-examples + build_dir: build-release + - os: ubuntu-24.04 + name: ubuntu-24.04-x64 build_cmd: ./build.sh release-examples build_dir: build-release - os: ubuntu-24.04-arm - name: linux-arm64 + name: ubuntu-24.04-arm64 build_cmd: ./build.sh release-examples build_dir: build-release - os: macos-26-xlarge @@ -161,14 +169,19 @@ jobs: # step that runs AFTER the "Clean after build" cleanup wipes target/debug # and target/release, which is why the old cache was always ~empty. The # restore/save split lets us snapshot the populated target/ before cleanup. + # + # Key on matrix.os (runner image), not runner.os. runner.os is just + # "Linux" for both ubuntu-22.04 and ubuntu-24.04, and restored + # build-scripts / .so files from a newer glibc host fail with + # GLIBC_2.39 not found on the older image. - name: Restore cargo target id: cache-cargo-target uses: actions/cache/restore@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0 with: path: client-sdk-rust/target/ - key: ${{ runner.os }}-${{ matrix.name }}-cargo-target-${{ steps.rust_sha.outputs.sha }} + key: ${{ matrix.os }}-${{ matrix.name }}-cargo-target-${{ steps.rust_sha.outputs.sha }} restore-keys: | - ${{ runner.os }}-${{ matrix.name }}-cargo-target- + ${{ matrix.os }}-${{ matrix.name }}-cargo-target- # restore-keys can hydrate target/ from a prior submodule SHA. cxxbridge # artifacts in webrtc-sys are not compatible across those bumps. @@ -208,7 +221,7 @@ jobs: uses: actions/cache/save@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0 with: path: client-sdk-rust/target/ - key: ${{ runner.os }}-${{ matrix.name }}-cargo-target-${{ steps.rust_sha.outputs.sha }} + key: ${{ matrix.os }}-${{ matrix.name }}-cargo-target-${{ steps.rust_sha.outputs.sha }} - name: Save vcpkg binary cache if: runner.os == 'Windows' && steps.cache-vcpkg-binary.outputs.cache-hit != 'true' @@ -328,6 +341,28 @@ jobs: ${{ matrix.build_dir }}/bin/ retention-days: 7 + - name: Upload deprecated linux-x64 alias artifact + if: matrix.name == 'ubuntu-24.04-x64' + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 + with: + name: livekit-sdk-linux-x64 + path: | + ${{ matrix.build_dir }}/lib/ + ${{ matrix.build_dir }}/include/ + ${{ matrix.build_dir }}/bin/ + retention-days: 7 + + - name: Upload deprecated linux-arm64 alias artifact + if: matrix.name == 'ubuntu-24.04-arm64' + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 + with: + name: livekit-sdk-linux-arm64 + path: | + ${{ matrix.build_dir }}/lib/ + ${{ matrix.build_dir }}/include/ + ${{ matrix.build_dir }}/bin/ + retention-days: 7 + # ---------- Cleanup ---------- - name: Clean after build (best-effort) if: always() diff --git a/.github/workflows/make-release.yml b/.github/workflows/make-release.yml index afc79446..125f1834 100644 --- a/.github/workflows/make-release.yml +++ b/.github/workflows/make-release.yml @@ -24,11 +24,17 @@ jobs: fail-fast: false matrix: include: - - os: ubuntu-latest - name: linux-x64 + - os: ubuntu-22.04 + name: ubuntu-22.04-x64 + generator: Ninja + - os: ubuntu-22.04-arm + name: ubuntu-22.04-arm64 + generator: Ninja + - os: ubuntu-24.04 + name: ubuntu-24.04-x64 generator: Ninja - os: ubuntu-24.04-arm - name: linux-arm64 + name: ubuntu-24.04-arm64 generator: Ninja - os: macos-26-xlarge name: macos-arm64 @@ -157,14 +163,17 @@ jobs: restore-keys: | ${{ runner.os }}-${{ matrix.name }}-cargo-registry- + # Key on matrix.os (runner image), not runner.os — see builds.yml. + # Compiled target/ artifacts are glibc-bound and must not restore across + # Ubuntu major versions (e.g. 24.04 → 22.04 → GLIBC_2.39 not found). - name: Cache cargo target id: cache-cargo-target uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0 with: path: client-sdk-rust/target/ - key: ${{ runner.os }}-${{ matrix.name }}-cargo-target-${{ steps.rust_sha.outputs.sha }} + key: ${{ matrix.os }}-${{ matrix.name }}-cargo-target-${{ steps.rust_sha.outputs.sha }} restore-keys: | - ${{ runner.os }}-${{ matrix.name }}-cargo-target- + ${{ matrix.os }}-${{ matrix.name }}-cargo-target- # restore-keys can hydrate target/ from a prior submodule SHA. cxxbridge # artifacts in webrtc-sys are not compatible across those bumps. @@ -413,8 +422,8 @@ jobs: echo "Artifacts downloaded:" ls -la - # Create tar.gz for Linux and macOS - for platform in linux-x64 linux-arm64 macos-arm64 macos-x64; do + # Create tar.gz for Ubuntu and macOS + for platform in ubuntu-22.04-x64 ubuntu-22.04-arm64 ubuntu-24.04-x64 ubuntu-24.04-arm64 macos-arm64 macos-x64; do dirName="livekit-sdk-${platform}-${VERSION}" if [[ -d "${dirName}" ]]; then echo "Creating archive for ${platform}..." @@ -422,6 +431,12 @@ jobs: echo "Created: ${dirName}.tar.gz" fi done + + # Deprecated compatibility aliases for existing Linux release consumers. + cp "${{ github.workspace }}/release-assets/livekit-sdk-ubuntu-24.04-x64-${VERSION}.tar.gz" \ + "${{ github.workspace }}/release-assets/livekit-sdk-linux-x64-${VERSION}.tar.gz" + cp "${{ github.workspace }}/release-assets/livekit-sdk-ubuntu-24.04-arm64-${VERSION}.tar.gz" \ + "${{ github.workspace }}/release-assets/livekit-sdk-linux-arm64-${VERSION}.tar.gz" # Create zip for Windows dirName="livekit-sdk-windows-x64-${VERSION}" @@ -441,6 +456,17 @@ jobs: name: v${{ steps.version.outputs.version }} draft: true files: ${{ github.workspace }}/release-assets/* + body: | + ## Linux assets + + Prefer the explicit Ubuntu assets: + + - `livekit-sdk-ubuntu-22.04-x64` + - `livekit-sdk-ubuntu-22.04-arm64` + - `livekit-sdk-ubuntu-24.04-x64` + - `livekit-sdk-ubuntu-24.04-arm64` + + `livekit-sdk-linux-x64` and `livekit-sdk-linux-arm64` are deprecated aliases of the Ubuntu 24.04 builds and will be removed in a future release. generate_release_notes: false env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 94b590a0..c2556cee 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -139,11 +139,17 @@ jobs: fail-fast: false matrix: include: - - os: ubuntu-latest - name: linux-x64 + - os: ubuntu-22.04 + name: ubuntu-22.04-x64 + e2e-testing: true + - os: ubuntu-22.04-arm + name: ubuntu-22.04-arm64 + e2e-testing: true + - os: ubuntu-24.04 + name: ubuntu-24.04-x64 e2e-testing: true - os: ubuntu-24.04-arm - name: linux-arm64 + name: ubuntu-24.04-arm64 e2e-testing: true - os: macos-26-xlarge name: macos-arm64 @@ -261,14 +267,17 @@ jobs: restore-keys: | ${{ runner.os }}-${{ matrix.name }}-cargo-registry- + # Key on matrix.os (runner image), not runner.os — see builds.yml. + # Compiled target/ artifacts are glibc-bound and must not restore across + # Ubuntu major versions (e.g. 24.04 → 22.04 → GLIBC_2.39 not found). - name: Restore cargo target id: cache-cargo-target uses: actions/cache/restore@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0 with: path: client-sdk-rust/target/ - key: ${{ runner.os }}-${{ matrix.name }}-cargo-target-${{ steps.rust_sha.outputs.sha }} + key: ${{ matrix.os }}-${{ matrix.name }}-cargo-target-${{ steps.rust_sha.outputs.sha }} restore-keys: | - ${{ runner.os }}-${{ matrix.name }}-cargo-target- + ${{ matrix.os }}-${{ matrix.name }}-cargo-target- # restore-keys can hydrate target/ from a prior submodule SHA. cxxbridge # artifacts in webrtc-sys are not compatible across those bumps.