Skip to the text
KDOS
Menu
kdos.dev KDOS from Scratch KDOS 0.2 · 4dd4a10 · 2026-11-30 Contents Index

194.3. pango-1.58.2

Text layout and rendering library, with pangoxft

Version 1.58.2, release 1
Shelf graphics-libs — 2D rendering, vector and SVG, text layout, colour management and graph drawing libraries
Phase 42_graphics (Graphics Stack), 35 of 189 in build order
Licence LGPL-2.0-or-later
Homepage https://gitlab.gnome.org/GNOME/pango
Build time 0.9 SBU
Installed size 2.6 MiB in 75 files
Recipe ports/core/graphics-libs/pango/kpkgbuild

About

pango lays out and renders text: it splits a paragraph into runs by script, direction and font, shapes each run with harfbuzz, breaks lines, and draws the result through cairo. GTK 3 and 4 and every program built on them lay out their text with it. Besides libpango this build installs pangocairo, pangoft2, pangoxft, the introspection data, and the pango-view, pango-list and pango-segmentation tools with their manual pages.

Sources

Dependencies

Depends on: cairo, harfbuzz, fribidi, fontconfig, freetype2, glib, libthai, meson, python3-docutils, libXft, libXrender, libX11, gobject-introspection, glib-introspection.

Required by (44): abiword, appstream, ardour, darktable, fcitx5, firefox-esr, fltk, font-manager, gegl, gimp, glabels, gnumeric, gnuplot, gnuradio, goffice, gramps, graphviz, gst-plugins-bad, gst-plugins-base, gtk3, gtk4, gtksourceview4, gtksourceview5, imagemagick, imv, inkscape, lasem, libdecor, librewolf, librsvg, libvips, mlt, pangomm, pangomm2.46, R, remmina, rhythmbox, sdl2-pango, thunderbird, tryton, tuxpaint, vte3, wesnoth, wxwidgets.

Installation

From the repository root, inside the build container, this is the line kdosbuild runs for the port:

script/chroot/exec.sh bash -c 'source script/phases/42_graphics/phase.env && kpkg install pango'

What kpkg does

kpkg runs these steps, in this order, as root inside the chroot. The port directory is /ports/core/graphics-libs/pango.

1. Verify every declared source. Each file a sha256 = line names, found in the port directory or in /var/cache/kpkg/sources, must hash to its line; a mismatch stops the build before anything is unpacked.

cd /ports/core/graphics-libs/pango
echo '342385b6ca3b7c73455d7c80a13b7dbe4489e00bc3bd4c5bd6ed4dce421e374a  pango-1.58.2.tar.xz' | sha256sum -c -

2. Unpack. The work directory is emptied and the first source is unpacked into $SRC with its top directory stripped; any later tarball lands unstripped beside it in $SRC_ROOT, and a file that is not a tarball is copied into $SRC.

SRC_ROOT=/var/cache/kpkg/work/pango
SRC=$SRC_ROOT/pango-1.58.2
PKG=$SRC_ROOT/pkg
rm -rf "$SRC_ROOT"
mkdir -p "$SRC" "$PKG"
tar --no-same-permissions --warning=no-unknown-keyword -xf pango-1.58.2.tar.xz -C "$SRC" --strip-components=1

Every config.guess and config.sub older than automake’s is then replaced with automake’s, so a configure script recognises the musl target.

3. Build. build.sh is sourced in a subshell under set -e, from $SRC, with name, version, release and the recipe’s helpers devseries and the five paths PKGNAME, PORT_SRC, SRC_ROOT, SRC and PKG set as shell variables. Its body, verbatim:

meson setup build --buildtype=release --prefix=/usr --sysconfdir=/etc --libdir=lib \
	-Dintrospection=enabled \
	-Dxft=enabled \
	-Dlibthai=enabled \
	-Dcairo=enabled \
	-Dfontconfig=enabled \
	-Dfreetype=enabled \
	-Dsysprof=disabled \
	-Dbuild-testsuite=false \
	-Dbuild-examples=false \
	-Dman-pages=true
meson compile -C build
DESTDIR=$PKG meson install --no-rebuild -C build

The switches, and why each is set:

The common switches of each build system are explained in the Flag glossary.

4. Package. kpkg removes libtool archives, the info directory index, mimeinfo.cache and every fonts.dir from $PKG, copies the source’s licence files into /usr/share/licenses/pango, prunes what the image does not ship, lints the tree and rolls it reproducibly:

tar --sort=name --format=gnu --numeric-owner --owner=0 --group=0 \
    --mtime=@$SOURCE_DATE_EPOCH \
    --use-compress-program='xz -9 -T0 --block-size=32MiB --no-adjust' \
    -cf pango-1.58.2-1.tar.xz -C "$PKG" .

5. Adopt. kpkgadd installs the package’s files over the root, refusing a path another package owns, records the file list in /var/lib/kpkg/db/pango, and runs the triggers its paths call for.

Contents

Installed programs: pango-list, pango-segmentation, pango-view.

Installed libraries: libpango-1.0.so, libpangocairo-1.0.so, libpangoft2-1.0.so, libpangoxft-1.0.so.

Installed directories: /usr/include/pango-1.0, /usr/share/licenses/pango.

Short descriptions

pango-list Pango font enumeration
pango-segmentation Pango text segmentation
pango-view Pango text viewer
pango.pc Internationalized text handling
pangocairo.pc Cairo rendering support for Pango
pangofc.pc Fontconfig support for Pango
pangoft2.pc FreeType 2.0 and fontconfig font support for Pango
pangoot.pc OpenType font support for Pango (deprecated)
pangoxft.pc Xft font support for Pango