327.30. knights-26.08.2
Chess board for local engines, two players at one desk or the Free Internet Chess Server
26.08.2-1 · (GPL-2.0-only OR GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL) AND GPL-2.0-or-later AND GFDL-1.2-or-later AND BSD-3-Clause AND CC0-1.0 · 1.0 SBU · 3.4 MiB, 59 files · 44_apps, 176 of 422 · ports/core/games-board/knights
Homepage: https://apps.kde.org/knights/
Knights is KDE’s chess board. It plays against a local chess engine over the XBoard or UCI protocol, two people at one desk, two engines against each other, or opponents on the Free Internet Chess Server, with clocks, themes and spoken moves. It is a Qt 6 and KDE Frameworks application built on libkdegames.
Depends on: cmake, ninja, extra-cmake-modules, qt6-qtbase, qt6-qtsvg, qt6-qtspeech, kcompletion, kconfig, kconfigwidgets, kcoreaddons, kcrash, kdbusaddons, kdoctools, ki18n, kio, kplotting, ksvg, ktextwidgets, kwallet, kwidgetsaddons, kxmlgui, solid, libplasma, libkdegames, gzip, stockfish.
Required by (1): kde-gear-games.
Sources: knights-26.08.2.tar.xz (2.4 MiB). Every step kpkg takes applies to this port.
Install: script/chroot/exec.sh bash -c 'source script/phases/44_apps/phase.env && kpkg install knights'
build.sh:
cmake -S . -B build -G Ninja \
-D CMAKE_INSTALL_PREFIX=/usr \
-D KDE_INSTALL_LIBDIR=lib \
-D CMAKE_BUILD_TYPE=Release \
-D BUILD_TESTING=OFF \
-D KDE_INSTALL_USE_QT_SYS_PATHS=ON \
-D KF_SKIP_PO_PROCESSING=ON \
-D CMAKE_REQUIRE_FIND_PACKAGE_Qt6TextToSpeech=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).-D CMAKE_REQUIRE_FIND_PACKAGE_Qt6TextToSpeech=ON— Make Qt TextToSpeech a requirement. Upstream looks for it quietly, and without it the accessibility setting that speaks the opponent’s moves is compiled out with nothing said. It comes from qt6-qtspeech, which is independsand speaks through speech-dispatcher.-D CMAKE_DISABLE_FIND_PACKAGE_7Zip=ON— Compress the themes’ SVGs to SVGZ with gzip, never with 7-Zip. Upstream takes 7-Zip whenever it finds one, and 7zip is in the build root from41_systemon, so the tool would follow whatever happens to be installed. Refused, the build runsgzip -9 -n, which upstream then requires and which stores no file name or time stamp in the output; gzip is independs.
Programs: knights.
Directories: /usr/share/doc/HTML/en/knights, /usr/share/knights, /usr/share/licenses/knights.
The configure requires Plasma: the player clocks draw widgets/clock from the Plasma desktop theme through ksvg, and that theme is installed by libplasma. Both are 43_toolkits libraries, so Knights stays a 44_apps port.
Knights runs no engine of its own. Of the engines its default configuration names (GNU Chess, Crafty, Stockfish and Sjeng), stockfish is the one that is a port, and it is in depends for run time; the build does not look for it. Upstream’s default opponent is GNU Chess, which the new-game dialog then offers first and which fails to start, so /usr/share/kdos/xdg/knightsrc sets player1Program and player2Program in [Protocols] to Stockfish. The engine settings page marks each configured command as found or missing on $PATH.
A Free Internet Chess Server password is kept in the wallet through kwallet.
KF_SKIP_PO_PROCESSING stops only ki18n_install(): kdoctools_install() still builds the handbook in every translated language, and kpkg’s language rule removes /usr/share/doc/HTML/<lang>/ from the package.
The desktop entry is upstream’s org.kde.knights.desktop. KAboutData derives the window’s Wayland app id, org.kde.knights, from the component name and the apps.kde.org home page, so it is the entry’s file name and Plasma pairs the window with the entry without a StartupWMClass.