From da31de1b03d8a670ba41ae5cfd5938109b58b1e7 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Fri, 20 Nov 2026 06:41:03 +0000 Subject: [PATCH 1/2] chore: bump up all non-major dependencies --- .github/workflows/CI.yml | 4 ++-- packages/binding/Cargo.toml | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index 7761cfc..d44fb41 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -274,7 +274,7 @@ jobs: - name: Setup cmake uses: jwlawson/actions-setup-cmake@v2 with: - cmake-version: 'v4.5.0' + cmake-version: 'v4.5.1' - name: Setup node uses: actions/setup-node@v7 with: @@ -311,7 +311,7 @@ jobs: - uses: actions/checkout@v7 - name: Build id: build - uses: cross-platform-actions/action@v1.7.0 + uses: cross-platform-actions/action@v1.8.0 env: DEBUG: 'napi:*' RUSTUP_HOME: /home/runner/rustup diff --git a/packages/binding/Cargo.toml b/packages/binding/Cargo.toml index 0b8f6b4..ebf7904 100644 --- a/packages/binding/Cargo.toml +++ b/packages/binding/Cargo.toml @@ -55,7 +55,7 @@ fast_image_resize = { version = "6", features = ["image"] } image = { version = "0.25", default-features = false, features = ["jpeg", "ico", "png", "pnm", "tga", "tiff", "bmp", "webp", "hdr", "dds"] } jpeg-decoder = "0.3" jxl = { version = "0.8.0", optional = true } -libavif = { version = "0.14", default-features = false, features = ["codec-aom"] } +libavif = { version = "0.15", default-features = false, features = ["codec-aom"] } libc = "0.2" lodepng = "3" moxcms = { version = "0.9.0", optional = true, features = ["extended_range"] } From d8c78cba14353a6c07f3a1dea4fab74f0a61c538 Mon Sep 17 00:00:00 2001 From: Cursor Agent Date: Fri, 20 Nov 2026 09:45:53 +0000 Subject: [PATCH 2/2] fix: merge libavif static libs under clang-cl xwin libavif 1.4 merge_static_libs.cmake treats Clang as GNU ar and runs `${CMAKE_AR} -M` (MRI). cargo-xwin sets CMAKE_AR=llvm-lib, which rejects -M, so avif.lib is never produced on macOS cross builds of aarch64/i686-pc-windows-msvc. Put a llvm-lib wrapper first on PATH that forwards -M to llvm-ar and otherwise calls the real llvm-lib. Co-authored-by: LongYinan --- .github/workflows/CI.yml | 9 +++++++-- packages/binding/xwin-msvc-ar/llvm-lib | 26 ++++++++++++++++++++++++++ 2 files changed, 33 insertions(+), 2 deletions(-) create mode 100755 packages/binding/xwin-msvc-ar/llvm-lib diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index d44fb41..095b7a0 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -53,7 +53,11 @@ jobs: build: | export XWIN_CACHE_DIR="$(pwd)/.xwin" export XWIN_ARCH=aarch64 - export PATH="$(brew --prefix llvm)/bin:$PATH" + # Keep this dir ahead of Homebrew llvm so CMAKE_AR=llvm-lib (from cargo-xwin) + # hits packages/binding/xwin-msvc-ar/llvm-lib. libavif 1.4 then can MRI-merge + # avif.lib via llvm-ar -M; brew llvm stays on PATH so cargo-xwin does not + # prepend it in front of the wrapper. + export PATH="$(pwd)/packages/binding/xwin-msvc-ar:$(brew --prefix llvm)/bin:$PATH" clang --version CFLAGS="-mneon /FIintrin.h" yarn workspace @napi-rs/image build -x --features with_simd --target aarch64-pc-windows-msvc - host: macos-latest @@ -66,7 +70,8 @@ jobs: export CFLAGS="-mavx2 -mpclmul /FIintrin.h" export CXXFLAGS="-mavx2 -mpclmul" export CARGO_PROFILE_RELEASE_LTO="false" - export PATH="$(brew --prefix llvm)/bin:$PATH" + # Same llvm-lib MRI wrapper as aarch64-pc-windows-msvc (see comment there). + export PATH="$(pwd)/packages/binding/xwin-msvc-ar:$(brew --prefix llvm)/bin:$PATH" clang --version yarn workspace @napi-rs/image build -x --features with_simd --target i686-pc-windows-msvc target: i686-pc-windows-msvc diff --git a/packages/binding/xwin-msvc-ar/llvm-lib b/packages/binding/xwin-msvc-ar/llvm-lib new file mode 100755 index 0000000..b39f2fd --- /dev/null +++ b/packages/binding/xwin-msvc-ar/llvm-lib @@ -0,0 +1,26 @@ +#!/bin/sh +# cargo-xwin sets CMAKE_AR=llvm-lib for clang-cl. libavif 1.4's +# merge_static_libs.cmake matches CMAKE_C_COMPILER_ID Clang before MSVC, +# so it merges static libs with GNU ar MRI (`${CMAKE_AR} -M