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

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

## インストール

```sh
sudo av install brew:libxml2
```

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

### macOS

- Homebrew (100%):

```sh
brew install libxml2
```

  証拠: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install libxml2
```

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

### Linux

- apk (92%):

```sh
sudo apk add libxml2
```

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

- Debian apt (92%):

```sh
sudo apt install libxml2
```

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

- dnf (92%):

```sh
sudo dnf install libxml2
```

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

- pacman (92%):

```sh
sudo pacman -S libxml2
```

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

- zypper (92%):

```sh
sudo zypper install libxml2-16
```

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

### Windows

- Scoop (92%):

```sh
scoop install main/libxml2
```

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

## パッケージ情報

- **パッケージキー:** brew:libxml2
- **パッケージマネージャ:** Homebrew
- **バージョン:** 2.15.3
- **ソース概要:** GNOME XML library
- **ホームページ:** <http://xmlsoft.org/>
- **生成日時:** 2026-08-03T19:37:03+00:00

## 実行可能ファイル

- xml2-config (エイリアス)
- xmlcatalog (エイリアス)
- xmllint (エイリアス)

## インストール挙動

- Bottle: 利用不可

## バージョンと鮮度

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

libxml2 is the GNOME XML C parser and toolkit, but its reach extends far beyond GNOME. It became one of the default XML implementations for Unix-like systems because it combines parser, tree API, validation support, HTML parsing, catalog handling, command-line tools, and language bindings in a portable C library.

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

The libxml2 documentation describes the project as an XML toolkit implemented in C and originally developed for the GNOME Project. The historical xmlsoft.org documentation credited Daniel Veillard as the maintainer and pointed users to GNOME CVS modules for libxml2 and libxslt.

GNOME's release archive contains the libxml2 2.0.0 source tarball dated 2000-04-12. The project's public documentation records the GNOME GitLab repository and the GNOME download archive as official locations, showing the migration from the older xmlsoft/GNOME CVS era to GNOME-hosted GitLab and generated API documentation.

### 採用の歴史

libxml2 was adopted widely because XML was a core interchange format for desktop files, configuration formats, documentation systems, web service stacks, office formats, and build tooling. Its permissive MIT license, C API, portability, and bindings made it attractive to distributions and application runtimes.

The command-line tools xmllint and xmlcatalog gave the library a direct package-manager presence. Even users who never linked libxml2 could install the package to validate XML, inspect documents, test XPath expressions, or manage XML catalogs in build and documentation pipelines.

### 使われ方

Common package usage includes linking against libxml2 for parsing and validation, using xmllint in scripts and tests, and using xmlcatalog where systems rely on XML catalog resolution. It is also a dependency layer for related XML software such as libxslt and xmlsec.

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

libxml2 is package-nerd infrastructure: small enough to be considered a library dependency, but important enough that parser behavior, security fixes, and ABI expectations affect browsers, language ecosystems, desktop software, and distro bootstrap graphs. Its presence in package managers is a sign that XML support is part of the Unix substrate rather than a niche add-on.

### タイムライン

- 2000: GNOME's source archive lists libxml2 2.0.0 dated 2000-04-12.
- 2002: Historical xmlsoft documentation points to GNOME CVS modules for libxml2 and libxslt.
- 2022: GNOME-hosted API documentation records the project repository on GNOME GitLab.
- 2026: GNOME's source archive lists maintained 2.x release directories through the 2.15 series.

### Related projects

- libxslt builds on the same GNOME XML stack for XSLT processing. XML Security Library uses libxml2 as its XML foundation. Higher-level bindings and wrappers expose libxml2 to languages such as Python, Perl, Ruby, PHP, and others.

### ソース

- <https://download.gnome.org/sources/libxml2/>
- <https://download.gnome.org/sources/libxml2/2.0/>
- <https://gnome.pages.gitlab.gnome.org/libxml2/>
- <https://web.mit.edu/ghudson/dev/nokrb/third/libxml2/doc/downloads.html>


## セキュリティノート

library-like package without higher-risk signals.

- **Geiger リスク:** グリーン / 低
- library-like package without higher-risk signals

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

- Debian apt - libxml2 - 2.12.7+dfsg+really2.9.14-2.1+deb13u3: normalized package name match | Debian stable package indexes: libxml2 from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | GNOME XML library | http://xmlsoft.org
- Debian apt - libxml2-dev - 2.12.7+dfsg+really2.9.14-2.1+deb13u3: normalized package name match | Debian stable package indexes: libxml2-dev from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | GNOME XML library - development files | http://xmlsoft.org
- Debian apt - libxml2-doc - 2.12.7+dfsg+really2.9.14-2.1+deb13u3: normalized package name match | Debian stable package indexes: libxml2-doc from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | GNOME XML library - documentation | http://xmlsoft.org
- Debian apt - libxml2-utils - 2.12.7+dfsg+really2.9.14-2.1+deb13u3: normalized package name match | Debian stable package indexes: libxml2-utils from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | GNOME XML library - utilities | http://xmlsoft.org
- Debian apt - python3-libxml2 - 2.12.7+dfsg+really2.9.14-2.1+deb13u3: normalized package name match | Debian stable package indexes: python3-libxml2 from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | GNOME XML library - Python3 bindings | http://xmlsoft.org
- Ubuntu apt - libxml2 - 2.9.14+dfsg-1.3ubuntu3: normalized package name match | Ubuntu 24.04 LTS package indexes: libxml2 from https://archive.ubuntu.com/ubuntu/dists/noble/main/binary-amd64/Packages.gz | GNOME XML library | http://xmlsoft.org
- Ubuntu apt - libxml2-dev - 2.9.14+dfsg-1.3ubuntu3: normalized package name match | Ubuntu 24.04 LTS package indexes: libxml2-dev from https://archive.ubuntu.com/ubuntu/dists/noble/main/binary-amd64/Packages.gz | GNOME XML library - development files | http://xmlsoft.org
- Ubuntu apt - libxml2-doc - 2.9.14+dfsg-1.3ubuntu3: normalized package name match | Ubuntu 24.04 LTS package indexes: libxml2-doc from https://archive.ubuntu.com/ubuntu/dists/noble/main/binary-amd64/Packages.gz | GNOME XML library - documentation | http://xmlsoft.org
- Ubuntu apt - libxml2-utils - 2.9.14+dfsg-1.3ubuntu3: normalized package name match | Ubuntu 24.04 LTS package indexes: libxml2-utils from https://archive.ubuntu.com/ubuntu/dists/noble/main/binary-amd64/Packages.gz | GNOME XML library - utilities | http://xmlsoft.org
- Ubuntu apt - python3-libxml2 - 2.9.14+dfsg-1.3ubuntu3: normalized package name match | Ubuntu 24.04 LTS package indexes: python3-libxml2 from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | GNOME XML library - Python3 bindings | http://xmlsoft.org
- apk - libxml2 - 2.13.9-r2: normalized package name match | Alpine Linux edge package indexes: libxml2 from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | XML parsing library, version 2 | https://gitlab.gnome.org/GNOME/libxml2
- apk - libxml2-dbg - 2.13.9-r2: normalized package name match | Alpine Linux edge package indexes: libxml2-dbg from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | XML parsing library, version 2 (debug symbols) | https://gitlab.gnome.org/GNOME/libxml2
- apk - libxml2-dev - 2.13.9-r2: normalized package name match | Alpine Linux edge package indexes: libxml2-dev from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | XML parsing library, version 2 (development files) | https://gitlab.gnome.org/GNOME/libxml2
- apk - libxml2-doc - 2.13.9-r2: normalized package name match | Alpine Linux edge package indexes: libxml2-doc from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | XML parsing library, version 2 (documentation) | https://gitlab.gnome.org/GNOME/libxml2
- apk - libxml2-static - 2.13.9-r2: normalized package name match | Alpine Linux edge package indexes: libxml2-static from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | XML parsing library, version 2 (static library) | https://gitlab.gnome.org/GNOME/libxml2
- apk - libxml2-utils - 2.13.9-r2: normalized package name match | Alpine Linux edge package indexes: libxml2-utils from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | XML utilities | https://gitlab.gnome.org/GNOME/libxml2


## Combined YAML source

View the package source record on GitHub. [combined/libxml2.yml](https://github.com/mxcl/pkgdb/blob/main/combined/libxml2.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
