Skip to main content

clang-tool-chain-bins

CI

clang-tool-chain-bins is the package and CLI for querying and installing the archived LLVM, Clang, MSVC-adjacent, and related tool bundles managed in this repository.

It is designed for machine consumption first:

  • per-archive JSON indexes for every *.tar.zst
  • aggregate tool index for exact and glob lookup
  • JSON Lines query output for scripting and AI agents
  • install resolution with cache tracking and concurrency-safe locking

Install

pip install clang-tool-chain-bins

The CLI uses ~/.clang-tool-chain as its default cache and install root. Set CLANG_TOOL_CHAIN_DOWNLOAD_PATH or pass --home-dir to use a different location.

Python API

The published package now exposes an importable top-level API at clang_tool_chain_bins.

from clang_tool_chain_bins import ensure, install, is_installed, query, resolve_one

matches = query("clang", platform="win", arch="x86_64")
selected = resolve_one("clang", platform="win", arch="x86_64", version="21.1.5", component="clang")

if not is_installed("clang", platform="win", arch="x86_64", version="21.1.5", component="clang"):
    result = ensure("clang", platform="win", arch="x86_64", version="21.1.5", component="clang")[0]
    print(result.install_path)

Public API types:

  • ToolMatch
  • QueryResult
  • InstallResult

Public API functions:

  • query(*patterns, ...)
  • resolve(tool, ...)
  • resolve_one(tool, ...)
  • is_installed(tool, ...)
  • install(tool, ...)
  • ensure(tool, ...)
  • try_install(tool, ...)

Query CLI

clangd is distributed in the clang-extra component for Windows x86_64/ARM64, Linux x86_64/ARM64, and macOS x86_64/ARM64. This is the native language server; installing the VS Code extension alone does not provide this binary.

Windows ARM64 uses the SHA256-pinned official LLVM 21.1.5 woa64 installer. The native windows-11-arm lane rejects x86_64 PE binaries and validates all four compiled tools, isolated runtime loading, and the C++20/WASM clangd fixture. The optional Forge fallback uses the pinned LLVM source revision and enables only Forge's native windows_arm64 target.

clang-tool-chain-bins query clangd --component clang-extra --platform linux --arch x86_64
clang-tool-chain-bins install clangd --component clang-extra --platform linux --arch x86_64

The archive includes the Clang resource headers and runtime libraries needed by clangd, so the installation does not depend on a system LLVM tree.

query is the discovery command. Default JSONL output returns one matched entry per line.

  • Patterns without glob characters are exact matches.
  • Patterns containing *, ?, or [] use glob matching.
  • Matching is case-insensitive against both normalized tool_name and the archived file_name.
  • Filters narrow matches by platform, arch, version, and component.
  • Output is JSON Lines by default, one matched entry per line. Use --pretty for a human-readable table plus per-match source URL and install path details.

Exact lookup:

clang-tool-chain-bins query clang

Glob lookup:

clang-tool-chain-bins query "llvm-*"

Multiple patterns in one call:

clang-tool-chain-bins query clang clang++ --platform linux --arch x86_64

Pretty output:

clang-tool-chain-bins query clang++ --pretty

Typical JSONL shape:

{"query":"clang","tool_name":"clang","file_name":"clang","component":"clang","version":"21.1.5","platform":"linux","arch":"x86_64","archive_url":"https://...","source_urls":["https://..."],"archive_sha256":"...","local_cache_path":"...","install_path":"...","installed":false}

Each JSON line for a match includes the aggregate index metadata plus derived local state such as:

  • query
  • tool_name and file_name
  • component, version, platform, arch
  • archive_filename, archive_path, archive_sha256, archive_url
  • source_urls
  • path_in_archive, tool_type, tool_sha256, size
  • parts, download_kind, probe_urls
  • local_cache_path
  • install_path
  • installed

