openkingdoms

LOW
maintainer DoubyCz 0 votes scanned 2026-09-18 21:28:57.026605
View on AUR
Why flagged

Uploaded within the last 14 days with 2 or fewer community votes — little peer review so far.

Triggered rules

Low Few votes, recently uploaded zero_votes_recent

Uploaded within the last 14 days with 2 or fewer community votes — little peer review so far.

PKGBUILD

1# Maintainer: Jiri Doubravsky (DoubyCz) <douby@douby.cz>
2#
3# OpenKingdoms - from-scratch open-source engine for Total Annihilation: Kingdoms
4# (Cavedog, 1999), written in C11. Native Linux build against the system SDL2,
5# so nothing is bundled. The engine ships no game content and never will: it
6# reads the original .hpi archives, which the user supplies from their own copy
7# (GOG Total Annihilation Commander Pack, or the original CDs).
8#
9# Point the engine at your copy with --game-dir, or export TAK_GAME_DIR.
10# The folder is remembered after the first run.
11#
12# This is the stable package, built from the latest released tag. For the
13# development version built from git HEAD, use openkingdoms-git.
14
15pkgname=openkingdoms
16pkgver=0.1.4
17pkgrel=1
18pkgdesc='Open-source engine for Total Annihilation: Kingdoms (1999). Requires you own the original game.'
19arch=('x86_64')
20url='https://github.com/OpenKingdoms/OpenKingdoms'
21license=('GPL-3.0-or-later')
22# 'sdl2' is deliberate rather than 'sdl2-compat': Arch currently satisfies it
23# with sdl2-compat (which provides sdl2=2.32.x), and naming the virtual package
24# keeps working if a real sdl2 ever returns.
25# ffmpeg: Bink playback (the main menu door clips and the cut scenes).
26depends=('sdl2' 'ffmpeg')
27makedepends=('git' 'cmake' 'ninja') # gcc/make come from base-devel
28conflicts=('openkingdoms-git')
29options=('!debug')
30install="${pkgname}.install"
31
32# Built from the tag rather than a source tarball on purpose: CMake stamps the
33# engine version from `git describe`, and without a .git directory the version
34# shown on the main menu would read "unknown" -- which is exactly what upstream's
35# bug template asks reporters to quote.
36_srcname=OpenKingdoms
37source=("${_srcname}::git+https://github.com/OpenKingdoms/OpenKingdoms.git#tag=v${pkgver}")
38sha256sums=('SKIP')
39
40build() {
41 cd "${srcdir}/${_srcname}"
42 # TAK_GAME_DIR is deliberately left empty: a package must not bake in one
43 # user's path. The engine asks for the folder on first run and remembers it.
44 cmake -B build -G Ninja \
45 -DCMAKE_BUILD_TYPE=Release \
46 -DCMAKE_INSTALL_PREFIX=/usr \
47 -DTAK_GAME_DIR=
48 cmake --build build
49}
50
51check() {
52 cd "${srcdir}/${_srcname}"
53 # Tests that load real game data carry the CTest label needs-data and are
54 # excluded here, the same way upstream CI does it: a build host has no game
55 # files and those cases would only skip (and a skip exits nonzero).
56 ctest --test-dir build --output-on-failure --label-exclude needs-data
57}
58
59package() {
60 cd "${srcdir}/${_srcname}"
61 DESTDIR="${pkgdir}" cmake --install build
62
63 # Upstream installs the binary as `tak-re`; add the name people know it by.
64 ln -s tak-re "${pkgdir}/usr/bin/openkingdoms"
65
66 install -Dm644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
67 install -Dm644 README.md "${pkgdir}/usr/share/doc/${pkgname}/README.md"
68 install -Dm644 docs/ASSETS.md "${pkgdir}/usr/share/doc/${pkgname}/ASSETS.md"
69
70 # No icon is shipped: the game's own icon lives in the original data, which
71 # is copyrighted and must not be redistributed. A stock category icon is used.
72 install -Dm644 /dev/stdin "${pkgdir}/usr/share/applications/openkingdoms.desktop" <<'EOF'
73[Desktop Entry]
74Type=Application
75Version=1.0
76Name=OpenKingdoms
77GenericName=Real-time strategy
78Comment=Engine for Total Annihilation: Kingdoms (needs your own copy of the game)
79Exec=openkingdoms
80Icon=applications-games
81Terminal=false
82Categories=Game;StrategyGame;
83Keywords=kingdoms;total;annihilation;rts;cavedog;
84EOF
85}
86

Scan history

Scanned at (UTC)SeverityRules
2026-09-18 21:28:57 Low 1

Report a package

Reports go to the AURWatch maintainer (one person) and are read by hand. No login required.

0 / 4000
Your suggestion