# ldc を Homebrew, apk, chocolatey, apt, dnf, MacPorts, Nix, pacman, zypper, scoop でインストール

ldc のインストール経路、実行ファイル、メタデータ、AI エージェント向けセキュリティノートを確認します。

## インストール

```sh
sudo av install brew:ldc
```

追加のインストールコマンド:

### macOS

- Homebrew (100%):

```sh
brew install ldc
```

  証拠: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install ldc
```

  証拠: MacPorts ports tree: lang/ldc/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1

### Linux

- apk (92%):

```sh
sudo apk add ldc
```

  証拠: Alpine Linux edge package indexes: ldc from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz

- Debian apt (92%):

```sh
sudo apt install ldc
```

  証拠: Debian stable package indexes: ldc from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz

- dnf (92%):

```sh
sudo dnf install ldc
```

  証拠: Fedora Rawhide package metadata: ldc from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/07190dc5ae9f35ae73866675fed6d95fe6e8d9fe22c9d7cdf85862cb2ed24a4c-primary.xml.zst

- Nix (92%):

```sh
nix profile install nixpkgs#ldc
```

  証拠: nixpkgs package indexes: pkgs/by-name/ld/ldc/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1

- pacman (92%):

```sh
sudo pacman -S ldc
```

  証拠: Arch Linux sync databases: ldc from https://geo.mirror.pkgbuild.com/extra/os/x86_64/extra.db.tar.gz

- zypper (92%):

```sh
sudo zypper install ldc
```

  証拠: openSUSE Tumbleweed package metadata: ldc from https://download.opensuse.org/tumbleweed/repo/oss/repodata/50b07339cb64c8ed4091bdbabddadc1ff5737b090e478818a195b40d8a3292861a879139b4a3987c31109699fde9fbf4a716367ddf4eef77da75f96e3193d6ed-primary.xml.zst

### Windows

- Chocolatey (92%):

```sh
choco install ldc
```

  証拠: Chocolatey community package catalog: ldc from http://community.chocolatey.org/api/v2/Packages?$filter=IsLatestVersion&$select=Id&$top=1000&$skiptoken='8.8696','genymotion'

- Scoop (92%):

```sh
scoop install main/ldc
```

  証拠: Scoop official bucket manifest trees: bucket/ldc.json from https://api.github.com/repos/ScoopInstaller/Main/git/trees/master?recursive=1

## パッケージ情報

- **パッケージキー:** brew:ldc
- **パッケージマネージャ:** Homebrew
- **バージョン:** 1.42.0
- **ソース概要:** Portable D programming language compiler
- **ホームページ:** <https://wiki.dlang.org/LDC>
- **リポジトリ:** <https://github.com/ldc-developers/ldc>
- **生成日時:** 2026-08-03T19:37:03+00:00

## 実行可能ファイル

- ldc-build-plugin (エイリアス)
- ldc-build-runtime (エイリアス)
- ldc-profdata (エイリアス)
- ldc-profgen (エイリアス)
- ldc-prune-cache (エイリアス)
- ldc2 (エイリアス)
- ldmd2 (エイリアス)
- timetrace2txt (エイリアス)

## インストール挙動

- Bottle: 利用不可

## バージョンと鮮度

- ページ生成日: 2026-08-03
- マネージャ版: 1.42.0
## プロジェクトの歴史と使われ方

LDC is the LLVM-backed compiler for the D programming language, pairing the D frontend and runtime libraries with LLVM code generation and optimization.

### プロジェクトの歴史

LDC emerged to give D programmers an LLVM-based alternative to the reference DMD compiler and GCC's GDC. The project README describes the compiler as using the official DMD frontend and LLVM as backend, with the ldc2 command as the main compiler driver.

The project evolved from early experimental D compiler work into a regular release train maintained by the ldc-developers organization. Its changelog shows the ongoing maintenance burden that matters for compilers: tracking D frontend/druntime/Phobos versions, LLVM versions, target ABI changes, platform support, and prebuilt binary packaging.

By the 1.x series, LDC had become a practical production compiler for D, not just a backend experiment. Its release notes repeatedly call out supported LLVM ranges, bundled LLVM versions for prebuilt packages, cross-compilation work, and platform fixes across Linux, macOS, Windows, Android, Alpine/musl, RISC-V, PowerPC, and other targets.

### 採用の歴史

LDC's adoption is tied to D users who want LLVM optimization, broader target support, link-time optimization, and packaging-friendly prebuilt compilers. Package-manager coverage across Homebrew, Debian, Ubuntu, Fedora-family systems, Alpine, Arch, Nix, Scoop, Chocolatey, MacPorts, and openSUSE-family systems reflects that it is one of the standard ways to install a D compiler.

The project also matters to downstream packagers because its behavior depends on matching D frontend/runtime versions to LLVM support windows. The changelog's repeated packaging notes, glibc baseline changes, installer changes, and bundled-runtime details are signals of a mature compiler package rather than a small standalone CLI.

### 使われ方

Users invoke ldc2 to compile D programs, use ldmd2 for DMD-compatible command-line behavior, and rely on helper tools such as ldc-build-runtime, ldc-build-plugin, ldc-profdata, ldc-profgen, and timetrace2txt for runtime building, plugin workflows, profiling, and build-time analysis.

The compiler is commonly selected when D code needs LLVM optimization, cross-compilation targets, sanitizer or profiling support, or integration with LLVM-adjacent workflows.

### パッケージ好きにとっての重要性

LDC is package-nerd significant because compiler packages sit at the junction of language ecosystems and system toolchains. It has to coordinate D language releases, LLVM ABI/API changes, C toolchains, platform linkers, bundled runtime libraries, and distro-specific packaging constraints.

For Homebrew and other package managers, LDC is also a dependency-shaped package: installing it is not just about one executable, but about shipping a coherent compiler, runtime, standard library, config files, and helper tools.

### タイムライン

- 2000s: LDC begins as an LLVM-based compiler path for the D language.
- 2016: The 1.0 release line establishes LDC as a stable D compiler package.
- 2023: LDC 1.33.0 documents semantic-analysis plugin support and adds ldc-build-plugin.
- 2024: LDC 1.38.0 documents LLVM 18 support and Android TLS/runtime changes.
- 2025: LDC 1.41.0 documents LLVM 20 support and Ubuntu 22.04-based Linux packages.
- 2026-03-01: LDC 1.42.0 documents LLVM 21 support and D frontend/druntime/Phobos version 2.112.1+.

### Related projects

- Related projects include DMD, the reference D compiler whose frontend LDC tracks; GDC, the GCC-based D compiler; LLVM and Clang; and the D runtime and Phobos standard library.

### ソース

- <https://formulae.brew.sh/formula/ldc>
- <https://github.com/ldc-developers/ldc>
- <https://github.com/ldc-developers/ldc/releases>
- <https://raw.githubusercontent.com/ldc-developers/ldc/master/CHANGELOG.md>
- <https://wiki.dlang.org/LDC>


## セキュリティノート

generalized runtime or code generation signal.

- **Geiger リスク:** yellow / 中
- generalized runtime or code generation signal

## 他のパッケージマネージャ記録

- Debian apt - ldc - 1:1.40.0-5: normalized package name match | Debian stable package indexes: ldc from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | LLVM D Compiler | https://github.com/ldc-developers/ldc
- Debian apt - libphobos2-ldc-shared-dev - 1:1.40.0-5: normalized package name match | Debian stable package indexes: libphobos2-ldc-shared-dev from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | LLVM D Compiler - Standard and runtime libraries, imports | https://github.com/ldc-developers/ldc
- Debian apt - libphobos2-ldc-shared110 - 1:1.40.0-5: normalized package name match | Debian stable package indexes: libphobos2-ldc-shared110 from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | LLVM D Compiler - Standard and runtime libraries | https://github.com/ldc-developers/ldc
- Nix - ldc: normalized package name match | nixpkgs package indexes: pkgs/by-name/ld/ldc/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- Ubuntu apt - ldc - 1:1.36.0-2ubuntu2: normalized package name match | Ubuntu 24.04 LTS package indexes: ldc from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | LLVM D Compiler | https://github.com/ldc-developers/ldc
- Ubuntu apt - libphobos2-ldc-shared-dev - 1:1.36.0-2ubuntu2: normalized package name match | Ubuntu 24.04 LTS package indexes: libphobos2-ldc-shared-dev from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | LLVM D Compiler - Standard and runtime libraries, imports | https://github.com/ldc-developers/ldc
- Ubuntu apt - libphobos2-ldc-shared106 - 1:1.36.0-2ubuntu2: normalized package name match | Ubuntu 24.04 LTS package indexes: libphobos2-ldc-shared106 from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | LLVM D Compiler - Standard and runtime libraries | https://github.com/ldc-developers/ldc
- apk - ldc - 1.42.0-r0: normalized package name match | Alpine Linux edge package indexes: ldc from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | The LLVM-based D Compiler | https://github.com/ldc-developers/ldc
- apk - ldc-bash-completion - 1.42.0-r0: normalized package name match | Alpine Linux edge package indexes: ldc-bash-completion from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | Bash completions for ldc | https://github.com/ldc-developers/ldc
- apk - ldc-dbg - 1.42.0-r0: normalized package name match | Alpine Linux edge package indexes: ldc-dbg from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | The LLVM-based D Compiler (debug symbols) | https://github.com/ldc-developers/ldc
- apk - ldc-runtime - 1.42.0-r0: normalized package name match | Alpine Linux edge package indexes: ldc-runtime from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | Dynamic runtime library for D code compiled with ldc-1.42.0 | https://github.com/ldc-developers/ldc
- apk - ldc-static - 1.42.0-r0: normalized package name match | Alpine Linux edge package indexes: ldc-static from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | The LLVM-based D Compiler (static library) | https://github.com/ldc-developers/ldc
- dnf - ldc - 1.42.0-3.fc45: normalized package name match | Fedora Rawhide package metadata: ldc from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/07190dc5ae9f35ae73866675fed6d95fe6e8d9fe22c9d7cdf85862cb2ed24a4c-primary.xml.zst | LLVM D Compiler | https://github.com/ldc-developers/ldc
- dnf - ldc-libs - 1.42.0-3.fc45: normalized package name match | Fedora Rawhide package metadata: ldc-libs from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/07190dc5ae9f35ae73866675fed6d95fe6e8d9fe22c9d7cdf85862cb2ed24a4c-primary.xml.zst | LLVM D Compiler libraries | https://github.com/ldc-developers/ldc
- pacman - ldc - 3:1.42.0-1: normalized package name match | Arch Linux sync databases: ldc from https://geo.mirror.pkgbuild.com/extra/os/x86_64/extra.db.tar.gz | A D Compiler based on the LLVM Compiler Infrastructure including D runtime and libphobos2 | https://github.com/ldc-developers/ldc
- zypper - ldc - 1.42.0-1.2: normalized package name match | openSUSE Tumbleweed package metadata: ldc from https://download.opensuse.org/tumbleweed/repo/oss/repodata/50b07339cb64c8ed4091bdbabddadc1ff5737b090e478818a195b40d8a3292861a879139b4a3987c31109699fde9fbf4a716367ddf4eef77da75f96e3193d6ed-primary.xml.zst | The LLVM D Compiler | https://wiki.dlang.org/LDC


## Combined YAML source

View the package source record on GitHub. [combined/ldc.yml](https://github.com/mxcl/pkgdb/blob/main/combined/ldc.yml)


## ソース

- pkg.so package database
- Geiger risk classifier
- curated package history
- pkgdb category and tag curation
- external package-manager database matches
- cross-ecosystem install command graph
