# Install cling with Homebrew, Nix

C++ interpreter. Version 1.3 via Homebrew; verified from local package data.

## Install

```sh
sudo av install brew:cling
```

Additional install commands:

### macOS

- Homebrew (100%):

```sh
brew install cling
```

  Evidence: local Homebrew formula metadata

### Linux

- Nix (92%):

```sh
nix profile install nixpkgs#cling
```

  Evidence: nixpkgs package indexes: pkgs/by-name/cl/cling/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1

## Package facts

- **Package key:** brew:cling
- **Package manager:** Homebrew
- **Package manager page:** <https://formulae.brew.sh/formula/cling>
- **Version:** 1.3
- **Source summary:** C++ interpreter
- **Homepage:** <https://root.cern/cling/>
- **Repository:** <https://github.com/root-project/cling>
- **Upstream docs:** <https://root.cern/cling>
- **License:** (LGPL-2.1-only OR NCSA) AND (Apache-2.0 WITH LLVM-exception)
- **Source archive:** <https://github.com/root-project/cling/archive/refs/tags/v1.3.tar.gz>
- **Generated:** 2026-07-08T07:18:31+00:00

## Executables

- cling (cli)
- cling (alias)

## Dependencies

- zstd

## Build dependencies

- cmake

## Uses from macOS

- libedit
- libxml2
- ncurses

## Install behavior

- Post-install hook: not defined
- Bottle: available on arm64_linux, arm64_sequoia, arm64_sonoma, arm64_tahoe, sonoma, x86_64_linux

## Freshness

- Page generated: 2026-07-08
- Package-manager version: 1.3
- Local data: ok
- Upstream repository: https://github.com/root-project/cling
- Upstream latest detected: v1.3 (current)
- info: No package-manager update timestamp was available.
## Project history and usage

Cling is an interactive C++ interpreter built on Clang and LLVM. The official README describes it as a REPL that reuses Clang diagnostics, supports interactive C++ development, and can be used from the command line or as a Jupyter kernel.

### Project history

Cling emerged from the ROOT high-energy physics ecosystem as the new interpreter for ROOT 6. The official README includes a peer-reviewed CHEP 2012 citation, 'Cling - The New Interactive Interpreter for ROOT 6', and the ROOT documentation presents Cling as ROOT's C++ interpreter.

### Adoption history

Cling's adoption is strongest through ROOT rather than as an isolated package. In package-manager culture, standalone formulae such as Homebrew and Nix expose it to users who want an interactive C++ REPL without installing or centering an entire ROOT workflow.

### How it is used

The README documents building Cling with the matching root-project LLVM branch, running cling with inline C++ snippets or an interactive prompt, using .help, and enabling a Jupyter kernel. The ROOT manual covers prompt commands and interactive C++ usage inside ROOT.

### Why package nerds care

Cling is package-nerd significant because it turns a compiled language and a large compiler infrastructure into a packaged interactive runtime. It also illustrates the maintenance burden of packaging tools that track LLVM and Clang closely, which is why distribution recipes matter for users who just want a working C++ REPL.

### Timeline

- 2012: CHEP publication describes Cling as the new interactive interpreter for ROOT 6.
- 2010s: Cling release tags progress from v0.4 through v1.x in the official repository tag list.
- 2020s: Official README documents standalone builds, LLVM/Clang integration, Jupyter support, and ROOT manual integration.
- 2026: Batch input lists Homebrew and Nix distribution.

### Related projects

- Cling is directly related to ROOT, Clang, LLVM, and Jupyter. It belongs near other interactive language runtimes and C++ exploration tools, but its official lineage is ROOT and LLVM/Clang rather than a general scripting-language implementation.

### Sources

- <https://github.com/root-project/cling#readme>
- <https://root.cern/cling>
- <https://root.cern/manual/cling>
- <https://github.com/root-project/cling/blob/master/docs/ReleaseNotes.md>


## Security Notes

generalized runtime or code generation signal.

- **Geiger risk:** yellow / medium
- generalized runtime or code generation signal

## Source Database Details

- **Source Database:** Homebrew formula API
- **Tap:** homebrew/core
- **Full Name:** cling
- **Version Scheme:** 0
- **Revision:** 0
- **Bottle Stable Root URL:** <https://ghcr.io/v2/homebrew/core>
- **Deprecated:** no
- **Disabled:** no
- **Keg Only:** no
- **URL Keys:** stable

## Other Package-Manager Records

- Nix - cling: normalized package name match | nixpkgs package indexes: pkgs/by-name/cl/cling/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1


## Related links

- [Secret-risk packages](https://www.automicvault.com/pkg/secret-risk-packages/) - Has protected-tool coverage, approval-gate, or non-low Geiger security signals.
- [Terminal utility packages](https://www.automicvault.com/pkg/terminal-utilities/) - Matched terminal and command-line workflow metadata.
- [Language runtime packages](https://www.automicvault.com/pkg/language-runtime-packages/) - Matched language runtime, compiler, or interpreter metadata.
- [Networking and protocol packages](https://www.automicvault.com/pkg/networking-protocol-tools/) - Matched network, protocol, or remote-service metadata.
- [zstd](https://www.automicvault.com/pkg/brew/zstd/) - Runtime dependency declared by Homebrew.
- [cmake](https://www.automicvault.com/pkg/brew/cmake/) - Build dependency declared by Homebrew.
- [cpi](https://www.automicvault.com/pkg/brew/cpi/) - Shares av.db curated category or tags: cli, cpp, interpreter, language-runtime, repl.
- [brainfuck](https://www.automicvault.com/pkg/brew/brainfuck/) - Shares av.db curated category or tags: cli, interpreter, language-runtime.
- [goawk](https://www.automicvault.com/pkg/brew/goawk/) - Shares av.db curated category or tags: cli, interpreter, language-runtime.
- [mawk](https://www.automicvault.com/pkg/brew/mawk/) - Shares av.db curated category or tags: cli, interpreter, language-runtime.
- [picoc](https://www.automicvault.com/pkg/brew/picoc/) - Shares av.db curated category or tags: cli, interpreter, language-runtime.
- [rustpython](https://www.automicvault.com/pkg/brew/rustpython/) - Shares av.db curated category or tags: cli, interpreter, language-runtime.
- [wasm3](https://www.automicvault.com/pkg/brew/wasm3/) - Shares av.db curated category or tags: cli, interpreter, language-runtime.
- [yaegi](https://www.automicvault.com/pkg/brew/yaegi/) - Shares av.db curated category or tags: cli, interpreter, language-runtime, repl.
- [julia](https://www.automicvault.com/pkg/brew/julia/) - Local package facts share a topical domain. Shared terms: cli, language, language-runtime, repl, runtime.
- [python-freethreading](https://www.automicvault.com/pkg/brew/python-freethreading/) - Local package facts share a topical domain. Shared terms: cli, interpreter, language, language-runtime, runtime.

## Combined YAML source

View the package source record on GitHub. [combined/cling.yml](https://github.com/automic-vault/db/blob/main/combined/cling.yml)


## Sources

- Nucleus package database
- Geiger risk classifier
- package-page enrichment
- curated package history
- package version freshness
- av.db category and tag curation
- package relationship graph
- external package-manager database matches
- cross-ecosystem install command graph
