Skip to content

Fix boot-patch image build: add llvm-dev and libclang-dev#18

Merged
sergii-aleo merged 2 commits into
mainfrom
claude/practical-ritchie-6csz8b
Jun 16, 2026
Merged

Fix boot-patch image build: add llvm-dev and libclang-dev#18
sergii-aleo merged 2 commits into
mainfrom
claude/practical-ritchie-6csz8b

Conversation

@alexk-aleo

Copy link
Copy Markdown
Member

Problem

The Build SnarkOS Boot-Patch Image action fails during cargo build --release --features history with:

error: failed to run custom build command for `clang-sys v1.8.1`
...
called `Result::unwrap()` on an `Err` value: "couldn't find any valid shared
libraries matching: ['libclang.so', 'libclang-*.so'], set the `LIBCLANG_PATH`
environment variable to a path where one of these files can be found"

The --features history build pulls in a crate (via clang-sys/bindgen, e.g. rocksdb bindings) that needs libclang at build time.

Cause

service/boot-patch/Dockerfile.boot installed only clang lld binutils in the builder stage, omitting llvm-dev and libclang-dev. Every other Dockerfile in the repo (root Dockerfile, snarkos-telemetry, snarkos-history-telemetry, snarkos-no-features) already includes these packages.

Fix

Add llvm-dev libclang-dev to the builder's apt install list, matching the other service Dockerfiles.


Generated by Claude Code

claude added 2 commits June 15, 2026 15:00
The telemetry and history feature builds pull in clang-sys via bindgen,
which requires libclang and llvm-config at build time. The builder stage
installed clang/lld/binutils but not the LLVM dev packages, causing:

  error: failed to run custom build command for `clang-sys v1.8.1`
  couldn't execute `llvm-config --prefix` ... No such file or directory

Add llvm-dev (provides llvm-config) and libclang-dev (provides libclang.so)
to all builder stages.

https://claude.ai/code/session_011UyaFFB58ZnFBdhVNWf23Z
The --features history build pulls in a crate (via clang-sys/bindgen)
that requires libclang at build time. Without llvm-dev/libclang-dev the
build fails with 'couldn't find any valid shared libraries matching
libclang.so'. This brings Dockerfile.boot in line with the other
service Dockerfiles.
@sergii-aleo sergii-aleo merged commit 0cd3505 into main Jun 16, 2026
2 checks passed
@sergii-aleo sergii-aleo deleted the claude/practical-ritchie-6csz8b branch June 16, 2026 13:28
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.

3 participants