installed is a local state check against the selected home directory. It becomes true only when the matching done.txt marker and the requested tool binary both exist; a stale marker without the binary is rejected.

install_path is always the resolved destination for that archive candidate, even when installed is false. source_urls resolves to the concrete download URL list for that match; for normal archives it is a one-item list, and for multipart archives it contains the part URLs.

If a query has no matches, the JSONL stream emits a marker line like {"query":"missing-tool","matched":false}.

Index selection for query works like this:

  • --index PATH uses that local aggregate index file.
  • CLANG_TOOL_CHAIN_BINS_INDEX_URL overrides the remote index URL when --index is not set.
  • Otherwise the CLI first tries to discover a repo-relative raw GitHub tool-index.json.
  • If that remote lookup fails, it falls back to the packaged local index at tools/data/tool-index.json.

Install CLI

install resolves an exact tool or filename to one or more archive candidates, then downloads and extracts the selected archive.

  • install does not support globs.
  • Matching is exact against tool_name or file_name.
  • If more than one archive matches, the command exits with an error unless you add filters or pass --all.
  • Output is always JSON, one object per installed candidate.
  • --dry-run prints the install plan without downloading or extracting anything.

Install a single archive:

clang-tool-chain-bins install clang --platform linux --arch x86_64

Preview the plan only:

clang-tool-chain-bins install clang --platform linux --arch x86_64 --dry-run

If multiple archives match, narrow the selection with:

  • --platform
  • --arch
  • --version
  • --component

Use --all to install every matching archive.

Typical install result:

{"operation":"install","status":"installed","tool_name":"clang","component":"clang","version":"21.1.5","platform":"linux","arch":"x86_64","install_path":"~/.clang-tool-chain/clang/linux/x86_64","archive_sha256":"...","archive_url":"https://...","dry_run":false}

Possible status values include:

  • installed
  • already_installed
  • dry_run

The installer is concurrency-safe for each component/platform/arch target:

  • archives are cached under HOME/archives/
  • installs land under HOME/<component>/<platform>/<arch>/
  • a per-target lock file prevents concurrent writers
  • done.txt records the installed archive hash and source URL

Download behavior:

  • file:// archive URLs are copied directly
  • HTTP(S) archive URLs are downloaded automatically

install uses the packaged local aggregate index unless --index is provided. Unlike query, it does not try to fetch a remote index automatically.

Index Generation

Generate or refresh sidecar indexes and the aggregate tool index:

clang-tool-chain-bins-index

Publishing

Build and validate release artifacts locally:

clang-tool-chain-bins-publish --skip-upload

Publish to TestPyPI:

clang-tool-chain-bins-publish --testpypi

Publish to PyPI:

clang-tool-chain-bins-publish

By default the publish script reads the token from PYPI_TOKEN.

Repository Scope

This repository still contains maintainer-oriented archive build scripts under tools/. The published package hardens the artifact boundary so wheel and sdist contents are limited to intentional code, metadata, tests, and generated tool index data rather than the raw archive payloads.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

