From ebf9293df25516237e8c799adfbc5a38444c8aed Mon Sep 17 00:00:00 2001 From: Huyvux12 Date: Thu, 19 Nov 2026 18:15:46 +0000 Subject: [PATCH 1/3] Fix #299: swap Debian/Fedora libzim package names in README Debian's development package is libzim-dev and Fedora's is libzim-devel; the README had them backwards. Also note that a system build requires C++ libzim 9.x (bundled build is 9.8.2) and point users with older distro packages (e.g. libzim-dev 8.2.1 on Ubuntu 24.04) to the bundled build. --- README.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 468f6052..d0e3c98a 100644 --- a/README.md +++ b/README.md @@ -229,8 +229,8 @@ python3 -m build ```sh # using system-installed C++ libzim brew install libzim # macOS -apt-get install libzim-devel # debian -dnf install libzim-dev # fedora +apt-get install libzim-dev # debian +dnf install libzim-devel # fedora USE_SYSTEM_LIBZIM=1 python3 -m build --wheel # using a specific C++ libzim @@ -242,6 +242,8 @@ LD_LIBRARY_PATH="/usr/local/lib" \ python3 -m build --wheel ``` +Building against a system libzim requires C++ libzim 9.x: python-libzim has built against libzim 9 since 3.3.0 and the bundled build downloads 9.8.2, so an older distribution package — for example `libzim-dev` 8.2.1 on Ubuntu 24.04 — lacks headers this version uses (e.g. `zim/illustration.h`). If your distribution only ships an older libzim, use the default bundled build instead of `USE_SYSTEM_LIBZIM=1`. + #### Other platforms On platforms for which there is no [official binary](https://download.openzim.org/release/libzim/) available, you'd have to [compile C++ libzim from source](https://github.com/openzim/libzim) first then either use `DONT_DOWNLOAD_LIBZIM` or `USE_SYSTEM_LIBZIM`. From 14a2d4a1105f4ad3a280edc98e2afd4278d98ebb Mon Sep 17 00:00:00 2001 From: Huyvux12 Date: Fri, 20 Nov 2026 09:34:02 +0000 Subject: [PATCH 2/3] Address review: state the system-libzim limitation generically Drop the distro-specific symptoms (Ubuntu 24.04's 8.2.1 package, the missing zim/illustration.h header) and instead state the limitation itself: a system build needs a libzim compatible with this release (9.x), and distributions do not all ship one recent enough, in which case the bundled build should be used. --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index d0e3c98a..7bc4753b 100644 --- a/README.md +++ b/README.md @@ -242,7 +242,7 @@ LD_LIBRARY_PATH="/usr/local/lib" \ python3 -m build --wheel ``` -Building against a system libzim requires C++ libzim 9.x: python-libzim has built against libzim 9 since 3.3.0 and the bundled build downloads 9.8.2, so an older distribution package — for example `libzim-dev` 8.2.1 on Ubuntu 24.04 — lacks headers this version uses (e.g. `zim/illustration.h`). If your distribution only ships an older libzim, use the default bundled build instead of `USE_SYSTEM_LIBZIM=1`. +Building against a system libzim requires a C++ libzim compatible with this release (9.x — the bundled build uses 9.8.2). Distributions do not all ship a recent enough libzim, so if yours only provides an older one, use the default bundled build instead of `USE_SYSTEM_LIBZIM=1`. #### Other platforms From 140373c5c499c7976263bab19af2afc9473aaec9 Mon Sep 17 00:00:00 2001 From: Huyvux12 Date: Fri, 20 Nov 2026 13:30:16 +0000 Subject: [PATCH 3/3] Use benoit74's clearer wording for the system-libzim note Adopt the wording proposed in review: setting USE_SYSTEM_LIBZIM=1 builds against the system libzim, which must be a compatible version, and leaving it unset downloads and bundles a compatible libzim automatically. This keeps the note generic (per rgaudin's earlier review) while stating the point directly. --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 7bc4753b..fbaa8c55 100644 --- a/README.md +++ b/README.md @@ -242,7 +242,7 @@ LD_LIBRARY_PATH="/usr/local/lib" \ python3 -m build --wheel ``` -Building against a system libzim requires a C++ libzim compatible with this release (9.x — the bundled build uses 9.8.2). Distributions do not all ship a recent enough libzim, so if yours only provides an older one, use the default bundled build instead of `USE_SYSTEM_LIBZIM=1`. +Setting `USE_SYSTEM_LIBZIM=1` builds against the libzim installed on your system, which must be a version compatible with this version of python-libzim. Many distributions ship an older libzim. If yours does, leave `USE_SYSTEM_LIBZIM` unset, and the build will download and bundle a compatible libzim automatically. #### Other platforms