🍺 BREW Explorer

← all formulae

libxmlb

brew install libxmlb v0.3.27 LGPL-2.1-or-later

Library for querying compressed XML metadata

1.4k
30-day installs · #1145
4.5k
90-day · #1150
15.2k
365-day · #1209
41
★ GitHub stars · updated 2mo ago

Runtime dependencies

Build dependencies

Links

Raw metadata
{
  "aliases": [],
  "alternatives": [],
  "build_dependencies": [
    "gi-docgen",
    "gobject-introspection",
    "meson",
    "ninja",
    "pkgconf",
    "python@3.14",
    "vala"
  ],
  "categories": [],
  "caveats": null,
  "conflicts_with": [],
  "dependencies": [
    "glib",
    "xz",
    "zstd"
  ],
  "deprecated": 0,
  "deprecation_reason": null,
  "desc": "Library for querying compressed XML metadata",
  "disable_reason": null,
  "disabled": 0,
  "enrichment_fetched_at": "2026-06-20T23:41:21+00:00",
  "first_seen": "2026-06-20T23:34:18+00:00",
  "full_name": "libxmlb",
  "github_default_branch": "main",
  "github_last_commit_at": "2026-06-08T09:44:15Z",
  "github_readme_excerpt": "libxmlb\n=======\n\n[![Coverity Scan Build Status](https://scan.coverity.com/projects/17055/badge.svg)](https://scan.coverity.com/projects/17055)\n[![OpenSSF Scorecard](https://api.securityscorecards.dev/projects/github.com/hughsie/libxmlb/badge)](https://securityscorecards.dev/viewer/?uri=github.com/hughsie/libxmlb)\n\nIntroduction\n------------\n\nXML is slow to parse and strings inside the document cannot be memory mapped as\nthey do not have a trailing NUL char. The libxmlb library takes XML source, and\nconverts it to a structured binary representation with a deduplicated string\ntable -- where the strings have the NULs included.\n\nThis allows an application to mmap the binary XML file, do an XPath query and\nreturn some strings without actually parsing the entire document. This is all\ndone using (almost) zero allocations and no actual copying of the binary data.\n\nAs each node in the binary XML file encodes the \u0027next\u0027 node at the same level\nit makes skipping whole subtrees trivial. A 10Mb binary XML file can be loaded\nfrom disk **and** queried in less than a few milliseconds.\n\nThe binary XML is not supposed to be small. It\u0027s usually about half the size of\nthe text XML data where a lot of the tag content is duplicated, but can actually\nbe larger than the original XML file. This isn\u0027t important; the fast query speed\nand the ability to mmap strings without copies more than makes up for the larger\non-disk size. If you want to compress your XML, this library probably isn\u0027t for\nyou -- just use gzip -- it gives you an almost a perfect compression ratio for\ndata like this.\n\nFor example:\n\n    $ xb-tool compile fedora.xmlb fedora.xml.gz\n\n    $ du -h fedora.xml*\n    12M         fedora.xmlb\n    3.6M        fedora.xml.gz\n\n    $ xb-tool query fedora.xmlb \"components/component[@type=desktop]/id[text()=firefox.desktop]\"\n    RESULT: firefox.desktop\n    real        0m0.011s\n    user        0m0.010s\n    sys         0m0.001s\n\nXPath\n=====\n\nThis library only implements a tiny subset of XPath. See",
  "github_repo": "hughsie/libxmlb",
  "github_stars": 41,
  "github_topics": [],
  "homepage": "https://github.com/hughsie/libxmlb",
  "homepage_og_description": null,
  "homepage_og_image": null,
  "homepage_title": null,
  "installs_30d": 1391,
  "installs_365d": 15230,
  "installs_90d": 4470,
  "keg_only": 0,
  "keg_only_reason": null,
  "last_seen": "2026-06-20T23:34:18+00:00",
  "license": "LGPL-2.1-or-later",
  "llm_generated_at": null,
  "llm_model": null,
  "name": "libxmlb",
  "oldnames": [],
  "one_liner": null,
  "optional_dependencies": [],
  "rank_30d": 1145,
  "rank_365d": 1209,
  "rank_90d": 1150,
  "raw_hash": "abced6c45f4e57e7",
  "recommended_dependencies": [],
  "revision": 0,
  "ruby_source_path": "Formula/lib/libxmlb.rb",
  "tap": "homebrew/core",
  "test_dependencies": [
    "pkgconf"
  ],
  "uses_from_macos": [],
  "version_head": "HEAD",
  "version_stable": "0.3.27",
  "versioned_formulae": [],
  "why_use_this": null
}