sccache
$ sccache Official Low RiskMozilla's ccache-like compiler cache supporting Rust (rustc), C/C++, and CUDA with local disk or remote S3, GCS, Azure, and Redis backends. Emits structured JSON metrics via sccache --show-stats --stats-format json.
brew install sccache Local/distributed compiler wrapper configured via RUSTC_WRAPPER=sccache or CMake launchers.
Agent-Readiness Checklist
Static evaluation (not yet probed on this host). Run npm run data:probe locally to capture live verification.
FCRS-1.0 6-Dimension Breakdown
Supports --show-stats --stats-format json and zero interactive prompts, transparently wrapping rustc and C/C++ compilers.
- Native
--stats-format jsonstats output - Non-interactive daemon and CLI commands
Safe compilation caching; remote storage writes are scoped to configured cache buckets and read via standard env vars.
- No destructive source mutations; read-only stats inspection
Single Rust static binary distributed via Homebrew, Cargo, and GitHub releases across macOS, Linux, and Windows.
- Prebuilt binaries on all three major OSes
Unlocks shared Rust + C++ compilation caching across CI runners and developer machines.
- Supports
RUSTC_WRAPPER=sccacheplus S3/GCS/Redis/GHA backends
Originating from Mozilla (mozilla/sccache) and actively maintained under Apache-2.0.
- Active
mozilla/sccacherepository
Clear markdown docs covering backends, env vars, and CLI flags.
- Backend and CLI documentation in repository
docs/
Security, Auth & Guardrails
Local caching needs no auth; remote backends read SCCACHE_* environment variables (e.g., AWS/GCS/Redis credentials) or ~/.config/sccache/config.
Apache-2.0 open-source CLI; remote cloud storage costs depend on your S3/GCS/Redis provider.
# sccache Agent Rules - Always pass `--stats-format json` with `sccache --show-stats` for structured cache inspection. - Avoid printing `env` or config files when `SCCACHE_S3_KEY` or Redis credentials are configured.
Agent-Ready Command Recipes
Safe Read-Only Queries
sccache --show-stats --stats-format json
Prints cache hits, misses, and backend error counts in structured JSON.
sccache --version
Reports the installed sccache binary version without starting the background server.
Controlled Writes & Previews
sccache --zero-stats
Zeroes hit/miss counters on the running daemon before measuring a clean build.
Strengths for Agents
- +
sccache --show-stats --stats-format jsongives agents exact JSON hit/miss telemetry. - + Caches both
rustcand C/C++/CUDA compilations with optional shared remote backends.
Caveats & Pitfalls
- ! Starts a local background daemon process on first invocation unless managed with
--stop-server. - ! Misconfigured remote storage env vars can slow or fail builds unless
SCCACHE_IDLE_TIMEOUTand fallback settings are tuned.