libxml2

The XML C parser and toolkit of Gnome.

Latest version: 2.14.3

Add to xmake.lua

add_requires("libxml2 2.14.3")

Learn how to add and link packages with Xmake →

Information

License
MIT
Recipe updated
2025-06-11T00:58:36.000Z

Platforms

  • android: armeabi, armeabi-v7a, arm64-v8a, riscv64, x86, x86_64, mips, mip64
  • msys: i386, x86_64
  • mingw: i386, x86_64, arm, arm64
  • windows: x86, x64, arm, arm64, arm64ec
  • linux: i386, x86_64, armv7, armv7s, arm64, mips, mips64, mipsel, mips64el, loong64, riscv64, s390x, ppc, ppc64, ppc64el, sparc64
  • bsd: i386, x86_64, arm, arm64, ppc, ppc64, ppc64el, riscv64, sparc64
  • harmony: armeabi-v7a, arm64-v8a, x86, x86_64
  • cross: i386, x86_64, arm, armv7, arm64, mips, mips64, mips64el, riscv, riscv64, loong64, s390x, ppc, ppc64, ppc64el, sh4, sparc64
  • wasm: wasm32, wasm64
  • iphoneos: arm64, x86_64
  • macosx: x86_64, arm64

Options

all
Enable all configs, exclude python · Type: boolean · Default: false
c14n
Add the Canonicalization support · Type: boolean · Default: true
catalog
Add the Catalog support · Type: boolean · Default: true
history
history support for xmllint shell · Type: boolean · Default: false
html
Add the HTML support · Type: boolean · Default: true
http
Add the HTTP support · Type: boolean · Default: false
iconv
Add ICONV support · Type: boolean · Default: false
icu
Add ICU support · Type: boolean · Default: false
iso8859x
Add ISO8859X support if no iconv · Type: boolean · Default: true
legacy
Add deprecated APIs for compatibility · Type: boolean · Default: false
lzma
Use liblzma · Type: boolean · Default: false
modules
Add the dynamic modules support · Type: boolean · Default: true
output
Add the serialization support · Type: boolean · Default: true
pattern
Add the xmlPattern selection interface · Type: boolean · Default: true
programs
Build programs · Type: boolean · Default: false
push
Add the PUSH parser interfaces · Type: boolean · Default: true
python
Build Python bindings · Type: boolean · Default: false
reader
Add the xmlReader parsing interface · Type: boolean · Default: true
readline
readline support for xmllint shell · Type: boolean · Default: false
regexps
Add Regular Expressions support · Type: boolean · Default: true
sax1
Add the older SAX1 interface · Type: boolean · Default: true
schemas
Add Relax-NG and Schemas support · Type: boolean · Default: true
schematron
Add Schematron support · Type: boolean · Default: true
thread_alloc
Add per-thread malloc hooks · Type: boolean · Default: false
threads
Add multithread support · Type: boolean · Default: true
tls
Enable thread-local storage · Type: boolean · Default: false
tools
Build tools · Type: boolean · Default: false
valid
Add the DTD validation support · Type: boolean · Default: true
writer
Add the xmlWriter saving interface · Type: boolean · Default: true
xinclude
Add the XInclude support · Type: boolean · Default: true
xpath
Add the XPATH support · Type: boolean · Default: true
xptr
Add the XPointer support · Type: boolean · Default: true
zlib
Use libz · Type: boolean · Default: false

Versions

  • v2.11.9
  • v2.12.9
  • v2.13.2
  • v2.13.4
  • v2.14.3

Dependencies

Used by (13)

Packages declaring this dependency; requirements can vary by platform and configuration.

Show 1 more

Install with xrepo

Install the package independently of a project and inspect its available configuration.

install

xrepo install "libxml2 2.14.3"

show info

xrepo info "libxml2"

Link a library to your target

Declare the requirement, then attach the library to the target that uses it.

xmake.lua

add_requires("libxml2 2.14.3")

target("demo")
    set_kind("binary")
    add_files("src/*.cpp")
    add_packages("libxml2")

Open a package environment

Open a shell with the environment exported by this package. Use the executable names documented by the package.

enter shell

xrepo env -b "libxml2 2.14.3" shell