Skip to content

fix(cross): bump libclang from 3.9 to 12 in cross images#6236

Open
Platane wants to merge 2 commits intomainfrom
fix/bump-libclang-cross-images
Open

fix(cross): bump libclang from 3.9 to 12 in cross images#6236
Platane wants to merge 2 commits intomainfrom
fix/bump-libclang-cross-images

Conversation

@Platane
Copy link
Copy Markdown
Collaborator

@Platane Platane commented Mar 30, 2026

Context

The nightly Linux builds (x86_64-unknown-linux-gnu and aarch64-unknown-linux-gnu) are failing with the following panic:

thread 'main' panicked at clang-sys-1.8.1/src/lib.rs:1859:
A `libclang` function was called that is not supported by the loaded `libclang` instance.
    called function = `clang_getTranslationUnitTargetInfo`
    loaded `libclang` instance = 3.9.x

Root cause

PR #5748 ("Add --retries parameter to CLI commands") updated OpenDAL as a side effect, which bumped zstd-sys from 2.0.13 to 2.0.15. Starting from 2.0.15, zstd-sys gained a bindgen dependency, which in turn requires clang-sys 1.8.1. That version calls clang_getTranslationUnitTargetInfo, a function only available in libclang >= 5.0. Our cross images ship libclang 3.9.x, which predates that API.

Why clang-3.9 was used

clang-3.9 was explicitly pinned in PR #2550 (Dec 2022) because the default clang version was breaking the rocksdb build. However, rocksdb has since been removed from the dependency tree entirely, so this constraint no longer applies.

Fix

Bump clang-3.9 / libclang-3.9-dev to clang-12 / libclang-12-dev in both GNU cross images. clang-12 is available in the Ubuntu 20.04 default apt repos (no extra LLVM apt source needed) and gives substantial headroom above the libclang >= 5.0 requirement.

Remark

I am not super confortable skipping 10 versions. Should I?

@Platane Platane marked this pull request as ready for review March 30, 2026 13:35
@trinity-1686a
Copy link
Copy Markdown
Contributor

when trying locally, i get these errors:

11.25 E: Unable to locate package clang-12
11.25 E: Unable to locate package libclang-12-dev

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants