327.20. kfourinline-26.08.2
Four in a row against the computer, or against another player over the network
26.08.2-1 · LGPL-2.0-or-later AND LGPL-2.0-only AND (LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL) AND GFDL-1.2-or-later AND BSD-3-Clause AND CC0-1.0 · 0.6 SBU · 1.6 MiB, 37 files · 44_apps, 166 of 422 · ports/core/games-board/kfourinline
Homepage: https://apps.kde.org/kfourinline/
KFourInLine is four in a row: drop pieces into a seven-column board until one player has four in a line. It plays against a computer opponent at several strengths, or against another person at the same screen or over the network. The computer player is a program of its own, kfourinlineproc, which the game drives over its standard input and output.
Depends on: cmake, ninja, extra-cmake-modules, qt6-qtbase, qt6-qtsvg, kconfig, kconfigwidgets, kcoreaddons, kcrash, kdbusaddons, kdnssd, kdoctools, ki18n, kiconthemes, kwidgetsaddons, kxmlgui, libkdegames, gzip.
Required by (1): kde-gear-games.
Sources: kfourinline-26.08.2.tar.xz (732.6 KiB). Every step kpkg takes applies to this port.
Install: script/chroot/exec.sh bash -c 'source script/phases/44_apps/phase.env && kpkg install kfourinline'
build.sh:
cmake -S . -B build -G Ninja \
-D CMAKE_INSTALL_PREFIX=/usr \
-D KDE_INSTALL_LIBDIR=lib \
-D CMAKE_BUILD_TYPE=Release \
-D KDE_INSTALL_USE_QT_SYS_PATHS=ON \
-D BUILD_TESTING=OFF \
-D KF_SKIP_PO_PROCESSING=ON \
-D CMAKE_DISABLE_FIND_PACKAGE_7Zip=ON \
-Wno-dev
cmake --build build
DESTDIR=$PKG cmake --install build
-D KF_SKIP_PO_PROCESSING=ON— Skips building the interface translations, which the package-wide English-only rule would remove anyway (see Size and language policy).kdoctools_install()still builds the handbook in every translated language, and kpkg’s language rule removes/usr/share/doc/HTML/<lang>/from the package.-D CMAKE_DISABLE_FIND_PACKAGE_7Zip=ON— Compresses the theme SVGs to SVGZ with gzip. Upstream’scmake/InternalMacros.cmakeuses 7-Zip’s7zzwhenever it finds one and otherwise requires gzip; 7zip is built in an earlier phase, so without the switch the package would follow whatever the build root holds. gzip runs with-n, which writes no file name or time stamp into the SVGZ files.
Programs: kfourinline, kfourinlineproc.
Directories: /usr/share/doc/HTML/en/kfourinline, /usr/share/kfourinline, /usr/share/licenses/kfourinline.
The game looks for kfourinlineproc first at kwin4/kfourinlineproc under its working directory and then on PATH, so a game started from a directory that holds such a file runs that file as the computer player.
The connect dialog finds network games on the local network through KDNSSD from kdnssd, which talks to the avahi daemon of avahi over D-Bus; mDNS, UDP 5353, passes the shipped firewall. A machine that hosts a game listens on TCP 7442, which the firewall’s input chain drops until a rule opens it (see The firewall); joining a game another machine hosts needs no rule.
The window’s Wayland app_id is org.kde.kfourinline: KAboutData builds that desktop file name from the component name and its organisation domain, kde.org. It is the desktop entry’s file name too, and upstream’s entry sets no StartupWMClass, so the task manager pairs the window with its entry without a patch.