clang_tool_chain_bins-0.4.6.tar.gz (113.8 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

clang_tool_chain_bins-0.4.6-cp310-abi3-win_arm64.whl (579.3 kB view details)

Uploaded CPython 3.10+Windows ARM64

clang_tool_chain_bins-0.4.6-cp310-abi3-win_amd64.whl (596.9 kB view details)

Uploaded CPython 3.10+Windows x86-64

clang_tool_chain_bins-0.4.6-cp310-abi3-musllinux_1_2_x86_64.whl (1.0 MB view details)

Uploaded CPython 3.10+musllinux: musl 1.2+ x86-64

clang_tool_chain_bins-0.4.6-cp310-abi3-musllinux_1_2_aarch64.whl (1.2 MB view details)

Uploaded CPython 3.10+musllinux: musl 1.2+ ARM64

clang_tool_chain_bins-0.4.6-cp310-abi3-manylinux_2_34_x86_64.whl (950.1 kB view details)

Uploaded CPython 3.10+manylinux: glibc 2.34+ x86-64

clang_tool_chain_bins-0.4.6-cp310-abi3-manylinux_2_34_aarch64.whl (903.9 kB view details)

Uploaded CPython 3.10+manylinux: glibc 2.34+ ARM64

clang_tool_chain_bins-0.4.6-cp310-abi3-macosx_11_0_arm64.whl (733.7 kB view details)

Uploaded CPython 3.10+macOS 11.0+ ARM64

clang_tool_chain_bins-0.4.6-cp310-abi3-macosx_10_12_x86_64.whl (816.2 kB view details)

Uploaded CPython 3.10+macOS 10.12+ x86-64

File details

Details for the file clang_tool_chain_bins-0.4.6.tar.gz.

File metadata

  • Download URL: clang_tool_chain_bins-0.4.6.tar.gz
  • Upload date:
  • Size: 113.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for clang_tool_chain_bins-0.4.6.tar.gz
Algorithm Hash digest
SHA256 0a88cc45f9db5baac22f26a7e61fabe5f6fdb5f99bd16334f46c22b69574f03a
MD5 9f2150c11d20c665430f7ca747ed6241
BLAKE2b-256 0b8a9d91adcd14f50cf1e5964fb1c12d19b29d0474d98b007e2eccbc132870e9

See more details on using hashes here.

Provenance

The following attestation bundles were made for clang_tool_chain_bins-0.4.6.tar.gz:

Publisher: auto-release.yml on zackees/clang-tool-chain-bins

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file clang_tool_chain_bins-0.4.6-cp310-abi3-win_arm64.whl.

File metadata

File hashes

Hashes for clang_tool_chain_bins-0.4.6-cp310-abi3-win_arm64.whl
Algorithm Hash digest
SHA256 51d2838bce2fda1fe13010ebcac0c96c0f675b8a41d19467ec02a58981cdbb08
MD5 31c161de936a465076413ef829fe8fd7
BLAKE2b-256 79d5c2644da9c1c0256cd235a54f91232d4d694fca9963363c2f872bc67e22d9

See more details on using hashes here.

Provenance

The following attestation bundles were made for clang_tool_chain_bins-0.4.6-cp310-abi3-win_arm64.whl:

Publisher: auto-release.yml on zackees/clang-tool-chain-bins

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file clang_tool_chain_bins-0.4.6-cp310-abi3-win_amd64.whl.

File metadata

File hashes

Hashes for clang_tool_chain_bins-0.4.6-cp310-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 20b930bcc958906264c56b36f2cfe3d7a11642b9f48130ce23ba184374e0850e
MD5 527ccc2fe03141b2722f1369f299ad61
BLAKE2b-256 3c009105c9608aee02b28bbd431f3bcdad24bd2d754ce9b8ac6bfa885a0847ac

See more details on using hashes here.

Provenance

The following attestation bundles were made for clang_tool_chain_bins-0.4.6-cp310-abi3-win_amd64.whl:

Publisher: auto-release.yml on zackees/clang-tool-chain-bins

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file clang_tool_chain_bins-0.4.6-cp310-abi3-musllinux_1_2_x86_64.whl.

File metadata

File hashes

Hashes for clang_tool_chain_bins-0.4.6-cp310-abi3-musllinux_1_2_x86_64.whl
Algorithm Hash digest
SHA256 bd6d7a4bd5f9c71ac31c549bd2de45c538d16800ce6b8f40ca835c6a1225e077
MD5 38a244319b614a2c0e3bde515d3581c6
BLAKE2b-256 9f1bd4e34ce462e3768a5e4134b91db00dc04b746b458b5a217f5b9fd4df6728

See more details on using hashes here.

Provenance

The following attestation bundles were made for clang_tool_chain_bins-0.4.6-cp310-abi3-musllinux_1_2_x86_64.whl:

Publisher: auto-release.yml on zackees/clang-tool-chain-bins

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file clang_tool_chain_bins-0.4.6-cp310-abi3-musllinux_1_2_aarch64.whl.

File metadata

File hashes

Hashes for clang_tool_chain_bins-0.4.6-cp310-abi3-musllinux_1_2_aarch64.whl
Algorithm Hash digest
SHA256 779945f0268bc712ca31a341855c5a30d3301649a674b42ac91eda392ec65bae
MD5 2321da4c8ac0ad9f945b88bd898f4770
BLAKE2b-256 51c2865ad4775697720a8c2a6f52c403f675e1c9a79479b024ddb246770de42e

See more details on using hashes here.

Provenance

The following attestation bundles were made for clang_tool_chain_bins-0.4.6-cp310-abi3-musllinux_1_2_aarch64.whl:

Publisher: auto-release.yml on zackees/clang-tool-chain-bins

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file clang_tool_chain_bins-0.4.6-cp310-abi3-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for clang_tool_chain_bins-0.4.6-cp310-abi3-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 5578635c91366b5181ec47ebbe6ab0caec4d404f94ac80e74838d2208da3ca7a
MD5 268df373408e53f972b0a3d594e2b9d4
BLAKE2b-256 d88297f14a972c8a68490e477047b2ad438f55aef72f99d2e4d3516a3eabd860

See more details on using hashes here.

Provenance

The following attestation bundles were made for clang_tool_chain_bins-0.4.6-cp310-abi3-manylinux_2_34_x86_64.whl:

Publisher: auto-release.yml on zackees/clang-tool-chain-bins

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file clang_tool_chain_bins-0.4.6-cp310-abi3-manylinux_2_34_aarch64.whl.

File metadata

File hashes

Hashes for clang_tool_chain_bins-0.4.6-cp310-abi3-manylinux_2_34_aarch64.whl
Algorithm Hash digest
SHA256 aa29472cd71c6a12612d97983c0e048d56056c7b135d9bcbf6a3f21c820b0fb7
MD5 50b3a112ed989af16ab50f3f0859ed76
BLAKE2b-256 fdce6e28463b2a480eed7e51faa5c147da96ffa23321bf19be689dfd819f6fb8

See more details on using hashes here.

Provenance

The following attestation bundles were made for clang_tool_chain_bins-0.4.6-cp310-abi3-manylinux_2_34_aarch64.whl:

Publisher: auto-release.yml on zackees/clang-tool-chain-bins

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file clang_tool_chain_bins-0.4.6-cp310-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for clang_tool_chain_bins-0.4.6-cp310-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 0ac4730d3a6e67fd07937adea5aaec6a8a14824f8d146e2c267d558a710bd47c
MD5 9dae450ee8fe86d1af537974cd13c4fc
BLAKE2b-256 3037bd45ec53a34781c3bcc402b63e6e4fc958a044d3cf5c1159c18580986cd3

See more details on using hashes here.

Provenance

The following attestation bundles were made for clang_tool_chain_bins-0.4.6-cp310-abi3-macosx_11_0_arm64.whl:

Publisher: auto-release.yml on zackees/clang-tool-chain-bins

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file clang_tool_chain_bins-0.4.6-cp310-abi3-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for clang_tool_chain_bins-0.4.6-cp310-abi3-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 2f71c385df1bceb7b8a3f9280cc5b09f3674b8718ae935ee7d8975b7e56b7c73
MD5 3d1fa33e53f9a6c57cbe7b8c90db3edc
BLAKE2b-256 21ca9e0207997447a7ca38d3a26f5fa09aa0401724af71d3d40d31cb56cfc71c

See more details on using hashes here.

Provenance

The following attestation bundles were made for clang_tool_chain_bins-0.4.6-cp310-abi3-macosx_10_12_x86_64.whl:

Publisher: auto-release.yml on zackees/clang-tool-chain-bins

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page