253.5. vte3-0.84.1
Terminal emulator widget for GTK 3 and GTK 4
| Version | 0.84.1, release 1 |
| Shelf | gtk — The GLib and GTK platform and GNOME/Xfce desktop-platform libraries: widgets, settings, bindings, GIO plug-ins |
| Phase | 43_toolkits (Toolkits), 162 of 344 in build order |
| Licence | LGPL-3.0-or-later |
| Homepage | https://gitlab.gnome.org/GNOME/vte |
| Build time | 4.5 SBU |
| Installed size | 4.1 MiB in 50 files |
| Recipe | ports/core/gtk/vte3/kpkgbuild |
About
VTE is GNOME’s terminal emulator widget: a GTK widget that runs a program on a pseudo-terminal and draws its screen. This port builds it for both toolkits, libvte-2.91.so for gtk3 and libvte-2.91-gtk4.so for gtk4. In the tree, geany’s terminal pane, qemu’s GTK display (built --enable-vte, for its text consoles), virt-manager and remmina use it. The desktop’s terminal, Konsole, does not: it has its own emulator.
Sources
vte3-0.84.1.tar.xz(6.4 MiB)
sha256aca1caa8478aebcdbb1d67897fb3511eb7601debae6810e16a15b6fa25f31ac8
upstream: https://download.gnome.org/sources/vte/0.84/vte-0.84.1.tar.xz
archive copy: sources-2/gtk--vte3-0.84.1.tar.xz
Dependencies
Depends on: meson, ninja, pkgconf, python3, gtk3, gtk4, glib, pango, cairo, pcre2, lz4, fmt, fribidi, gnutls, icu, gobject-introspection, glib-introspection, vala.
Required by (4): geany, qemu, remmina, virt-manager.
Patches
build.sh applies these; kpkg applies nothing by itself.
fix-W_EXITCODE.patch— DefinesW_EXITCODE(ret, sig)as((ret) << 8 | (sig))insrc/widget.ccwhen the C library does not. VTE uses it to report a child killed withSIGKILLwhen the widget is destroyed; musl’s<sys/wait.h>has no such macro, and the file does not compile without it.
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/43_toolkits/phase.env && kpkg install vte3'
What kpkg does
kpkg runs these steps, in this order, as root inside the chroot. The port directory is /ports/core/gtk/vte3.
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/gtk/vte3
echo 'aca1caa8478aebcdbb1d67897fb3511eb7601debae6810e16a15b6fa25f31ac8 vte3-0.84.1.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/vte3
SRC=$SRC_ROOT/vte3-0.84.1
PKG=$SRC_ROOT/pkg
rm -rf "$SRC_ROOT"
mkdir -p "$SRC" "$PKG"
tar --no-same-permissions --warning=no-unknown-keyword -xf vte3-0.84.1.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 five paths PKGNAME, PORT_SRC, SRC_ROOT, SRC and PKG set as shell variables. Its body, verbatim:
patch -p1 -i "$PORT_SRC/fix-W_EXITCODE.patch"
meson setup build \
--prefix=/usr --sysconfdir=/etc --libdir=lib \
--buildtype=release \
--wrap-mode=nodownload \
-Dgtk3=true \
-Dgtk4=true \
-Dgir=true \
-Dvapi=true \
-Da11y=true \
-Dfribidi=true \
-Dgnutls=true \
-Dicu=true \
-D_systemd=false \
-Dterminfo=false \
-Dapp=false \
-Dglade=false \
-Ddocs=false \
-Ddbg=false
meson compile -C build
DESTDIR=$PKG meson install --no-rebuild -C build
The switches, and why each is set:
--wrap-mode=nodownload— Never download a meson subproject. The release tarball carries simdutf, fast_float and fmt undersubprojects/. simdutf and fast_float are used from those copies, since neither is a port; the configure takes fmt from its port in preference to the copy, and uses its headers only.-Dgtk3=true,-Dgtk4=true— Build both widgets from one source tree. Both are upstream’s defaults.-Dgir=true,-Dvapi=true— Generate the introspection data and the Vala bindings for both, through which Python, JavaScript and Vala programs use the widget. Both are upstream’s defaults.-Dgnutls=true— Encrypt the scrollback that VTE spills to disk, with gnutls. Without it every terminal opens with the warning “GnuTLS not enabled; data will be written to disk unencrypted!”.-Dicu=true— Support legacy character sets, other than UTF-8, through icu.-Dfribidi=true,-Da11y=true— Bidirectional text through fribidi, and the accessibility interface. Both are upstream’s defaults.-D_systemd=false— Build without libsystemd. Upstream’s default is on, and then VTE places each child program in a systemd scope of its own over D-Bus. KDOS has no systemd (see No systemd).-Dterminfo=false— Install no terminfo entry of VTE’s own; the option is experimental and off by default.-Dapp=false— Build neither of the test terminals,vte-2.91andvte-2.91-gtk4, which upstream builds by default.-Dglade=false— Install no catalogue file for the Glade interface designer, which is not a port.-Ddbg=false— No extra debugging code, upstream’s default.
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/vte3, 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 vte3-0.84.1-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/vte3, and runs the triggers its paths call for.
Contents
Installed libraries: libvte-2.91-gtk4.so, libvte-2.91.so.
Installed directories: /usr/include/vte-2.91, /usr/include/vte-2.91-gtk4, /usr/share/licenses/vte3.
Short descriptions
vte-2.91.pc |
VTE widget for GTK+ 3.0 |
vte-2.91-gtk4.pc |
VTE widget for GTK+ 4.0 |