gnu: Further simplify package inputs.
[jackhill/guix/guix.git] / gnu / packages / games.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2013 John Darrington <jmd@gnu.org>
3 ;;; Copyright © 2013 Nikita Karetnikov <nikita@karetnikov.org>
4 ;;; Copyright © 2014, 2015 David Thompson <dthompson2@worcester.edu>
5 ;;; Copyright © 2014, 2015, 2016, 2017, 2018, 2019, 2020, 2021 Eric Bavier <bavier@posteo.net>
6 ;;; Copyright © 2014 Cyrill Schenkel <cyrill.schenkel@gmail.com>
7 ;;; Copyright © 2014 Sylvain Beucler <beuc@beuc.net>
8 ;;; Copyright © 2014, 2015, 2018, 2019, 2021 Ludovic Courtès <ludo@gnu.org>
9 ;;; Copyright © 2014, 2015, 2016 Sou Bunnbu <iyzsong@gmail.com>
10 ;;; Copyright © 2014, 2015, 2019 Mark H Weaver <mhw@netris.org>
11 ;;; Copyright © 2015, 2016 Andreas Enge <andreas@enge.fr>
12 ;;; Copyright © 2015 David Hashe <david.hashe@dhashe.com>
13 ;;; Copyright © 2015, 2017, 2018, 2021 Chris Lemmer Webber <cwebber@dustycloud.org>
14 ;;; Copyright © 2015, 2016, 2017, 2018, 2019, 2021 Ricardo Wurmus <rekado@elephly.net>
15 ;;; Copyright © 2015, 2016, 2017 Alex Kost <alezost@gmail.com>
16 ;;; Copyright © 2015 Paul van der Walt <paul@denknerd.org>
17 ;;; Copyright © 2016, 2017 Rodger Fox <thylakoid@openmailbox.org>
18 ;;; Copyright © 2016, 2017, 2018 Nikita <nikita@n0.is>
19 ;;; Copyright © 2016 Albin Söderqvist <albin@fripost.org>
20 ;;; Copyright © 2016, 2017, 2018, 2019, 2020 Kei Kebreau <kkebreau@posteo.net>
21 ;;; Copyright © 2016 Alex Griffin <a@ajgrf.com>
22 ;;; Copyright © 2016, 2017, 2018, 2019, 2020, 2021 Efraim Flashner <efraim@flashner.co.il>
23 ;;; Copyright © 2016 Jan Nieuwenhuizen <janneke@gnu.org>
24 ;;; Copyright © 2016 Steve Webber <webber.sl@gmail.com>
25 ;;; Copyright © 2017 Adonay "adfeno" Felipe Nogueira <https://libreplanet.org/wiki/User:Adfeno> <adfeno@hyperbola.info>
26 ;;; Copyright © 2017, 2018, 2020 Arun Isaac <arunisaac@systemreboot.net>
27 ;;; Copyright © 2017–2021 Tobias Geerinckx-Rice <me@tobias.gr>
28 ;;; Copyright © 2017, 2019 nee <nee-git@hidamari.blue>
29 ;;; Copyright © 2017 Clément Lassieur <clement@lassieur.org>
30 ;;; Copyright © 2017, 2019, 2020 Marius Bakke <mbakke@fastmail.com>
31 ;;; Copyright © 2017, 2018 Rutger Helling <rhelling@mykolab.com>
32 ;;; Copyright © 2017 Roel Janssen <roel@gnu.org>
33 ;;; Copyright © 2017, 2018, 2019, 2020, 2021 Nicolas Goaziou <mail@nicolasgoaziou.fr>
34 ;;; Copyright © 2018 okapi <okapi@firemail.cc>
35 ;;; Copyright © 2018 Tim Gesthuizen <tim.gesthuizen@yahoo.de>
36 ;;; Copyright © 2018 Madalin Ionel-Patrascu <madalinionel.patrascu@mdc-berlin.de>
37 ;;; Copyright © 2018 Benjamin Slade <slade@jnanam.net>
38 ;;; Copyright © 2018 Alex Vong <alexvong1995@gmail.com>
39 ;;; Copyright © 2019, 2020 Pierre Neidhardt <mail@ambrevar.xyz>
40 ;;; Copyright © 2019, 2020 Oleg Pykhalov <go.wigust@gmail.com>
41 ;;; Copyright © 2019 Pierre Langlois <pierre.langlois@gmx.com>
42 ;;; Copyright © 2019 Julien Lepiller <julien@lepiller.eu>
43 ;;; Copyright © 2019, 2020 Jesse Gibbons <jgibbons2357+guix@gmail.com>
44 ;;; Copyright © 2019 Dan Frumin <dfrumin@cs.ru.nl>
45 ;;; Copyright © 2019, 2020, 2021 Guillaume Le Vaillant <glv@posteo.net>
46 ;;; Copyright © 2019, 2020 Timotej Lazar <timotej.lazar@araneo.si>
47 ;;; Copyright © 2019 Josh Holland <josh@inv.alid.pw>
48 ;;; Copyright © 2019 Pkill -9 <pkill9@runbox.com>
49 ;;; Copyright © 2017, 2019 Hartmut Goebel <h.goebel@crazy-compilers.com>
50 ;;; Copyright © 2020 Alberto Eleuterio Flores Guerrero <barbanegra+guix@posteo.mx>
51 ;;; Copyright © 2020 Naga Malleswari <nagamalli@riseup.net>
52 ;;; Copyright © 2020 Vitaliy Shatrov <D0dyBo0D0dyBo0@protonmail.com>
53 ;;; Copyright © 2020 Jack Hill <jackhill@jackhill.us>
54 ;;; Copyright © 2020 Vincent Legoll <vincent.legoll@gmail.com>
55 ;;; Copyright © 2020, 2021 Michael Rohleder <mike@rohleder.de>
56 ;;; Copyright © 2020 Trevor Hass <thass@okstate.edu>
57 ;;; Copyright © 2020, 2021 Liliana Marie Prikler <liliana.prikler@gmail.com>
58 ;;; Copyright © 2020 Lu hux <luhux@outlook.com>
59 ;;; Copyright © 2020 Tomás Ortín Fernández <tomasortin@mailbox.org>
60 ;;; Copyright © 2021 Olivier Rojon <o.rojon@posteo.net>
61 ;;; Copyright © 2021 Stefan Reichör <stefan@xsteve.at>
62 ;;; Copyright © 2021 Greg Hogan <code@greghogan.com>
63 ;;; Copyright © 2021 David Pflug <david@pflug.io>
64 ;;; Copyright © 2021 Felix Gruber <felgru@posteo.net>
65 ;;; Copyright © 2021 Solene Rapenne <solene@perso.pw>
66 ;;; Copyright © 2021 Noisytoot <noisytoot@disroot.org>
67 ;;; Copyright © 2021 Petr Hodina <phodina@protonmail.com>
68 ;;; Copyright © 2021 Brendan Tildesley <mail@brendan.scot>
69 ;;; Copyright © 2021 Christopher Baines <mail@cbaines.net>
70 ;;;
71 ;;; This file is part of GNU Guix.
72 ;;;
73 ;;; GNU Guix is free software; you can redistribute it and/or modify it
74 ;;; under the terms of the GNU General Public License as published by
75 ;;; the Free Software Foundation; either version 3 of the License, or (at
76 ;;; your option) any later version.
77 ;;;
78 ;;; GNU Guix is distributed in the hope that it will be useful, but
79 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
80 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
81 ;;; GNU General Public License for more details.
82 ;;;
83 ;;; You should have received a copy of the GNU General Public License
84 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
85
86 (define-module (gnu packages games)
87 #:use-module (ice-9 match)
88 #:use-module ((guix licenses) #:prefix license:)
89 #:use-module (guix utils)
90 #:use-module (guix packages)
91 #:use-module (guix download)
92 #:use-module (guix git-download)
93 #:use-module (guix svn-download)
94 #:use-module (guix gexp)
95 #:use-module (gnu packages)
96 #:use-module (gnu packages adns)
97 #:use-module (gnu packages algebra)
98 #:use-module (gnu packages autotools)
99 #:use-module (gnu packages backup)
100 #:use-module (gnu packages base)
101 #:use-module (gnu packages build-tools)
102 #:use-module (gnu packages admin)
103 #:use-module (gnu packages audio)
104 #:use-module (gnu packages avahi)
105 #:use-module (gnu packages assembly)
106 #:use-module (gnu packages bash)
107 #:use-module (gnu packages bison)
108 #:use-module (gnu packages boost)
109 #:use-module (gnu packages check)
110 #:use-module (gnu packages cmake)
111 #:use-module (gnu packages compression)
112 #:use-module (gnu packages code)
113 #:use-module (gnu packages cpp)
114 #:use-module (gnu packages curl)
115 #:use-module (gnu packages crypto)
116 #:use-module (gnu packages cyrus-sasl)
117 #:use-module (gnu packages documentation)
118 #:use-module (gnu packages docbook)
119 #:use-module (gnu packages emulators)
120 #:use-module (gnu packages flex)
121 #:use-module (gnu packages fltk)
122 #:use-module (gnu packages fonts)
123 #:use-module (gnu packages fontutils)
124 #:use-module (gnu packages freedesktop)
125 #:use-module (gnu packages fribidi)
126 #:use-module (gnu packages game-development)
127 #:use-module (gnu packages gcc)
128 #:use-module (gnu packages gettext)
129 #:use-module (gnu packages ghostscript)
130 #:use-module (gnu packages gimp)
131 #:use-module (gnu packages gl)
132 #:use-module (gnu packages glib)
133 #:use-module (gnu packages gnome)
134 #:use-module (gnu packages gnu-doc)
135 #:use-module (gnu packages gnupg)
136 #:use-module (gnu packages gnuzilla)
137 #:use-module (gnu packages golang)
138 #:use-module (gnu packages gperf)
139 #:use-module (gnu packages graphics)
140 #:use-module (gnu packages gsasl)
141 #:use-module (gnu packages gstreamer)
142 #:use-module (gnu packages gtk)
143 #:use-module (gnu packages guile)
144 #:use-module (gnu packages haskell)
145 #:use-module (gnu packages haskell-crypto)
146 #:use-module (gnu packages haskell-xyz)
147 #:use-module (gnu packages icu4c)
148 #:use-module (gnu packages image)
149 #:use-module (gnu packages imagemagick)
150 #:use-module (gnu packages javascript)
151 #:use-module (gnu packages kde)
152 #:use-module (gnu packages kde-frameworks)
153 #:use-module (gnu packages less)
154 #:use-module (gnu packages libcanberra)
155 #:use-module (gnu packages libedit)
156 #:use-module (gnu packages libidn)
157 #:use-module (gnu packages libunwind)
158 #:use-module (gnu packages linux)
159 #:use-module (gnu packages llvm)
160 #:use-module (gnu packages lua)
161 #:use-module (gnu packages man)
162 #:use-module (gnu packages maths)
163 #:use-module (gnu packages messaging)
164 #:use-module (gnu packages mp3)
165 #:use-module (gnu packages music)
166 #:use-module (gnu packages multiprecision)
167 #:use-module (gnu packages ncurses)
168 #:use-module (gnu packages netpbm)
169 #:use-module (gnu packages networking)
170 #:use-module (gnu packages ocaml)
171 #:use-module (gnu packages opencl)
172 #:use-module (gnu packages pcre)
173 #:use-module (gnu packages perl)
174 #:use-module (gnu packages perl-check)
175 #:use-module (gnu packages perl-compression)
176 #:use-module (gnu packages pkg-config)
177 #:use-module (gnu packages pretty-print)
178 #:use-module (gnu packages protobuf)
179 #:use-module (gnu packages pulseaudio)
180 #:use-module (gnu packages python)
181 #:use-module (gnu packages python-web)
182 #:use-module (gnu packages python-xyz)
183 #:use-module (gnu packages qt)
184 #:use-module (gnu packages readline)
185 #:use-module (gnu packages ruby)
186 #:use-module (gnu packages shells)
187 #:use-module (gnu packages sdl)
188 #:use-module (gnu packages serialization)
189 #:use-module (gnu packages sqlite)
190 #:use-module (gnu packages squirrel)
191 #:use-module (gnu packages swig)
192 #:use-module (gnu packages tcl)
193 #:use-module (gnu packages terminals)
194 #:use-module (gnu packages texinfo)
195 #:use-module (gnu packages textutils)
196 #:use-module (gnu packages tls)
197 #:use-module (gnu packages upnp)
198 #:use-module (gnu packages video)
199 #:use-module (gnu packages vulkan)
200 #:use-module (gnu packages web)
201 #:use-module (gnu packages wget)
202 #:use-module (gnu packages wxwidgets)
203 #:use-module (gnu packages xdisorg)
204 #:use-module (gnu packages xorg)
205 #:use-module (gnu packages xiph)
206 #:use-module (gnu packages xml)
207 #:use-module (guix build-system copy)
208 #:use-module (guix build-system cmake)
209 #:use-module (guix build-system glib-or-gtk)
210 #:use-module (guix build-system gnu)
211 #:use-module (guix build-system go)
212 #:use-module (guix build-system meson)
213 #:use-module (guix build-system perl)
214 #:use-module (guix build-system python)
215 #:use-module (guix build-system qt)
216 #:use-module (guix build-system scons)
217 #:use-module (guix build-system trivial)
218 #:use-module ((srfi srfi-1) #:hide (zip))
219 #:use-module (srfi srfi-26))
220
221 (define-public abe
222 (package
223 (name "abe")
224 (version "1.1")
225 (source
226 (origin
227 (method url-fetch)
228 (uri (string-append "mirror://sourceforge/abe/abe/abe-" version
229 "/abe-" version ".tar.gz"))
230 (sha256
231 (base32 "1xvpnq1y6y48fn3pvn2lk0h1ilmalv7nb7awpid1g4jcq1sfmi6z"))))
232 (build-system gnu-build-system)
233 (arguments
234 `(#:configure-flags
235 (list (string-append "--with-data-dir="
236 (assoc-ref %outputs "out")
237 "/share/abe"))
238 #:phases
239 (modify-phases %standard-phases
240 (replace 'bootstrap
241 (lambda _ (invoke "sh" "autogen.sh")))
242 (add-before 'build 'set-SDL
243 ;; Set correct environment for SDL.
244 (lambda* (#:key inputs #:allow-other-keys)
245 (setenv "CPATH"
246 (string-append
247 (assoc-ref inputs "sdl") "/include/SDL:"
248 (or (getenv "CPATH") "")))
249 #t))
250 (add-after 'install 'finalize-install
251 (lambda* (#:key outputs #:allow-other-keys)
252 (let ((share (string-append (assoc-ref outputs "out") "/share")))
253 ;; Installation script does not copy game data files.
254 (let ((data (string-append share "/abe")))
255 (for-each (lambda (dir)
256 (let ((target (string-append data "/" dir)))
257 (mkdir-p target)
258 (copy-recursively dir target)))
259 '("images" "maps" "sounds")))
260 ;; Create desktop file.
261 (let ((apps (string-append share "/applications")))
262 (mkdir-p apps)
263 (make-desktop-entry-file
264 (string-append apps "/abe.desktop")
265 #:name "Abe's Amazing Adventure"
266 #:exec ,name
267 #:categories '("AdventureGame" "Game")
268 #:keywords
269 '("side-scrolling" "adventure" "pyramid" "singleplayer")
270 #:comment
271 '(("de" "Ein sich seitwärts bewegendes Abenteuerspiel")
272 (#f "Side-scrolling game")))))
273 #t)))))
274 (native-inputs
275 (list autoconf automake))
276 (inputs
277 `(("libxi" ,libxi)
278 ("libxmu" ,libxmu)
279 ("libxt" ,libxt)
280 ("sdl" ,(sdl-union (list sdl sdl-mixer)))))
281 (home-page "http://abe.sourceforge.net")
282 (synopsis "Scrolling, platform-jumping, ancient pyramid exploring game")
283 (description
284 "Abe's Amazing Adventure is a scrolling,
285 platform-jumping, key-collecting, ancient pyramid exploring game, vaguely in
286 the style of similar games for the Commodore+4.")
287 (license license:gpl2+)))
288
289 ;; Data package for adanaxisgpl.
290 (define adanaxis-mush
291 (let ((version "1.1.0"))
292 (origin
293 (method url-fetch)
294 (uri (string-append "http://www.mushware.com/files/adanaxis-mush-"
295 version ".tar.gz"))
296 (sha256
297 (base32 "0mk9ibis5nkdcalcg1lkgnsdxxbw4g5w2i3icjzy667hqirsng03")))))
298
299 (define-public adanaxisgpl
300 (package
301 (name "adanaxisgpl")
302 (version "1.2.5")
303 (source
304 (origin
305 (method url-fetch)
306 (uri (string-append "http://www.mushware.com/files/adanaxisgpl-"
307 version ".tar.gz"))
308 (sha256
309 (base32 "0jkn637jaabvlhd6hpvzb57vvjph94l6fbf7qxbjlw9zpr19dw1f"))
310 (modules '((guix build utils)))
311 (snippet
312 '(begin
313 ;; Necessary for building with gcc >=4.7.
314 (substitute* "src/Mushcore/MushcoreSingleton.h"
315 (("SingletonPtrSet\\(new SingletonType\\);")
316 "MushcoreSingleton::SingletonPtrSet(new SingletonType);"))
317 ;; Avoid an "invalid conversion from const char* to char*" error.
318 (substitute* "src/Platform/X11/PlatformMiscUtils.cpp"
319 (("char \\*end, \\*result;")
320 (string-append "const char *end;"
321 "\n"
322 "char *result;")))
323 #t))))
324 (build-system gnu-build-system)
325 (arguments
326 `(#:tests? #f ; no check target
327 #:phases
328 (modify-phases %standard-phases
329 (add-after 'install 'install-data
330 (lambda* (#:key inputs outputs #:allow-other-keys)
331 (let ((data (assoc-ref inputs "adanaxis-mush"))
332 (share (string-append (assoc-ref outputs "out")
333 "/share/" ,name "-" ,version)))
334 (mkdir-p share)
335 (invoke "tar" "xvf" data "-C" share)))))))
336 (native-inputs
337 `(("adanaxis-mush" ,adanaxis-mush))) ; game data
338 (inputs
339 `(("expat" ,expat)
340 ("freeglut" ,freeglut)
341 ("glu" ,glu)
342 ("libjpeg" ,libjpeg-turbo)
343 ("libogg" ,libogg)
344 ("libtiff" ,libtiff)
345 ("libvorbis" ,libvorbis)
346 ("libx11" ,libx11)
347 ("libxext" ,libxext)
348 ("pcre" ,pcre)
349 ("sdl" ,sdl)
350 ("sdl-mixer" ,sdl-mixer)))
351 (home-page "https://www.mushware.com")
352 (synopsis "Action game in four spatial dimensions")
353 (description
354 "Adanaxis is a fast-moving first person shooter set in deep space, where
355 the fundamentals of space itself are changed. By adding another dimension to
356 space this game provides an environment with movement in four directions and
357 six planes of rotation. Initially the game explains the 4D control system via
358 a graphical sequence, before moving on to 30 levels of gameplay with numerous
359 enemy, ally, weapon and mission types. Features include simulated 4D texturing,
360 mouse and joystick control, and original music.")
361 (license license:gpl2)))
362
363 (define-public alex4
364 (package
365 (name "alex4")
366 (version "1.2.1")
367 (source
368 (origin
369 (method git-fetch)
370 (uri (git-reference
371 (url "https://github.com/carstene1ns/alex4")
372 (commit version)))
373 (file-name (git-file-name name version))
374 (sha256
375 (base32 "098wy72mh4lsvq3gm0rhamjssf9l1hp6hhkpzrv7klpb97cwwc3h"))))
376 (build-system gnu-build-system)
377 (arguments
378 `(#:tests? #f ; no check target
379 #:make-flags
380 (list "CC=gcc"
381 "CFLAGS=-D_FILE_OFFSET_BITS=64"
382 (string-append "PREFIX=" (assoc-ref %outputs "out")))
383 #:phases
384 (modify-phases %standard-phases
385 (delete 'configure) ; no configure script
386 (add-after 'install 'install-data
387 (lambda* (#:key outputs #:allow-other-keys)
388 (let ((share (string-append (assoc-ref outputs "out")
389 "/share/" ,name)))
390 (install-file "alex4.ini" share)
391 #t))))))
392 (inputs
393 `(("allegro" ,allegro-4)
394 ("dumb" ,dumb-allegro4)))
395 (home-page "http://allegator.sourceforge.net/")
396 (synopsis "Retro platform game")
397 (description
398 "Guide Alex the Allegator through the jungle in order to save his
399 girlfriend Lola from evil humans who want to make a pair of shoes out of her.
400 Plenty of classic platforming in four nice colors guaranteed!
401
402 The game includes a built-in editor so you can design and share your own maps.")
403 (license license:gpl2+)))
404
405 (define-public armagetronad
406 (package
407 (name "armagetronad")
408 (version "0.2.9.1.0")
409 (source (origin
410 (method url-fetch)
411 (uri (string-append "mirror://sourceforge/armagetronad/stable/"
412 version "/armagetronad-" version ".tbz"))
413 (sha256
414 (base32
415 "18gn4sg4j5sw38ngb90sl50raliplrsgjcvy8fjwry733k0cgdjr"))))
416 (build-system gnu-build-system)
417 (native-inputs
418 (list pkg-config))
419 (inputs
420 (list libxml2
421 sdl
422 sdl-image
423 freeglut
424 libpng
425 libjpeg-turbo))
426 (home-page "http://www.armagetronad.org")
427 (synopsis "Tron clone in 3D")
428 (description "Armagetron Advanced is a multiplayer game in 3d that
429 attempts to emulate and expand on the lightcycle sequence from the movie Tron.
430 It's an old school arcade game slung into the 21st century. Highlights
431 include a customizable playing arena, HUD, unique graphics, and AI bots. For
432 the more advanced player there are new game modes and a wide variety of
433 physics settings to tweak as well.")
434 (license license:gpl2+)))
435
436 (define-public astromenace
437 (package
438 (name "astromenace")
439 (version "1.4.1")
440 (source
441 (origin
442 (method git-fetch)
443 (uri (git-reference
444 (url "https://github.com/viewizard/astromenace")
445 (commit (string-append "v" version))))
446 (file-name (git-file-name name version))
447 (sha256
448 (base32 "1ad6l887jxqv8xspwc2rvy8ym9sdlmkqdqhsh0pi076kjarxsyws"))))
449 (build-system cmake-build-system)
450 (arguments
451 `(#:tests? #f ;no test
452 #:configure-flags (list (string-append "-DDATADIR="
453 (assoc-ref %outputs "out")
454 "/share/astromenace"))
455 #:phases
456 (modify-phases %standard-phases
457 (replace 'install
458 ;; Upstream provides no install phase.
459 (lambda* (#:key inputs outputs #:allow-other-keys)
460 (let* ((out (assoc-ref outputs "out"))
461 (bin (string-append out "/bin"))
462 (share (string-append out "/share"))
463 (apps (string-append share "/applications"))
464 (data (string-append share "/astromenace"))
465 (icons (string-append share "/icons/hicolor/64x64/apps")))
466 (install-file "astromenace" bin)
467 (install-file "gamedata.vfs" data)
468 (let ((source (assoc-ref inputs "source")))
469 (with-directory-excursion (string-append source "/share")
470 (install-file "astromenace.desktop" apps)
471 (mkdir-p icons)
472 (copy-file "astromenace_64.png"
473 (string-append icons "/astromenace.png")))))
474 #t)))))
475 (inputs
476 (list freealut
477 freetype
478 glu
479 libogg
480 libvorbis
481 openal
482 sdl2))
483 (home-page "https://www.viewizard.com/")
484 (synopsis "3D space shooter with spaceship upgrade possibilities")
485 (description
486 "Space is a vast area, an unbounded territory where it seems there is
487 a room for everybody, but reversal of fortune put things differently. The
488 hordes of hostile creatures crawled out from the dark corners of the universe,
489 craving to conquer your homeland. Their force is compelling, their legions
490 are interminable. However, humans didn't give up without a final showdown and
491 put their best pilot to fight back. These malicious invaders chose the wrong
492 galaxy to conquer and you are to prove it! Go ahead and make alien aggressors
493 regret their insolence.")
494 ;; Game is released under GPL3+ terms. Artwork is subject to CC
495 ;; BY-SA 4.0, and fonts to OFL1.1.
496 (license (list license:gpl3+ license:cc-by-sa4.0 license:silofl1.1))))
497
498 (define-public bastet
499 (package
500 (name "bastet")
501 (version "0.43.2")
502 (source
503 (origin
504 (method git-fetch)
505 (uri (git-reference
506 (url "https://github.com/fph/bastet")
507 (commit version)))
508 (file-name (git-file-name name version))
509 (sha256
510 (base32 "09kamxapm9jw9przpsgjfg33n9k94bccv65w95dakj0br33a75wn"))
511 (patches
512 (search-patches "bastet-change-source-of-unordered_set.patch"))))
513 (build-system gnu-build-system)
514 (arguments
515 `(#:make-flags
516 (list (string-append "CXXFLAGS=-I"
517 (assoc-ref %build-inputs "boost") "/include"))
518 #:phases
519 (modify-phases %standard-phases
520 (delete 'configure) ; no configure script
521 (replace 'check
522 ;; The 'Test' target builds the tests, but doesn't actually run them.
523 (lambda* (#:key make-flags #:allow-other-keys)
524 (apply invoke "make" "Test" make-flags)
525 (setenv "HOME" ".")
526 (invoke "./Test")))
527 (replace 'install
528 (lambda* (#:key outputs #:allow-other-keys)
529 (let* ((out (assoc-ref outputs "out"))
530 (share (string-append out "/share"))
531 (hicolor (string-append share "/icons/hicolor")))
532 (install-file "bastet"
533 (string-append out "/bin"))
534
535 (install-file "bastet.desktop"
536 (string-append share "/applications"))
537 (install-file "bastet.svg"
538 (string-append hicolor "/scalable/apps"))
539
540 (install-file "bastet.appdata.xml"
541 (string-append share "/appdata"))
542
543 (install-file "bastet.6"
544 (string-append out "/share/man/man6"))
545 #t))))))
546 (native-inputs
547 (list hicolor-icon-theme))
548 (inputs
549 (list boost ncurses))
550 (home-page "https://fph.altervista.org/prog/bastet.html")
551 (synopsis "Antagonistic Tetris-style falling brick game for text terminals")
552 (description
553 "Bastet (short for Bastard Tetris) is a simple ncurses-based falling brick
554 game. Unlike normal Tetris, Bastet does not choose the next brick at random.
555 Instead, it uses a special algorithm to choose the worst brick possible.
556
557 Playing bastet can be a painful experience, especially if you usually make
558 canyons and wait for the long I-shaped block to clear four rows at a time.")
559 (license license:gpl3+)))
560
561 (define-public tetrinet
562 (package
563 (name "tetrinet")
564 (version "0.11")
565 (source
566 (origin
567 (method url-fetch)
568 (uri (string-append
569 "http://tetrinet.or.cz/download/tetrinet-" version
570 ".tar.bz2"))
571 (sha256
572 (base32
573 "0b4pddqz6is1771qmvcj8qqlr4in2djdbkk13agvp9yhfah2v8x7"))))
574 (build-system gnu-build-system)
575 (inputs
576 (list ncurses))
577 (arguments
578 `(#:tests? #f ;no tests
579 #:make-flags '("CC=gcc")
580 #:phases
581 (modify-phases %standard-phases
582 (delete 'configure) ;no configure script
583 (add-after 'unpack 'fix-install-dir
584 (lambda* (#:key outputs #:allow-other-keys)
585 (let ((out (assoc-ref outputs "out")))
586 (mkdir-p (string-append out "/bin"))
587 (substitute* "Makefile"
588 (("/usr/games") (string-append out "/bin"))))))
589 (add-after 'install 'install-documentation
590 (lambda* (#:key outputs #:allow-other-keys)
591 (let* ((out (assoc-ref outputs "out"))
592 (doc (string-append out "/share/doc/" ,name "-" ,version)))
593 (for-each (lambda (file)
594 (install-file file doc))
595 (list "README" "tetrinet.txt"))))))))
596 (home-page "http://tetrinet.or.cz")
597 (synopsis "Terminal-based multiplayer Tetris clone")
598 (description "Tetrinet is a multiplayer Tetris-like game with powerups and
599 attacks you can use on opponents.")
600 (license license:public-domain)))
601
602 (define-public vitetris
603 (package
604 (name "vitetris")
605 (version "0.59.1")
606 (source
607 (origin
608 (method git-fetch)
609 (uri (git-reference
610 (url "https://github.com/vicgeralds/vitetris")
611 (commit (string-append "v" version))))
612 (sha256
613 (base32 "1ah1c5g7abksif0n8v5rb7r4pn2az20c3mkp4ak13vgs23ddmds5"))
614 (file-name (git-file-name name version))))
615 (build-system gnu-build-system)
616 (arguments
617 `(#:tests? #f ;no test
618 #:make-flags
619 (list ,(string-append "CC=" (cc-for-target))
620 (string-append "DESTDIR=" (assoc-ref %outputs "out")))
621 #:phases
622 (modify-phases %standard-phases
623 (replace 'configure
624 (lambda _
625 ;; the non standard configure script does not accept
626 ;; standard parameters -> invoke configure by hand
627 (invoke "./configure" "prefix=")
628 ;; src/src-conf.mk must be writable for the build step
629 (make-file-writable "src/src-conf.mk"))))))
630 (home-page "http://victornils.net/tetris/")
631 (synopsis "Terminal-based Tetris clone")
632 (description "Vitetris is a classic multiplayer Tetris clone for the
633 terminal.")
634 (license license:bsd-2)))
635
636 (define-public blobwars
637 (package
638 (name "blobwars")
639 (version "2.00")
640 (source
641 (origin
642 (method url-fetch)
643 (uri (string-append "mirror://sourceforge/blobwars/"
644 "blobwars-" version ".tar.gz"))
645 (sha256
646 (base32 "16aagvkx6azf75gm5kaa94bh5npydvhqp3fvdqyfsanzdjgjf1n4"))))
647 (build-system gnu-build-system)
648 (arguments
649 `(#:tests? #f ;no test
650 #:make-flags
651 (let ((out (assoc-ref %outputs "out")))
652 (list (string-append "PREFIX=" out)
653 (string-append "BINDIR=" out "/bin/")
654 "USEPAK=1"
655 "RELEASE=1"))
656 #:phases
657 (modify-phases %standard-phases
658 (add-after 'unpack 'werror-begone
659 (lambda _
660 (substitute* "Makefile" (("-Werror") ""))
661 #t))
662 (delete 'configure)))) ;no configure script
663 (native-inputs
664 `(("gettext" ,gettext-minimal)
665 ("pkg-config" ,pkg-config)))
666 (inputs
667 `(("hicolor-icon-theme" ,hicolor-icon-theme)
668 ("sdl" ,(sdl-union (list sdl2
669 sdl2-image
670 sdl2-mixer
671 sdl2-ttf
672 sdl2-net)))))
673 (home-page "https://sourceforge.net/projects/blobwars/")
674 (synopsis "Platform action game featuring a blob with a lot of weapons")
675 (description "Blobwars: Metal Blob Solid is a 2D platform game, the first
676 in the Blobwars series. You take on the role of a fearless Blob agent. Your
677 mission is to infiltrate various enemy bases and rescue as many MIAs as
678 possible, while battling many vicious aliens.")
679 (license (list license:gpl2 ; For code and graphics
680 license:cc0 ; Music and sounds have specific licenses
681 license:cc-by3.0 ; see /doc/readme
682 license:cc-by-sa3.0
683 license:lgpl2.1+
684 license:bsd-2))))
685
686 (define-public bsd-games
687 (package
688 (name "bsd-games")
689 (version "2.17.0")
690 (source
691 (origin
692 (method url-fetch)
693 (uri "https://ibiblio.org/pub/linux/games/bsd-games-2.17.tar.gz")
694 (sha256
695 (base32 "0q7zdyyfvn15y0w4g54kq3gza89h61py727m8slmw73cxx594vq6"))
696 (patches
697 (search-patches
698 ;; thanks Arch, and Debian
699 "bsd-games-2.17-64bit.patch"
700 "bsd-games-bad-ntohl-cast.patch"
701 "bsd-games-gamescreen.h.patch"
702 "bsd-games-getline.patch"
703 "bsd-games-null-check.patch"
704 "bsd-games-number.c-and-test.patch"
705 "bsd-games-stdio.h.patch"
706 "bsd-games-prevent-name-collisions.patch"
707 ;; Guix customizations
708 "bsd-games-add-configure-config.patch"
709 "bsd-games-dont-install-empty-files.patch"
710 "bsd-games-add-wrapper.patch"))))
711 (build-system gnu-build-system)
712 (native-inputs
713 (list flex bison))
714 (inputs
715 `(("curses" ,ncurses)
716 ("pager" ,less)
717 ("miscfiles" ,miscfiles)
718 ("openssl" ,openssl))) ;used only by 'factor'
719 (arguments
720 `(#:phases
721 (modify-phases %standard-phases
722 (replace 'configure
723 (lambda* (#:key outputs inputs #:allow-other-keys)
724 (let* ((out (assoc-ref outputs "out"))
725 (bin (string-append out "/bin"))
726 (doc (string-append out "/share/doc/bsd-games-" ,version))
727 (man (string-append out "/share/man"))
728 (word-list (search-input-file inputs "/share/web2"))
729 (static-data (string-append out "/share/games/bsd-games"))
730 ;; Not a "./" because of substitute* in 'patch-install
731 ;; below. The .// allow us not to mess with the games'
732 ;; code any further: we just use a wrapper script that
733 ;; cd's to a BSD_GAMES_DIR. :]
734 (save-files ".//"))
735 (substitute* "configure"
736 (("/usr/share/man") man)
737 (("/usr/share/doc/bsd-games") doc)
738 (("/usr/share/[^\n/]*") static-data)
739 (("/var/games") save-files)
740 (("/usr/bin/less") (which "less"))
741 (("(/usr/bin|/usr/games)") bin))
742 (substitute* "config.params" (("WORD_LIST") word-list))
743 (substitute* "wrapper" (("STATIC_DATA") static-data))
744 (invoke "./configure"))
745 #t))
746 (add-before 'install 'patch-install
747 ;; Some games need a writable directory containing pre-maded files.
748 ;; The files get installed to the Store. Then the wrapper kicks in.
749 (lambda* (#:key outputs #:allow-other-keys)
750 (let* ((out (assoc-ref outputs "out"))
751 (static-data (string-append out "/share/games/bsd-games"))
752 (save-files ".//"))
753 (substitute* "Makeconfig" ((save-files) static-data)))
754 #t))
755 (add-after 'install 'install-documents
756 (lambda* (#:key outputs #:allow-other-keys)
757 (let* ((out (assoc-ref outputs "out"))
758 (doc (string-append out "/share/doc/bsd-games-" ,version)))
759 (rename-file "phantasia/COPYRIGHT" "phantasia-COPYRIGHT")
760 (for-each
761 (lambda(file) (install-file file doc))
762 '("AUTHORS" "BUGS" "README" "SECURITY" "THANKS"
763 "phantasia-COPYRIGHT")))
764 #t)))))
765 (home-page "https://github.com/vattam/BSDGames")
766 (synopsis "Collection of the old text-based games and amusements")
767 (description
768 "These are the BSD games. See the fortune-mod package for fortunes.
769
770 Action: atc (keep the airplanes safe), hack (explore the dangerous Dungeon),
771 hunt (kill the others for the Pair of Boots, multi-player only), robots (avoid
772 the evil robots), sail (game of naval warfare with wooden ships), snake (steal
773 the $$ from the cave, anger the snake, and get out alive), tetris (game of
774 lining up the falling bricks of different shapes), and worm (eat, grow big,
775 and neither bite your tail, nor ram the wall).
776
777 Amusements: banner (prints a large banner), bcd & morse & ppt (print a punch
778 card, or paper tape, or Morse codes), caesar & rot13 (ciphers and deciphers
779 the input), factor (factorizes a number), number (translates numbers into
780 text), pig (translates from English to Pig Latin), pom (should print the
781 Moon's phase), primes (generates primes), rain & worms (plays an screen-saver
782 in terminal), random (prints randomly chosen lines from files, or returns a
783 random exit-code), and wtf (explains what do some acronyms mean).
784
785 Board: backgammon (lead the men out of board faster than the friend do),
786 boggle (find the words in the square of letters), dab (game of dots and
787 boxes), gomoku (game of five in a row), hangman (guess a word before man is
788 hanged), and monop (game of monopoly, hot-seat only). Also the card-games:
789 canfield, cribbage, fish (juniors game), and mille.
790
791 Quests: adventure (search for treasures with the help of wizard),
792 battlestar (explore the world around, starting from dying spaceship),
793 phantasia (role-play as an rogue), trek (hunt the Klingons, and save the
794 Federation), and wump (hunt the big smelly Wumpus in a dark cave).
795
796 Quizzes: arithmetic and quiz.")
797 ;; "Auxiliary and data files, distributed with the games in NetBSD, but
798 ;; not bearing copyright notices, probably fall under the terms of the UCB
799 ;; or NetBSD copyrights and licences. The file "fortune/Notes" contains a
800 ;; warning in regard to the fortune databases."
801 (license (list
802 ;; Most games. Files: countmail/countmail.6, dab/dab.6,
803 ;; lib/strlcpy.c, wargames/wargames.6
804 license:bsd-3
805 ;; dab and hunt. Files: adventure/extern.h,
806 ;; backgammon/backgammon/backlocal.h, caesar/rot13.in,
807 ;; countmail/countmail, dm/utmpentry.c, dm/utmpentry.h,
808 ;; hack/extern.h, robots/auto.c, sail/display.h,
809 ;; sail/restart.h, wargames/wargames
810 license:bsd-4
811 ;; wtf (the game)
812 license:public-domain
813 ;; phantasia (all but phantasia/pathnames.h.in, which is bsd-3)
814 (license:fsf-free "file:///phantasia/COPYRIGHT")))))
815
816
817 (define-public bzflag
818 (package
819 (name "bzflag")
820 (version "2.4.22")
821 (source
822 (origin
823 (method url-fetch)
824 (uri (string-append "https://download.bzflag.org/bzflag/source/"
825 version "/bzflag-" version ".tar.bz2"))
826 (sha256
827 (base32 "0kba0011nswc2csqlzkd7bas307zm5813zlnby5vsmxn08rnar4y"))))
828 (build-system gnu-build-system)
829 (arguments
830 `(#:phases
831 (modify-phases %standard-phases
832 (add-after 'install 'install-desktop-file-and-icons
833 (lambda* (#:key outputs #:allow-other-keys)
834 (let* ((share (string-append (assoc-ref outputs "out") "/share"))
835 (data (string-append share "/bzflag"))
836 (hicolor (string-append share "/icons/hicolor"))
837 (applications (string-append share "/applications")))
838 ;; Move desktop file.
839 (install-file (string-append data "/bzflag.desktop")
840 applications)
841 ;; Install icons.
842 (for-each (lambda (size)
843 (let* ((dim (string-append size "x" size))
844 (dir (string-append hicolor "/" dim "/apps")))
845 (mkdir-p dir)
846 (copy-file
847 (string-append data "/bzflag-" dim ".png")
848 (string-append dir "/bzflag.png"))))
849 '("48" "256")))
850 #t)))))
851 (native-inputs
852 (list pkg-config))
853 (inputs
854 (list c-ares
855 curl
856 glew
857 glu
858 sdl2
859 zlib))
860 (home-page "https://www.bzflag.org/")
861 (synopsis "3D first person tank battle game")
862 (description
863 "BZFlag is a 3D multi-player multiplatform tank battle game that
864 allows users to play against each other in a network environment.
865 There are five teams: red, green, blue, purple and rogue (rogue tanks
866 are black). Destroying a player on another team scores a win, while
867 being destroyed or destroying a teammate scores a loss. Rogues have
868 no teammates (not even other rogues), so they cannot shoot teammates
869 and they do not have a team score.
870
871 There are two main styles of play: capture-the-flag and free-for-all.
872 In capture-the-flag, each team (except rogues) has a team base and
873 each team with at least one player has a team flag. The object is to
874 capture an enemy team's flag by bringing it to your team's base. This
875 destroys every player on the captured team, subtracts one from that
876 team's score, and adds one to your team's score. In free-for-all,
877 there are no team flags or team bases. The object is simply to get as
878 high a score as possible.")
879 ;; The game is dual-licensed.
880 (license (list license:lgpl2.1 license:mpl2.0))))
881
882 (define-public cataclysm-dda
883 (package
884 (name "cataclysm-dda")
885 (version "0.F-3")
886 (source
887 (origin
888 (method git-fetch)
889 (uri (git-reference
890 (url "https://github.com/CleverRaven/Cataclysm-DDA")
891 (commit version)))
892 (sha256
893 (base32 "1qnsz6az9qp4sbr3y4rcqhlmadrrdzafvd2xwf3db5wn0swvbjys"))
894 (file-name (git-file-name name version))))
895 (build-system gnu-build-system)
896 (arguments
897 '(#:make-flags
898 (list (string-append "PREFIX=" (assoc-ref %outputs "out"))
899 "USE_HOME_DIR=1" "DYNAMIC_LINKING=1" "RELEASE=1"
900 "LOCALIZE=1" "LANGUAGES=all")
901 #:phases
902 (modify-phases %standard-phases
903 (delete 'configure)
904 ;; Apparently we can't do make on both tiles and a console version at
905 ;; the same time anymore, so we have to either "make clean" between
906 ;; builds or do some other hackery. See:
907 ;; https://github.com/CleverRaven/Cataclysm-DDA/issues/42598#issuecomment-667702746
908 (add-after 'install 'make-clean-pre-tiles
909 (lambda* (#:key make-flags outputs #:allow-other-keys)
910 ;; Change prefix directory and enable tile graphics and sound.
911 (invoke "make" "clean")))
912 (add-after 'make-clean-pre-tiles 'build-tiles
913 (lambda* (#:key make-flags outputs #:allow-other-keys)
914 ;; Change prefix directory and enable tile graphics and sound.
915 (apply invoke "make" "TILES=1" "SOUND=1"
916 (string-append "PREFIX="
917 (assoc-ref outputs "tiles"))
918 (cdr make-flags))))
919 (add-after 'build-tiles 'install-tiles
920 (lambda* (#:key make-flags outputs #:allow-other-keys)
921 (apply invoke "make" "install" "TILES=1" "SOUND=1"
922 (string-append "PREFIX="
923 (assoc-ref outputs "tiles"))
924 (cdr make-flags)))))
925 ;; TODO: Add libtap++ from https://github.com/cbab/libtappp as a native
926 ;; input in order to support tests.
927 #:tests? #f))
928 (outputs '("out"
929 "tiles")) ;for tile graphics and sound support
930 (native-inputs
931 `(("gettext" ,gettext-minimal)
932 ("pkg-config" ,pkg-config)
933 ("astyle" ,astyle)))
934 (inputs
935 (list freetype
936 libogg
937 libvorbis
938 ncurses
939 sdl2
940 sdl2-image
941 sdl2-ttf
942 sdl2-mixer))
943 (home-page "https://cataclysmdda.org/")
944 (synopsis "Survival horror roguelike video game")
945 (description
946 "Cataclysm: Dark Days Ahead (or \"DDA\" for short) is a roguelike set
947 in a post-apocalyptic world. Struggle to survive in a harsh, persistent,
948 procedurally generated world. Scavenge the remnants of a dead civilization
949 for food, equipment, or, if you are lucky, a vehicle with a full tank of gas
950 to get you out of Dodge. Fight to defeat or escape from a wide variety of
951 powerful monstrosities, from zombies to giant insects to killer robots and
952 things far stranger and deadlier, and against the others like yourself, that
953 want what you have.")
954 (license license:cc-by-sa3.0)))
955
956 (define-public cockatrice
957 (let ((release-date "2021-01-26"))
958 (package
959 (name "cockatrice")
960 (version "2.8.0")
961 (source
962 (origin
963 (method git-fetch)
964 (uri (git-reference
965 (url "https://github.com/Cockatrice/Cockatrice")
966 (commit (string-append release-date "-Release-" version))))
967 (file-name (git-file-name name version))
968 (sha256
969 (base32
970 "0q8ffcklb2b7hcqhy3d2f9kz9aw22pp04pc9y4sslyqmf17pwnz9"))
971 (modules '((guix build utils)))
972 (snippet
973 ;; Strip image URLs as they point towards non-free web services
974 '(substitute* "cockatrice/src/settings/downloadsettings.cpp"
975 (("downloadURLs.append\\(\".*\"\\);") "")))))
976 (build-system qt-build-system)
977 (arguments
978 `(#:configure-flags '("-DWITH_SERVER=1"
979 "-DWITH_CLIENT=1"
980 "-DWITH_ORACLE=1"
981 "-DTEST=1")))
982 (native-inputs
983 (list googletest pkg-config))
984 (inputs
985 (list protobuf
986 qtbase-5
987 qtmultimedia
988 qtsvg
989 qttools
990 qtwebsockets
991 xz
992 zlib))
993 (home-page "https://cockatrice.github.io")
994 (synopsis "Tabletop card game simulator")
995 (description "Cockatrice is a program for playing tabletop card games
996 over a network. Its server design prevents users from manipulating the game
997 for unfair advantage. The client also provides a single-player mode, which
998 allows users to brew while offline.")
999 (license license:gpl2))))
1000
1001 (define-public corsix-th
1002 (package
1003 (name "corsix-th")
1004 (version "0.65.1")
1005 (source
1006 (origin
1007 (method git-fetch)
1008 (uri (git-reference
1009 (url "https://github.com/CorsixTH/CorsixTH")
1010 (commit (string-append "v" version))))
1011 (file-name (git-file-name name version))
1012 (sha256
1013 (base32 "0hw92ln9jm9v55drmbfqjng58yshgwfpv7fqynryrg3gvg8zhbvh"))))
1014 (build-system cmake-build-system)
1015 (arguments
1016 `(#:phases
1017 (modify-phases %standard-phases
1018 (add-after 'install 'wrap-binary
1019 (lambda _
1020 ;; Set Lua module paths and default MIDI soundfont on startup.
1021 (let* ((out (assoc-ref %outputs "out"))
1022 (fluid (assoc-ref %build-inputs "fluid-3"))
1023 (lua-version ,(version-major+minor (package-version lua)))
1024 (lua-cpath
1025 (map (lambda (lib)
1026 (string-append
1027 (assoc-ref %build-inputs (string-append "lua-" lib))
1028 "/lib/lua/" lua-version "/?.so"))
1029 '("filesystem" "lpeg"))))
1030 (wrap-program (string-append out "/bin/corsix-th")
1031 `("LUA_CPATH" ";" = ,lua-cpath)
1032 `("SDL_SOUNDFONTS" ":" suffix
1033 (,(string-append fluid "/share/soundfonts/FluidR3Mono_GM.sf3")))))
1034 #t)))
1035 #:tests? #f)) ; TODO need busted package to run tests
1036 ;; Omit Lua-Socket dependency to disable automatic updates.
1037 (inputs
1038 (list ffmpeg
1039 fluid-3
1040 freetype
1041 lua
1042 lua-filesystem
1043 lua-lpeg
1044 sdl2
1045 sdl2-mixer))
1046 (home-page "https://corsixth.com")
1047 (synopsis "Implementation of the @i{Theme Hospital} game engine")
1048 (description
1049 "This package provides a reimplementation of the 1997 Bullfrog business
1050 simulation game @i{Theme Hospital}. As well as faithfully recreating the
1051 original engine, CorsixTH adds support for high resolutions, custom levels and
1052 more. This package does @emph{not} provide the game assets.")
1053 (license (list
1054 license:expat ; main license
1055 license:bsd-3)))) ; CorsixTH/Src/random.c
1056
1057 (define-public cowsay
1058 (package
1059 (name "cowsay")
1060 (version "3.04")
1061 (source (origin
1062 (method git-fetch)
1063 (uri (git-reference
1064 (url "https://github.com/tnalpgge/rank-amateur-cowsay")
1065 (commit (string-append name "-" version))))
1066 (file-name (git-file-name name version))
1067 (sha256
1068 (base32
1069 "06455kq37hvq1xb7adyiwrx0djs50arsxvjgixyxks16lm1rlc7n"))))
1070 (build-system gnu-build-system)
1071 (arguments
1072 `(#:phases
1073 (modify-phases %standard-phases
1074 (delete 'configure) ; no configure script
1075 (delete 'build) ; nothing to be built
1076 (replace 'install
1077 (lambda* (#:key outputs #:allow-other-keys)
1078 (invoke "sh" "install.sh"
1079 (assoc-ref outputs "out"))))
1080 (delete 'check)
1081 (add-after 'install 'check
1082 (lambda* (#:key outputs #:allow-other-keys)
1083 (invoke (string-append (assoc-ref outputs "out")
1084 "/bin/cowsay")
1085 "We're done!"))))))
1086 (inputs
1087 (list perl))
1088 (home-page (string-append "https://web.archive.org/web/20071026043648/"
1089 "http://www.nog.net:80/~tony/warez/cowsay.shtml"))
1090 (synopsis "Speaking cow text filter")
1091 (description "Cowsay is basically a text filter. Send some text into it,
1092 and you get a cow saying your text. If you think a talking cow isn't enough,
1093 cows can think too: all you have to do is run @command{cowthink}. If you're
1094 tired of cows, a variety of other ASCII-art messengers are available.")
1095 (license license:gpl3+)))
1096
1097 (define-public lolcat
1098 (let ((commit "35dca3d0a381496d7195cd78f5b24aa7b62f2154")
1099 (revision "0"))
1100 (package
1101 (name "lolcat")
1102 (version (git-version "1.0" revision commit))
1103 (source
1104 (origin
1105 (method git-fetch)
1106 (uri (git-reference
1107 (url "https://github.com/jaseg/lolcat")
1108 (commit commit)))
1109 (sha256
1110 (base32
1111 "0jjbkqcc2ikjxd1xgdyv4rb0vsw218181h89f2ywg29ffs3ypd8g"))
1112 (file-name (git-file-name name version))))
1113 (build-system gnu-build-system)
1114 (arguments
1115 `(#:tests? #f ; no check target
1116 #:make-flags
1117 (list ,(string-append "CC=" (cc-for-target)))
1118 #:phases
1119 (modify-phases %standard-phases
1120 (delete 'bootstrap)
1121 (delete 'configure)
1122 (replace 'install
1123 (lambda* (#:key outputs #:allow-other-keys)
1124 (let* ((out (assoc-ref outputs "out"))
1125 (dest (string-append out "/bin")))
1126 (mkdir-p dest)
1127 (install-file "lolcat" dest)
1128 (install-file "censor" dest)
1129 #t))))))
1130 (home-page "https://github.com/jaseg/lolcat")
1131 (synopsis "Rainbow coloring effect for text console display")
1132 (description "@command{lolcat} concatenates files and streams like
1133 regular @command{cat}, but it also adds terminal escape codes between
1134 characters and lines resulting in a rainbow effect.")
1135 (license license:wtfpl2))))
1136
1137 (define-public falltergeist
1138 (package
1139 (name "falltergeist")
1140 (version "0.3.1")
1141 (source (origin
1142 (method git-fetch)
1143 (uri (git-reference
1144 (url "https://github.com/falltergeist/falltergeist")
1145 (commit version)))
1146 (file-name (git-file-name name version))
1147 (sha256
1148 (base32
1149 "05cg58i2g32wbmrvmdsicic8xs83gld3qr1p7r4lnlckcl1l7dy4"))))
1150 (build-system cmake-build-system)
1151 (arguments
1152 `(#:tests? #f)) ; no tests provided
1153 (native-inputs (list pkg-config))
1154 (inputs `(("sdl" ,(sdl-union (list sdl2
1155 sdl2-image
1156 sdl2-mixer)))
1157 ("glew" ,glew)
1158 ("glm" ,glm)))
1159 (home-page "https://falltergeist.org/")
1160 (synopsis "Fallout 2 game engine")
1161 (description "This package provides the Fallout 2 game engine. Game data
1162 should be placed in @file{~/.local/share/falltergeist}.")
1163 (license license:gpl3+)))
1164
1165 (define-public foobillard++
1166 ;; Even though this latest revision is old already, stable release is
1167 ;; lagging way behind it, and has issues with textures rendering.
1168 (let ((svn-revision 170))
1169 (package
1170 (name "foobillard++")
1171 (version (string-append "3.43-r" (number->string svn-revision)))
1172 (source
1173 (origin
1174 (method svn-fetch)
1175 (uri (svn-reference
1176 (url "svn://svn.code.sf.net/p/foobillardplus/code/")
1177 (revision svn-revision)))
1178 (file-name (git-file-name name version))
1179 (sha256
1180 (base32 "00b693ys5zvzjbjzzj3dqfzm5xw64gwjf9m8qv6bkmf0klbhmayk"))
1181 (patches
1182 (search-patches "foobillard++-pkg-config.patch"))
1183 (modules '((guix build utils)))
1184 (snippet
1185 '(begin
1186 ;; Unfortunately, the game includes background music with
1187 ;; a non-commercial clause. Delete it.
1188 (for-each delete-file (find-files "data/music" "\\.ogg$"))
1189 #t))))
1190 (build-system gnu-build-system)
1191 (arguments
1192 `(#:configure-flags
1193 (list
1194 ;; Install data in a less exotic location.
1195 (string-append "--prefix=" (assoc-ref %outputs "out") "/share")
1196 ;; Prevent a build error about undefined trigonometric functions.
1197 "--enable-fastmath=no")
1198 #:phases
1199 (modify-phases %standard-phases
1200 (add-after 'unpack 'fix-makefile
1201 ;; Remove hard-coded directories. Also fix installation
1202 ;; rule: it tries to move around non-existent files or
1203 ;; files already moved.
1204 (lambda* (#:key outputs #:allow-other-keys)
1205 (substitute* "Makefile.am"
1206 (("/usr") (assoc-ref outputs "out"))
1207 (("cp .*?/foobillardplus\\.desktop.*") "")
1208 (("cp .*?/foobillardplus\\.(png|xbm) \\$\\(datarootdir\\).*")
1209 ""))
1210 #t))
1211 (add-after 'unpack 'unbundle-font
1212 ;; XXX: The package ships with LinBiolinum_aSB.ttf and
1213 ;; LinBiolinum_aS.ttf, which are not provided by
1214 ;; `font-linuxlibertine' package. Therefore, we cannot replace
1215 ;; them yet.
1216 (lambda* (#:key inputs #:allow-other-keys)
1217 (let ((dejavu (string-append (assoc-ref inputs "font-dejavu")
1218 "/share/fonts/truetype/")))
1219 (with-directory-excursion "data"
1220 (for-each (lambda (f)
1221 (delete-file f)
1222 (symlink (string-append dejavu f) f))
1223 '("DejaVuSans-Bold.ttf" "DejaVuSans.ttf"))))
1224 #t))
1225 (replace 'bootstrap
1226 (lambda _
1227 (invoke "aclocal" "--force")
1228 (invoke "autoconf" "-f")
1229 (invoke "autoheader" "-f")
1230 (invoke "automake" "-a" "-c" "-f")))
1231 (add-before 'build 'prepare-build
1232 ;; Set correct environment for SDL.
1233 (lambda* (#:key inputs #:allow-other-keys)
1234 (setenv "CPATH"
1235 (string-append
1236 (search-input-directory inputs "include/SDL")
1237 ":" (or (getenv "CPATH") "")))))
1238 (add-before 'build 'fix-settings-directory
1239 ;; Hide foobillardplus settings directory in $HOME.
1240 (lambda _
1241 (substitute* "src/history.c"
1242 (("/foobillardplus-data") "/.foobillardplus"))
1243 #t))
1244 (add-before 'install 'create-directories
1245 ;; Install process does not create directories before
1246 ;; trying to move file in it.
1247 (lambda* (#:key outputs #:allow-other-keys)
1248 (let ((out (assoc-ref outputs "out")))
1249 (mkdir-p (string-append out "/share/icons"))
1250 (mkdir-p (string-append out "/share/applications")))
1251 #t))
1252 (add-after 'install 'symlink-executable
1253 ;; Symlink executable to $out/bin.
1254 (lambda* (#:key outputs #:allow-other-keys)
1255 (let* ((out (assoc-ref outputs "out"))
1256 (bin (string-append out "/bin")))
1257 (mkdir-p bin)
1258 (with-directory-excursion bin
1259 (symlink "../share/foobillardplus/bin/foobillardplus"
1260 "foobillardplus"))
1261 #t))))))
1262 (native-inputs
1263 (list autoconf automake pkg-config))
1264 (inputs
1265 `(("font-dejavu" ,font-dejavu)
1266 ("freetype" ,freetype)
1267 ("glu" ,glu)
1268 ("libpng" ,libpng)
1269 ("sdl" ,(sdl-union (list sdl sdl-mixer sdl-net)))))
1270 (home-page "http://foobillardplus.sourceforge.net/")
1271 (synopsis "3D billiard game")
1272 (description "FooBillard++ is an advanced 3D OpenGL billiard game
1273 based on the original foobillard 3.0a sources from Florian Berger.
1274 You can play it with one or two players or against the computer.
1275
1276 The game features:
1277
1278 @itemize
1279 @item Wood paneled table with gold covers and gold diamonds.
1280 @item Reflections on balls.
1281 @item Zoom in and out, rotation, different angles and bird's eye view.
1282 @item Different game modes: 8 or 9-ball, Snooker or Carambole.
1283 @item Tournaments. Compete against other players.
1284 @item Animated cue with strength and eccentric hit adjustment.
1285 @item Jump shots and snipping.
1286 @item Realistic gameplay and billiard sounds.
1287 @item Red-Green stereo.
1288 @item And much more.
1289 @end itemize")
1290 (license (list license:gpl2 license:silofl1.1)))))
1291
1292 (define-public freedoom
1293 (package
1294 (name "freedoom")
1295 (version "0.12.1")
1296 (source
1297 (origin
1298 (method git-fetch)
1299 (uri (git-reference
1300 (url "https://github.com/freedoom/freedoom")
1301 (commit (string-append "v" version))))
1302 (file-name (git-file-name name version))
1303 (sha256
1304 (base32 "1mq60lfwaaxmch7hsz8403pwafnlsmsd5z2df2j77ppwndwcrypb"))))
1305 (build-system gnu-build-system)
1306 (arguments
1307 '(#:make-flags
1308 (list (string-append "prefix=" (assoc-ref %outputs "out")))
1309 #:tests? #f ; no check target
1310 #:phases
1311 (modify-phases %standard-phases
1312 (delete 'bootstrap)
1313 (replace 'configure
1314 (lambda* (#:key inputs outputs #:allow-other-keys)
1315 (let* ((freedoom (assoc-ref outputs "out"))
1316 (wad-dir (string-append freedoom "/share/games/doom")))
1317 ;; Make sure that the install scripts know where to find
1318 ;; the appropriate WAD files.
1319 (substitute* "dist/freedoom"
1320 (("IWAD=freedm.wad")
1321 (string-append "IWAD=" wad-dir "/freedm.wad"))
1322 (("IWAD=freedoom1.wad")
1323 (string-append "IWAD=" wad-dir "/freedoom1.wad"))
1324 (("IWAD=freedoom2.wad")
1325 (string-append "IWAD=" wad-dir "/freedoom2.wad")))
1326 #t))))))
1327 (native-inputs
1328 (list asciidoc deutex python python-pillow))
1329 (home-page "https://freedoom.github.io/")
1330 (synopsis "Free content game based on the Doom engine")
1331 (native-search-paths
1332 (list (search-path-specification
1333 (variable "DOOMWADDIR")
1334 (files '("share/games/doom")))
1335 (search-path-specification
1336 (variable "DOOMWADPATH")
1337 (files '("share/games/doom")))))
1338 (description
1339 "The Freedoom project aims to create a complete free content first person
1340 shooter game. Freedoom by itself is just the raw material for a game: it must
1341 be paired with a compatible game engine (such as @code{prboom-plus}) to be
1342 played. Freedoom complements the Doom engine with free levels, artwork, sound
1343 effects and music to make a completely free game.")
1344 (license license:bsd-3)))
1345
1346 (define-public freedroidrpg
1347 (package
1348 (name "freedroidrpg")
1349 (version "0.16.1")
1350 (source
1351 (origin
1352 (method url-fetch)
1353 (uri (string-append "http://ftp.osuosl.org/pub/freedroid/"
1354 "freedroidRPG-" (version-major+minor version) "/"
1355 "freedroidRPG-" version ".tar.gz"))
1356 (sha256
1357 (base32 "0n4kn38ncmcy3lrxmq8fjry6c1z50z4q1zcqfig0j4jb0dsz2va2"))))
1358 (build-system gnu-build-system)
1359 (arguments
1360 `(#:configure-flags
1361 (list
1362 (string-append "CFLAGS="
1363 "-I" (assoc-ref %build-inputs "sdl-gfx") "/include/SDL "
1364 "-I" (assoc-ref %build-inputs "sdl-image") "/include/SDL "
1365 "-I" (assoc-ref %build-inputs "sdl-mixer") "/include/SDL")
1366 "--enable-opengl")
1367 ;; FIXME: the test suite fails with the following error output:
1368 ;; 4586 Segmentation fault env SDL_VIDEODRIVER=dummy \
1369 ;; SDL_AUDIODRIVER=dummy ./src/freedroidRPG -nb text
1370 #:tests? #f))
1371 (native-inputs
1372 (list pkg-config))
1373 (inputs
1374 `(("glu" ,glu)
1375 ("libjpeg" ,libjpeg-turbo)
1376 ("libogg" ,libogg)
1377 ("libpng" ,libpng)
1378 ("libvorbis" ,libvorbis)
1379 ("mesa" ,mesa)
1380 ("python" ,python-wrapper)
1381 ("sdl" ,sdl)
1382 ("sdl-gfx" ,sdl-gfx)
1383 ("sdl-image" ,sdl-image)
1384 ("sdl-mixer" ,sdl-mixer)
1385 ("zlib" ,zlib)))
1386 (home-page "https://www.freedroid.org/")
1387 (synopsis "Isometric role-playing game against killer robots")
1388 (description
1389 "Freedroid RPG is an @dfn{RPG} (Role-Playing Game) with isometric graphics.
1390 The game tells the story of a world destroyed by a conflict between robots and
1391 their human masters. To restore peace to humankind, the player must complete
1392 numerous quests while fighting off rebelling robots---either by taking control
1393 of them, or by simply blasting them to pieces with melee and ranged weapons in
1394 real-time combat.")
1395 (license (list license:expat ; lua/
1396 license:gpl3 ; src/gen_savestruct.py
1397 license:gpl2+)))) ; the rest
1398
1399 (define-public golly
1400 (package
1401 (name "golly")
1402 (version "3.3")
1403 (source (origin
1404 (method url-fetch)
1405 (uri (string-append "mirror://sourceforge/golly/golly/golly-"
1406 version "/golly-" version
1407 "-src.tar.gz"))
1408 (sha256
1409 (base32
1410 "1j3ksnar4rdam4xiyspgyrs1pifbvxfxkrn65brkwxpx39mpgzc8"))))
1411 (build-system gnu-build-system)
1412 (arguments
1413 '(#:make-flags (list "CC=gcc"
1414 (string-append "GOLLYDIR="
1415 (assoc-ref %outputs "out")
1416 "/share/golly"))
1417 #:tests? #f ; no check target
1418 #:phases
1419 (modify-phases %standard-phases
1420 (replace 'configure
1421 (lambda* (#:key inputs #:allow-other-keys)
1422 ;; For some reason, setting the PYTHON_SHLIB make flag doesn't
1423 ;; properly set the path to the Python shared library. This
1424 ;; substitution acheives the same end by different means.
1425 (substitute* "gui-wx/wxprefs.cpp"
1426 (("pythonlib = wxT\\(STRINGIFY\\(PYTHON_SHLIB\\)\\)")
1427 (string-append "pythonlib = \""
1428 (assoc-ref inputs "python")
1429 "/lib/libpython-2.7.so\"")))
1430 #t))
1431 (replace 'build
1432 (lambda* (#:key make-flags outputs #:allow-other-keys)
1433 (with-directory-excursion "gui-wx"
1434 (apply invoke `("make" ,@make-flags "-f" "makefile-gtk")))))
1435 (replace 'install
1436 (lambda* (#:key outputs #:allow-other-keys)
1437 (let* ((out (assoc-ref outputs "out"))
1438 (bin (string-append out "/bin"))
1439 (doc (string-append out "/share/doc/golly"))
1440 (pixmaps (string-append out "/share/pixmaps"))
1441 (share (string-append out "/share/golly")))
1442 (for-each (lambda (binary)
1443 (install-file binary bin))
1444 '("bgolly" "golly"))
1445 (for-each (lambda (document)
1446 (install-file
1447 (string-append "docs/" document ".html")
1448 doc))
1449 '("License" "ReadMe" "ToDo"))
1450 (install-file "gui-wx/icons/appicon.xpm" pixmaps)
1451 (for-each (lambda (folder)
1452 (copy-recursively
1453 folder
1454 (string-append share "/" folder)))
1455 '("Help" "Patterns" "Rules" "Scripts")))
1456 #t)))))
1457 (native-inputs
1458 (list lua))
1459 (inputs
1460 `(("glu" ,glu)
1461 ("mesa" ,mesa)
1462 ("python" ,python-2)
1463 ("wxwidgets" ,wxwidgets-gtk2)
1464 ("zlib" ,zlib)))
1465 (home-page "http://golly.sourceforge.net/")
1466 (synopsis "Software for exploring cellular automata")
1467 (description
1468 "Golly simulates Conway's Game of Life and many other types of cellular
1469 automata. The following features are available:
1470 @enumerate
1471 @item Support for bounded and unbounded universes, with cells of up to 256
1472 states.
1473 @item Support for multiple algorithms, including Bill Gosper's Hashlife
1474 algorithm.
1475 @item Loading patterns from BMP, PNG, GIF and TIFF image files.
1476 @item Reading RLE, macrocell, Life 1.05/1.06, dblife and MCell files.
1477 @item Scriptable via Lua or Python.
1478 @item Extracting patterns, rules and scripts from zip files.
1479 @item Downloading patterns, rules and scripts from online archives.
1480 @item Pasting patterns from the clipboard.
1481 @item Unlimited undo/redo.
1482 @item Configurable keyboard shortcuts.
1483 @item Auto fit option to keep patterns within the view.
1484 @end enumerate")
1485 (license license:gpl2+)))
1486
1487 (define-public joycond
1488 (let ((commit "f9a66914622514c13997c2bf7ec20fa98e9dfc1d")
1489 (revision "1"))
1490 (package
1491 (name "joycond")
1492 (version (git-version "0.1.0" revision commit))
1493 (source
1494 (origin
1495 (method git-fetch)
1496 (uri (git-reference
1497 (url "https://github.com/DanielOgorchock/joycond")
1498 (commit commit)))
1499 (file-name (git-file-name name version))
1500 (sha256
1501 (base32 "07z86yp27vxc0b44jgvf1vpa69rh3wdvd1xbzcsrj3f32743pv5a"))))
1502 (build-system cmake-build-system)
1503 (arguments
1504 `(#:tests? #f ;no test suite
1505 #:phases
1506 (modify-phases %standard-phases
1507 (add-after 'unpack 'fix-bin-location
1508 (lambda* (#:key outputs #:allow-other-keys)
1509 (let ((out (assoc-ref outputs "out")))
1510 (substitute* "CMakeLists.txt"
1511 (("/lib/udev/rules.d")
1512 (string-append out "/lib/udev/rules.d"))
1513 (("/etc/systemd/system")
1514 (string-append out "/etc/systemd/system"))
1515 (("/etc/modules-load.d")
1516 (string-append out "/etc/modules-load.d"))
1517 (("/usr/bin")
1518 (string-append out "/bin")))))))))
1519 (native-inputs (list pkg-config))
1520 (inputs
1521 (list eudev libevdev))
1522 (home-page "https://github.com/DanielOgorchock/joycond")
1523 (synopsis "Joy-Con controller daemon")
1524 (description "This package provides a userspace daemon for the Nintendo
1525 Joy-Con controllers.")
1526 (license license:gpl3))))
1527
1528 (define-public julius
1529 (package
1530 (name "julius")
1531 (version "1.6.0")
1532 (source
1533 (origin
1534 (method git-fetch)
1535 (uri (git-reference
1536 (url "https://github.com/bvschaik/julius")
1537 (commit (string-append "v" version))))
1538 (file-name (git-file-name name version))
1539 (sha256
1540 (base32 "0nfdn8n6ywhm69ckz9a1chl5xxiqyaj3l337wadsbppnpscjihrc"))
1541 ;; Remove unused bundled libraries.
1542 (modules '((guix build utils)))
1543 (snippet
1544 '(begin
1545 (with-directory-excursion "ext"
1546 (for-each delete-file-recursively '("dirent" "png" "SDL2" "zlib")))
1547 #t))))
1548 (build-system cmake-build-system)
1549 (inputs
1550 (list libpng sdl2 sdl2-mixer))
1551 (home-page "https://github.com/bvschaik/julius")
1552 (synopsis "Re-implementation of Caesar III game engine")
1553 (description
1554 "Engine for Caesar III, a city-building real-time strategy game.
1555 Julius includes some UI enhancements while preserving the logic (including
1556 bugs) of the original game, so that saved games are compatible. This package
1557 does not include game data.")
1558 (license (list license:agpl3
1559 license:zlib)))) ; ext/tinyfiledialogs
1560
1561 (define-public augustus
1562 (package
1563 (inherit julius)
1564 (name "augustus")
1565 (version "2.0.1")
1566 (source
1567 (origin
1568 (method git-fetch)
1569 (uri (git-reference
1570 (url "https://github.com/Keriew/augustus")
1571 (commit (string-append "v" version))))
1572 (file-name (git-file-name name version))
1573 (sha256
1574 (base32 "0czazw8mc3fbvdazs2nzvgxd1dpzjc8z5fwiv89vv4nd7laz3jkj"))
1575 ;; Remove unused bundled libraries.
1576 (modules '((guix build utils)))
1577 (snippet
1578 '(begin
1579 (with-directory-excursion "ext"
1580 (for-each delete-file-recursively '("dirent" "png" "SDL2" "zlib")))
1581 #t))))
1582 (arguments
1583 ;; No tests. See https://github.com/Keriew/augustus/issues/82.
1584 `(#:tests? #f))
1585 (home-page "https://github.com/Keriew/augustus")
1586 (synopsis "Re-implementation of Caesar III game engine with gameplay changes")
1587 (description
1588 "Fork of Julius, an engine for the a city-building real-time strategy
1589 game Caesar III. Gameplay enhancements include:
1590
1591 @itemize
1592 @item roadblocks;
1593 @item market special orders;
1594 @item global labour pool;
1595 @item partial warehouse storage;
1596 @item increased game limits;
1597 @item zoom controls.
1598 @end itemize\n")))
1599
1600 (define-public meandmyshadow
1601 (package
1602 (name "meandmyshadow")
1603 (version "0.5a")
1604 (source (origin
1605 (method url-fetch)
1606 (uri (string-append "mirror://sourceforge/meandmyshadow/"
1607 version "/meandmyshadow-" version
1608 "-src.tar.gz"))
1609 (sha256
1610 (base32
1611 "0i98v6cgmpsxy7mbb0s2y6f6qq6mkwzk2nrv1nz39ncf948aky2h"))))
1612 (build-system cmake-build-system)
1613 (arguments
1614 `(#:tests? #f)) ; there are no tests
1615 (native-inputs
1616 (list pkg-config))
1617 (inputs
1618 `(("curl" ,curl)
1619 ("libarchive" ,libarchive)
1620 ("lua" ,lua)
1621 ("sdl" ,(sdl-union (list sdl2
1622 sdl2-image
1623 sdl2-mixer
1624 sdl2-ttf)))))
1625 (home-page "https://acmepjz.github.io/meandmyshadow/")
1626 (synopsis "Puzzle/platform game")
1627 (description "Me and My Shadow is a puzzle/platform game in which you try
1628 to reach the exit by solving puzzles. Spikes, moving blocks, fragile blocks
1629 and much more stand between you and the exit. Record your moves and let your
1630 shadow mimic them to reach blocks you couldn't reach alone.")
1631 (license license:gpl3+)))
1632
1633 (define-public opensurge
1634 (package
1635 (name "opensurge")
1636 (version "0.5.2.1")
1637 (source
1638 (origin
1639 (method git-fetch)
1640 (uri (git-reference
1641 (url "https://github.com/alemart/opensurge")
1642 (commit (string-append "v" version))))
1643 (file-name (git-file-name name version))
1644 (sha256
1645 (base32 "13g5izss7dmgigc8iif8hid3z6i066b0z29rbql2b9qjmdj1dp41"))))
1646 (build-system cmake-build-system)
1647 (arguments
1648 `(#:tests? #f ;there are no tests
1649 #:configure-flags
1650 (let* ((out (assoc-ref %outputs "out"))
1651 (share (string-append out "/share")))
1652 (list (string-append "-DCMAKE_INSTALL_PREFIX=" out)
1653 (string-append "-DGAME_BINDIR=" out "/bin") ; not /bin/games
1654 (string-append "-DGAME_DATADIR=" share "/" ,name)
1655 (string-append "-DDESKTOP_ENTRY_PATH=" share "/applications")
1656 (string-append "-DDESKTOP_ICON_PATH=" share "/pixmaps")
1657 (string-append "-DDESKTOP_METAINFO_PATH=" share "/metainfo")))
1658 #:phases
1659 (modify-phases %standard-phases
1660 (add-after 'unpack 'fix-xdg-open-path
1661 (lambda* (#:key inputs #:allow-other-keys)
1662 ;; Look for xdg-open in the store.
1663 (substitute* "src/core/web.c"
1664 (("/usr(/bin/xdg-open)" _ bin)
1665 (search-input-file inputs bin)))))
1666 (add-after 'unpack 'unbundle-fonts
1667 (lambda* (#:key inputs #:allow-other-keys)
1668 ;; Replace bundled Roboto fonts with links to the store.
1669 (with-directory-excursion "fonts"
1670 (let ((roboto-dir (string-append
1671 (assoc-ref inputs "font-google-roboto")
1672 "/share/fonts/truetype/")))
1673 (for-each
1674 (lambda (font)
1675 (delete-file font)
1676 (symlink (string-append roboto-dir font) font))
1677 '("Roboto-Black.ttf" "Roboto-Bold.ttf" "Roboto-Medium.ttf")))
1678 #t))))))
1679 (inputs
1680 (list allegro font-google-roboto surgescript xdg-utils))
1681 (home-page "https://opensurge2d.org")
1682 (synopsis "2D retro side-scrolling game")
1683 (description "@code{Open Surge} is a 2D retro side-scrolling platformer
1684 inspired by the Sonic games. The player runs at high speeds through each
1685 level while collecting items and avoiding obstacles. The game includes a
1686 built-in level editor.")
1687 (license
1688 ;; Code is under GPL 3+, assets are under various licenses.
1689 ;; See src/misc/credits.c for details.
1690 (list license:gpl3+
1691 license:cc0
1692 license:cc-by3.0
1693 license:cc-by-sa3.0
1694 license:expat
1695 license:public-domain
1696 license:silofl1.1))))
1697
1698 (define-public knights
1699 (package
1700 (name "knights")
1701 (version "025")
1702 (source (origin
1703 (method url-fetch)
1704 (uri (string-append "http://www.knightsgame.org.uk/files/knights_"
1705 version "_src.tar.gz"))
1706 (sha256
1707 (base32
1708 "18vp2ygvn0s0jz8rm585jqf6hjqkam1ximq81k0r9hpmfj7wb88f"))))
1709 (build-system gnu-build-system)
1710 (arguments
1711 '(#:make-flags
1712 (list (string-append "PREFIX=" (assoc-ref %outputs "out"))
1713 "CXXFLAGS=-lpthread")
1714 #:phases
1715 (modify-phases %standard-phases
1716 ;; No configure script.
1717 (delete 'configure))
1718 #:tests? #f)) ;; No check target.
1719 (inputs
1720 `(("boost" ,boost)
1721 ("sdl-union" ,(sdl-union (list sdl sdl-image sdl-mixer)))
1722 ("freetype" ,freetype)
1723 ("fontconfig" ,fontconfig)
1724 ("curl" ,curl)))
1725 (native-inputs
1726 (list pkg-config))
1727 (home-page "http://www.knightsgame.org.uk/")
1728 (synopsis "Multiplayer dungeon game involving knights and quests")
1729 (description "Knights is a multiplayer game involving several knights who
1730 must run around a dungeon and complete various quests. Each game revolves
1731 around a quest – for example, you might have to find some items and carry them
1732 back to your starting point. This may sound easy, but as there are only
1733 enough items in the dungeon for one player to win, you may end up having to
1734 kill your opponents to get their stuff! Other quests involve escaping from
1735 the dungeon, fighting a duel to the death against the enemy knights, or
1736 destroying an ancient book using a special wand.")
1737 ;; This package includes modified sources of lua (X11), enet (Expat), and
1738 ;; guichan (BSD-3). The "Coercri" library is released under the Boost
1739 ;; license. The whole package is released under GPLv3+.
1740 (license license:gpl3+)))
1741
1742 (define-public gnome-2048
1743 (package
1744 (name "gnome-2048")
1745 (version "3.38.2")
1746 (source (origin
1747 (method url-fetch)
1748 (uri (string-append "mirror://gnome/sources/gnome-2048/"
1749 (version-major+minor version) "/"
1750 "gnome-2048-" version ".tar.xz"))
1751 (sha256
1752 (base32
1753 "0s5fg4z5in1h39fcr69j1qc5ynmg7a8mfprk3mc3c0csq3snfwz2"))))
1754 (build-system meson-build-system)
1755 (arguments
1756 `(#:glib-or-gtk? #t
1757 #:meson ,meson-0.59
1758 #:phases
1759 (modify-phases %standard-phases
1760 (add-after 'unpack 'skip-gtk-update-icon-cache
1761 ;; Don't create 'icon-theme.cache'.
1762 (lambda _
1763 (substitute* "meson_post_install.py"
1764 (("gtk-update-icon-cache") "true"))
1765 #t)))))
1766 (inputs
1767 (list gtk+ clutter clutter-gtk libgee libgnome-games-support))
1768 (native-inputs
1769 `(("gettext" ,gettext-minimal)
1770 ("glib:bin" ,glib "bin") ; for desktop-file-validate and appstream-util
1771 ("itstool" ,itstool)
1772 ("libxml2" ,libxml2)
1773 ("pkg-config" ,pkg-config)
1774 ("vala" ,vala)))
1775 (home-page "https://wiki.gnome.org/Apps/2048")
1776 (synopsis "Move the tiles until you obtain the 2048 tile")
1777 (description "GNOME 2048 provides a 2D grid for playing 2048, a
1778 single-player sliding tile puzzle game. The objective of the game is to merge
1779 together adjacent tiles of the same number until the sum of 2048 is achieved
1780 in one tile.")
1781 (license license:gpl3+)))
1782
1783 (define-public gnome-chess
1784 (package
1785 (name "gnome-chess")
1786 (version "3.37.3")
1787 (source (origin
1788 (method url-fetch)
1789 (uri (string-append "mirror://gnome/sources/gnome-chess/"
1790 (version-major+minor version) "/"
1791 "gnome-chess-" version ".tar.xz"))
1792 (sha256
1793 (base32
1794 "09axf0q1mp13sv8cs0syfg8ahcd9r2qb26278r09j6s4njxmkfv4"))))
1795 (build-system meson-build-system)
1796 (arguments
1797 '(#:glib-or-gtk? #t
1798 #:phases
1799 (modify-phases %standard-phases
1800 (add-after 'unpack 'skip-gtk-update-icon-cache
1801 ;; Don't create 'icon-theme.cache'.
1802 (lambda _
1803 (substitute* "meson_post_install.py"
1804 (("gtk-update-icon-cache") "true"))
1805 #t)))))
1806 (inputs
1807 (list gtk+ librsvg))
1808 (native-inputs
1809 `(("gettext" ,gettext-minimal)
1810 ("glib:bin" ,glib "bin") ; for desktop-file-validate and appstream-util
1811 ("itstool" ,itstool)
1812 ("pkg-config" ,pkg-config)
1813 ("vala" ,vala)))
1814 (home-page "https://wiki.gnome.org/Apps/Chess")
1815 (synopsis "Chess board for GNOME")
1816 (description "GNOME Chess provides a 2D board for playing chess games
1817 against human or computer players. It supports loading and saving games in
1818 Portable Game Notation. To play against a computer, install a chess engine
1819 such as chess or stockfish.")
1820 (license license:gpl3+)))
1821
1822 (define-public gnubg
1823 (package
1824 (name "gnubg")
1825 (version "1.06.002")
1826 (source
1827 (origin
1828 (method url-fetch)
1829 (uri (string-append "mirror://gnu/gnubg/gnubg-release-"
1830 version "-sources.tar.gz"))
1831 (sha256
1832 (base32
1833 "11xwhcli1h12k6rnhhyq4jphzrhfik7i8ah3k32pqw803460n6yf"))))
1834 (build-system gnu-build-system)
1835 (inputs (list ;; XXX: Build with an older Pango for 'pango_font_get_hb_font' and
1836 ;; 'pango_coverage_get_type'. Try removing this for versions > 1.06.002.
1837 pango-1.42
1838 glib
1839 readline
1840 gtk+-2
1841 mesa
1842 glu
1843 gtkglext
1844 sqlite
1845 libcanberra))
1846 (native-inputs `(("python-2" ,python-2)
1847 ("pkg-config" ,pkg-config)))
1848 (arguments
1849 `(#:configure-flags
1850 ;; SSE instructions are available on Intel systems only.
1851 (list ,@(if (any (cute string-prefix? <> (or (%current-target-system)
1852 (%current-system)))
1853 '("x86_64" "i686"))
1854 '("--enable-simd=sse2") ; prevent avx instructions
1855 '()))
1856 #:phases
1857 (modify-phases %standard-phases
1858 (add-after 'install 'install-desktop-file
1859 (lambda* (#:key outputs #:allow-other-keys)
1860 (let* ((out (assoc-ref outputs "out"))
1861 (apps (string-append out "/share/applications")))
1862 (mkdir-p apps)
1863 (with-output-to-file (string-append apps "/gnubg.desktop")
1864 (lambda _
1865 (format #t
1866 "[Desktop Entry]~@
1867 Name=GNU Backgammon~@
1868 Exec=~a/bin/gnubg -w~@
1869 Icon=gnubg~@
1870 Categories=Game;~@
1871 Terminal=false~@
1872 Type=Application~%"
1873 out))))
1874 #t)))))
1875 (home-page "https://www.gnu.org/software/gnubg/")
1876 (synopsis "Backgammon game")
1877 (description "The GNU backgammon application (also known as \"gnubg\") can
1878 be used for playing, analyzing and teaching the game. It has an advanced
1879 evaluation engine based on artificial neural networks suitable for both
1880 beginners and advanced players. In addition to a command-line interface, it
1881 also features an attractive, 3D representation of the playing board.")
1882 (license license:gpl3+)))
1883
1884 (define-public gnubik
1885 (package
1886 (name "gnubik")
1887 (version "2.4.3")
1888 (source
1889 (origin
1890 (method url-fetch)
1891 (uri (string-append "mirror://gnu/gnubik/gnubik-"
1892 version ".tar.gz"))
1893 (sha256
1894 (base32
1895 "1vlf924mq8hg93bsjj0rzvs0crc6psmlxyc6zn0fr7msnmpx6gib"))))
1896 (build-system gnu-build-system)
1897 (arguments
1898 '(#:phases (modify-phases %standard-phases
1899 (add-after 'unpack 'skip-gtk-update-icon-cache
1900 (lambda _
1901 ;; Do not attempt to run 'gtk-update-icon-cache', which is
1902 ;; unnecessary and causes a needless dependency on glib.
1903 (substitute* "Makefile.in"
1904 (("gtk-update-icon-cache")
1905 "true"))
1906 #t)))))
1907 (inputs (list gtk+-2
1908 mesa
1909 glu
1910 libx11
1911 guile-2.0
1912 gtkglext))
1913 (native-inputs `(("gettext" ,gettext-minimal)
1914 ("pkg-config" ,pkg-config)))
1915 (home-page "https://www.gnu.org/software/gnubik/")
1916 (synopsis "3d Rubik's cube game")
1917 (description
1918 "GNUbik is a puzzle game in which you must manipulate a cube to make
1919 each of its faces have a uniform color. The game is customizable, allowing
1920 you to set the size of the cube (the default is 3x3) or to change the colors.
1921 You may even apply photos to the faces instead of colors. The game is
1922 scriptable with Guile.")
1923 (license license:gpl3+)))
1924
1925 (define-public gnushogi
1926 (package
1927 (name "gnushogi")
1928 (version "1.4.2")
1929 (source
1930 (origin
1931 (method url-fetch)
1932 (uri (string-append "mirror://gnu/gnushogi/gnushogi-"
1933 version ".tar.gz"))
1934 (sha256
1935 (base32
1936 "0a9bsl2nbnb138lq0h14jfc5xvz7hpb2bcsj4mjn6g1hcsl4ik0y"))))
1937 (arguments `(#:tests? #f)) ;; No check target.
1938 (build-system gnu-build-system)
1939 (home-page "https://www.gnu.org/software/gnushogi/")
1940 (synopsis "The game of Shogi (Japanese chess)")
1941 (description "GNU Shogi is a program that plays the game Shogi (Japanese
1942 Chess). It is similar to standard chess but this variant is far more complicated.")
1943 (license license:gpl3+)))
1944
1945 (define-public ltris
1946 (package
1947 (name "ltris")
1948 (version "1.2.3")
1949 (source
1950 (origin
1951 (method url-fetch)
1952 (uri (string-append "mirror://sourceforge/lgames/ltris/"
1953 "ltris-" version ".tar.gz"))
1954 (sha256
1955 (base32 "1a2m17jwkyar8gj07bn5jk01j2ps4vvc48z955jjjsh67q2svi0f"))))
1956 (build-system gnu-build-system)
1957 (arguments
1958 '(#:phases
1959 (modify-phases %standard-phases
1960 (add-after 'set-paths 'set-sdl-paths
1961 (lambda* (#:key inputs #:allow-other-keys)
1962 (setenv "CPATH"
1963 (string-append
1964 (search-input-directory inputs "include/SDL")
1965 ":" (or (getenv "CPATH") ""))))))))
1966 (inputs
1967 (list (sdl-union (list sdl sdl-mixer))))
1968 (home-page "http://lgames.sourceforge.net/LTris/")
1969 (synopsis "Tetris clone based on the SDL library")
1970 (description
1971 "LTris is a tetris clone: differently shaped blocks are falling down the
1972 rectangular playing field and can be moved sideways or rotated by 90 degree
1973 units with the aim of building lines without gaps which then disappear (causing
1974 any block above the deleted line to fall down). LTris has three game modes: In
1975 Classic you play until the stack of blocks reaches the top of the playing field
1976 and no new blocks can enter. In Figures the playing field is reset to a new
1977 figure each level and later on tiles and lines suddenly appear. In Multiplayer
1978 up to three players (either human or CPU) compete with each other sending
1979 removed lines to all opponents. There is also a Demo mode in which you can
1980 watch your CPU playing while enjoying a cup of tea!")
1981 (license license:gpl2+)))
1982
1983 (define-public nethack
1984 (package
1985 (name "nethack")
1986 (version "3.6.6")
1987 (source
1988 (origin
1989 (method url-fetch)
1990 (uri
1991 (string-append "https://www.nethack.org/download/" version "/nethack-"
1992 (string-join (string-split version #\.) "") "-src.tgz"))
1993 (sha256
1994 (base32 "1liyckjp34j354qnxc1zn9730lh1p2dabrg1hap24z6xnqx0rpng"))))
1995 (native-inputs
1996 (list bison flex))
1997 (inputs
1998 (list ncurses less))
1999 (build-system gnu-build-system)
2000 (arguments
2001 '(#:make-flags
2002 `(,(string-append "PREFIX=" (assoc-ref %outputs "out")))
2003 #:phases
2004 (modify-phases %standard-phases
2005 (add-before 'configure 'patch-paths
2006 (lambda _
2007 (substitute* "sys/unix/nethack.sh"
2008 (("^ *cd .*$") ""))
2009 (substitute* "sys/unix/Makefile.utl"
2010 (("^YACC *=.*$") "YACC = bison -y\n")
2011 (("^LEX *=.*$") "LEX = flex\n")
2012 (("^# CC = gcc") "CC = gcc"))
2013 (substitute* "sys/unix/hints/linux"
2014 (("/bin/gzip") (string-append
2015 (assoc-ref %build-inputs "gzip")
2016 "/bin/gzip"))
2017 (("^WINTTYLIB=.*") "WINTTYLIB=-lncurses"))
2018 (substitute* "include/config.h"
2019 (("^.*define CHDIR.*$") "")
2020 (("^/\\* *#*define *REPRODUCIBLE_BUILD *\\*/")
2021 ;; Honor SOURCE_DATE_EPOCH.
2022 "#define REPRODUCIBLE_BUILD"))
2023
2024 ;; Note: 'makedefs' rejects and ignores dates that are too old
2025 ;; or too new, so we must choose something reasonable here.
2026 (setenv "SOURCE_DATE_EPOCH" "1531865062")
2027
2028 (substitute* "sys/unix/Makefile.src"
2029 (("^# CC = gcc") "CC = gcc"))
2030 #t))
2031 (replace 'configure
2032 (lambda _
2033 (let ((bash (string-append
2034 (assoc-ref %build-inputs "bash")
2035 "/bin/bash")))
2036 (with-directory-excursion "sys/unix"
2037 (substitute* "setup.sh" (("/bin/sh") bash))
2038 (invoke bash "setup.sh" "hints/linux"))
2039 #t)))
2040 (add-after 'install 'fixup-paths
2041 (lambda _
2042 (let* ((output (assoc-ref %outputs "out"))
2043 (nethack-script (string-append output "/bin/nethack")))
2044 (mkdir-p (string-append output "/games/lib/nethackuserdir"))
2045 (for-each
2046 (lambda (file)
2047 (rename-file
2048 (string-append output "/games/lib/nethackdir/" file)
2049 (string-append output "/games/lib/nethackuserdir/"
2050 file)))
2051 '("xlogfile" "logfile" "perm" "record" "save"))
2052 (mkdir-p (string-append output "/bin"))
2053 (call-with-output-file nethack-script
2054 (lambda (port)
2055 (format port "#!~a/bin/sh
2056 PATH=~a:$PATH
2057 if [ ! -d ~~/.config/nethack ]; then
2058 mkdir -p ~~/.config/nethack
2059 cp -r ~a/games/lib/nethackuserdir/* ~~/.config/nethack
2060 chmod -R +w ~~/.config/nethack
2061 fi
2062
2063 RUNDIR=$(mktemp -d)
2064
2065 cleanup() {
2066 rm -rf $RUNDIR
2067 }
2068 trap cleanup EXIT
2069
2070 cd $RUNDIR
2071 for i in ~~/.config/nethack/*; do
2072 ln -s $i $(basename $i)
2073 done
2074 for i in ~a/games/lib/nethackdir/*; do
2075 ln -s $i $(basename $i)
2076 done
2077 ~a/games/nethack"
2078 (assoc-ref %build-inputs "bash")
2079 (list->search-path-as-string
2080 (list
2081 (string-append
2082 (assoc-ref %build-inputs "coreutils") "/bin")
2083 (string-append
2084 (assoc-ref %build-inputs "less") "/bin"))
2085 ":")
2086 output
2087 output
2088 output)))
2089 (chmod nethack-script #o555)
2090 #t)))
2091 (delete 'check))))
2092 (home-page "https://nethack.org")
2093 (synopsis "Classic dungeon crawl game")
2094 (description "NetHack is a single player dungeon exploration game that runs
2095 on a wide variety of computer systems, with a variety of graphical and text
2096 interfaces all using the same game engine. Unlike many other Dungeons &
2097 Dragons-inspired games, the emphasis in NetHack is on discovering the detail of
2098 the dungeon and not simply killing everything in sight - in fact, killing
2099 everything in sight is a good way to die quickly. Each game presents a
2100 different landscape - the random number generator provides an essentially
2101 unlimited number of variations of the dungeon and its denizens to be discovered
2102 by the player in one of a number of characters: you can pick your race, your
2103 role, and your gender.")
2104 (license
2105 (license:fsdg-compatible
2106 "https://nethack.org/common/license.html"))))
2107
2108 (define-public pipewalker
2109 (package
2110 (name "pipewalker")
2111 (version "0.9.4")
2112 (source
2113 (origin
2114 (method url-fetch)
2115 (uri (string-append "mirror://sourceforge/pipewalker/pipewalker/"
2116 version "/pipewalker-" version ".tar.gz"))
2117 (sha256
2118 (base32 "1x46wgk0s55562pd96cxagxkn6wpgglq779f9b64ff1k3xzp3myn"))))
2119 (build-system gnu-build-system)
2120 (arguments
2121 `(#:configure-flags
2122 (list (string-append "--docdir=" (assoc-ref %outputs "out")
2123 "/share/doc/" ,name "-" ,version))
2124 #:phases
2125 (modify-phases %standard-phases
2126 (add-after 'configure 'patch-docdir
2127 ;; Makefile.in ignores configure's ‘--docdir=...’ option. Fix that.
2128 (lambda _
2129 (substitute* "Makefile"
2130 (("(pkgdocdatadir = ).*" _ assignment)
2131 (string-append assignment "$(docdir)\n")))
2132 #t)))))
2133 (inputs
2134 (list libpng mesa sdl))
2135 (home-page "http://pipewalker.sourceforge.net/")
2136 (synopsis "Logical tile puzzle")
2137 (description
2138 "PipeWalker is a simple puzzle game with many diffent themes: connect all
2139 computers to one network server, bring water from a source to the taps, etc.
2140 The underlying mechanism is always the same: you must turn each tile in the
2141 grid in the right direction to combine all components into a single circuit.
2142 Every puzzle has a complete solution, although there may be more than one.")
2143 (license license:gpl3+)))
2144
2145 (define-public prboom-plus
2146 (package
2147 (name "prboom-plus")
2148 (version "2.5.1.4")
2149 (source (origin
2150 (method url-fetch)
2151 (uri (string-append "mirror://sourceforge/prboom-plus/prboom-plus/"
2152 version "/prboom-plus-" version ".tar.gz"))
2153 (sha256
2154 (base32 "151v6nign86m1a2vqz27krsccpc9m4d1jax4y43v2fa82wfj9qp0"))
2155 (modules '((guix build utils)))
2156 (snippet
2157 '(begin
2158 (substitute* "src/version.c"
2159 (("__DATE__") "")
2160 (("__TIME__") ""))
2161 #t))))
2162 (build-system gnu-build-system)
2163 (arguments
2164 '(#:configure-flags '("--disable-cpu-opt")
2165 #:make-flags `(,(string-append "gamesdir="
2166 (assoc-ref %outputs "out") "/bin"))
2167 #:phases
2168 (modify-phases %standard-phases
2169 (add-after 'set-paths 'set-sdl'paths
2170 (lambda* (#:key inputs #:allow-other-keys)
2171 (setenv "CPATH"
2172 (string-append
2173 (search-input-directory inputs "/include/SDL")
2174 ":" (or (getenv "CPATH") ""))))))))
2175 (inputs
2176 (list fluidsynth
2177 glu
2178 libmad
2179 libpng
2180 libvorbis
2181 pcre
2182 portmidi
2183 (sdl-union (list sdl sdl-image sdl-mixer sdl-net))))
2184 (home-page "http://prboom-plus.sourceforge.net/")
2185 (synopsis "Version of the classic 3D shoot'em'up game Doom")
2186 (description
2187 "PrBoom+ is a Doom source port developed from the original PrBoom project.")
2188 (license license:gpl2+)))
2189
2190 (define-public retux
2191 (let ((release "1.5")
2192 (revision 0))
2193 (package
2194 (name "retux")
2195 (version (if (zero? revision)
2196 release
2197 (string-append release "-"
2198 (number->string revision))))
2199 (source (origin
2200 (method url-fetch)
2201 (uri (string-append "https://github.com/retux-game/retux/"
2202 "releases/download/v"
2203 version "/retux-"
2204 release "-src.zip"))
2205 (sha256
2206 (base32
2207 "1yima7s36hn2kh5h08lczc5iid8jbdxk7x1g5ms6knaznzj7rll3"))))
2208 (build-system python-build-system)
2209 (arguments
2210 `(#:tests? #f ; no check target
2211 #:phases
2212 (modify-phases %standard-phases
2213 ;; no setup.py script
2214 (delete 'build)
2215 (replace 'install
2216 (lambda* (#:key outputs #:allow-other-keys)
2217 (let* ((out (assoc-ref outputs "out"))
2218 (bin (string-append out "/bin"))
2219 (data (string-append out "/share/retux")))
2220 (mkdir-p bin)
2221
2222 (substitute* "retux.py"
2223 ;; Use the correct data directory.
2224 (("os\\.path\\.join\\(os\\.path\\.dirname\\(__file__\\), \"data\"\\),")
2225 (string-append "\"" data "\",")))
2226
2227 (copy-file "retux.py" (string-append bin "/retux"))
2228 (copy-recursively "data" data)
2229 #t))))))
2230 (native-inputs
2231 (list unzip))
2232 (inputs
2233 (list python-sge python-six python-xsge))
2234 (home-page "https://retux-game.github.io/")
2235 (synopsis "Action platformer game")
2236 (description
2237 "ReTux is an action platformer loosely inspired by the Mario games,
2238 utilizing the art assets from the @code{SuperTux} project.")
2239 ;; GPL version 3 or later is the license for the code and some art.
2240 ;; The rest of the licenses are for the art exclusively, as listed in
2241 ;; data/LICENSES.
2242 (license (list license:cc0
2243 license:cc-by3.0
2244 license:cc-by-sa3.0
2245 license:cc-by-sa4.0
2246 license:gpl2+
2247 license:gpl3+)))))
2248
2249 (define-public roguebox-adventures
2250 (package
2251 (name "roguebox-adventures")
2252 (version "3.0.1")
2253 (source
2254 (origin
2255 (method url-fetch)
2256 (uri (string-append
2257 "http://download.tuxfamily.org/rba/RogueBoxAdventures_v"
2258 (string-join (string-split version #\.) "_") "_Source.zip"))
2259 (file-name (string-append name "-" version ".zip"))
2260 (sha256
2261 (base32
2262 "05zd03s5w9kcpklfgcggbaa6rwf59nm0q9vcj6gh9v2lh402k067"))))
2263 (build-system python-build-system)
2264 (arguments
2265 `(#:tests? #f ; no check target
2266 #:phases
2267 (modify-phases %standard-phases
2268 (replace 'unpack
2269 (lambda* (#:key source #:allow-other-keys)
2270 (and (invoke "unzip" source)
2271 ;; The actual source is buried a few directories deep.
2272 (chdir (string-append "RogueBoxAdventures_v"
2273 (string-join
2274 (string-split ,version #\.) "_")
2275 "_Source")))))
2276 ;; no setup.py script
2277 (replace 'build
2278 (lambda* (#:key outputs #:allow-other-keys)
2279 (let* ((out (assoc-ref outputs "out"))
2280 (data (string-append
2281 out "/share/games/roguebox-adventures")))
2282 ;; Use the correct data directory.
2283 (substitute* '("main.py" "LIB/getch.py" "LIB/getch_gcwz.py")
2284 (("basic_path + os\\.sep + 'DATA'")
2285 (string-append "'" data "'"))
2286 (("^basic_path.*$")
2287 (string-append "basic_path ='" data "'\n")))
2288 (substitute* "LIB/dialog.py"
2289 (("d_path = os\\.path\\.dirname\\(.*\\)\\)")
2290 (string-append "d_path = '" data "'")))
2291 (substitute* "LIB/gra_files.py"
2292 (("basic_path = b_path\\.replace\\('/LIB',''\\)")
2293 (string-append "basic_path ='" data "'\n")))
2294
2295 ;; The game must save in the user's home directory because
2296 ;; the store is read-only.
2297 (substitute* "main.py"
2298 (("home_save = False") "home_save = True")
2299 (("'icon_small.png'")
2300 (string-append "'" data "/icon_small.png'"))))
2301 #t))
2302 (replace 'install
2303 (lambda* (#:key outputs #:allow-other-keys)
2304 (let* ((out (assoc-ref outputs "out"))
2305 (bin (string-append out "/bin"))
2306 (roguebox-adventures
2307 (string-append bin "/roguebox-adventures"))
2308 (data (string-append
2309 out "/share/games/roguebox-adventures"))
2310 (lib (string-append data "/LIB"))
2311 (doc (string-append
2312 out "/share/doc/roguebox-adventures")))
2313 (mkdir-p bin)
2314 (mkdir-p doc)
2315
2316 (for-each (lambda (file)
2317 (copy-recursively file
2318 (string-append data "/" file)))
2319 '("AUDIO" "FONT" "GRAPHIC" "LIB" "LICENSE"
2320 "icon_big.png" "icon_small.png"))
2321 (for-each (lambda (file)
2322 (chmod file #o555)
2323 (install-file file lib))
2324 '("main.py" "run.py"))
2325
2326 (copy-recursively "DOC" doc)
2327
2328 (call-with-output-file
2329 roguebox-adventures
2330 (lambda (p)
2331 (format p "\
2332 #!~a
2333 export GUIX_PYTHONPATH=~a/LIB:~a
2334 exec -a \"~a\" ~a \"$@\"\n"
2335 (which "bash") data (getenv "GUIX_PYTHONPATH")
2336 (which "python3")
2337 (string-append lib "/main.py"))))
2338 (chmod roguebox-adventures #o555))
2339 #t)))))
2340 (native-inputs
2341 (list unzip))
2342 (inputs
2343 (list python-pygame python-tmx))
2344 (home-page "https://rogueboxadventures.tuxfamily.org")
2345 (synopsis "A classical roguelike/sandbox game")
2346 (description
2347 "RogueBox Adventures is a graphical roguelike with strong influences
2348 from sandbox games like Minecraft or Terraria. The main idea of RogueBox
2349 Adventures is to offer the player a kind of roguelike toy-world. This world
2350 can be explored and changed freely.")
2351 ;; The GPL3+ is for code, the rest are for art.
2352 (license (list license:cc0
2353 license:cc-by3.0
2354 license:gpl3+
2355 license:silofl1.1))))
2356
2357 (define-public seahorse-adventures
2358 (package
2359 (name "seahorse-adventures")
2360 (version "1.3")
2361 (source
2362 (origin
2363 (method git-fetch)
2364 (uri (git-reference
2365 (url "https://github.com/dulsi/seahorse-adventures")
2366 (commit (string-append "release-" version))))
2367 (file-name (git-file-name name version))
2368 (sha256
2369 (base32 "0m53jh2gchzr7rs35hml6lbvc5kb5hp229wlfqa09098b7hhl15a"))
2370 (modules '((guix build utils)
2371 (ice-9 ftw)
2372 (srfi srfi-1)))
2373 ;; Remove non-free (non-commercial) font.
2374 (snippet
2375 `(begin
2376 (for-each delete-file (find-files "data/fonts" "."))
2377 #t))))
2378 (build-system python-build-system)
2379 (arguments
2380 `(#:tests? #f ;no test
2381 #:phases
2382 (modify-phases %standard-phases
2383 (delete 'build) ;pure Python
2384 (replace 'install ;no install script
2385 (lambda* (#:key outputs #:allow-other-keys)
2386 (let* ((out (assoc-ref outputs "out"))
2387 (bin (string-append out "/bin"))
2388 (share (string-append out "/share"))
2389 (applications (string-append share "/applications"))
2390 (data (string-append share "/seahorse-adventures")))
2391 ;; Install data.
2392 (for-each (lambda (f)
2393 (chmod f #o555)
2394 (install-file f data))
2395 '("leveledit.py" "run_game.py" "tileedit.py"))
2396 (for-each (lambda (dir)
2397 (let ((target (string-append data "/" dir)))
2398 (mkdir-p target)
2399 (copy-recursively dir target)))
2400 '("data" "lib"))
2401 ;; Create executable.
2402 (mkdir-p bin)
2403 (let ((executable (string-append bin "/seahorse-adventures")))
2404 (call-with-output-file executable
2405 (lambda (p)
2406 (format p
2407 "#!~a~@
2408 export GUIX_PYTHONPATH=~a:~a~@
2409 exec -a \"~a\" ~a \"$@\"~%"
2410 (which "bash") data (getenv "GUIX_PYTHONPATH")
2411 (which "python3")
2412 (string-append data "/run_game.py"))))
2413 (chmod executable #o555))
2414 ;; Add desktop file.
2415 (mkdir-p applications)
2416 (make-desktop-entry-file
2417 (string-append applications "/seahorse-adventures.desktop")
2418 #:name "Seahorse Adventures"
2419 #:comment
2420 '((#f "Help Barbie the seahorse float on bubbles to the moon"))
2421 #:exec ,name
2422 #:icon ,name
2423 #:categories '("Game" "ActionGame")
2424 #:keywords '("game" "retro" "platform"))
2425 ;; Add icons.
2426 (for-each
2427 (lambda (size)
2428 (let ((dir (string-append share "/icons/hicolor/"
2429 size "x" size "/apps")))
2430 (mkdir-p dir)
2431 (copy-file
2432 (string-append "icon" size ".png")
2433 (string-append dir "/searhorse-adventures.png"))))
2434 '("32" "64" "128")))
2435 #t))
2436 (add-after 'install 'unbundle-fonts
2437 ;; Unbundle Bitstream Vera font and replace deleted one.
2438 (lambda* (#:key outputs inputs #:allow-other-keys)
2439 (let* ((out (assoc-ref outputs "out"))
2440 (data (string-append out "/share/seahorse-adventures"))
2441 (vera (search-input-file
2442 inputs "/share/fonts/truetype/Vera.ttf")))
2443 (let ((themes-dir (string-append data "/data/themes/")))
2444 (for-each
2445 (lambda (theme)
2446 (let ((target (string-append themes-dir theme "/Vera.ttf")))
2447 (delete-file target)
2448 (symlink vera target)))
2449 '("default" "gray")))
2450 (symlink vera (string-append data "/data/fonts/04B_20__.TTF"))
2451 (substitute* (string-append data "/lib/main.py")
2452 (("f_scale = 0.35") "f_scale = 0.47")))
2453 #t)))))
2454 (inputs
2455 (list font-bitstream-vera python-pygame))
2456 (home-page "http://www.imitationpickles.org/barbie/")
2457 (synopsis "Help Barbie the seahorse float on bubbles to the moon")
2458 (description
2459 "Barbie Seahorse Adventures is a retro style platform arcade game.
2460 You are Barbie the seahorse who travels through the jungle, up to the
2461 volcano until you float on bubbles to the moon. On the way to your
2462 final destination you will encounter various enemies, servants of the
2463 evil overlord who has stolen the galaxy crystal. Avoid getting hit
2464 and defeat them with your bubbles!")
2465 ;; GPL2+ is for code, CC0 is for art.
2466 (license (list license:gpl2+ license:cc0))))
2467
2468 (define-public solarus
2469 (package
2470 (name "solarus")
2471 ;; XXX: When updating this package, please also update hash in
2472 ;; `solarus-quest-editor' below.
2473 (version "1.6.5")
2474 (source
2475 (origin
2476 (method git-fetch)
2477 (uri (git-reference
2478 (url "https://gitlab.com/solarus-games/solarus")
2479 (commit (string-append "v" version))))
2480 (file-name (git-file-name name version))
2481 (sha256
2482 (base32 "0ny9dgqphjv2l39rff2621hnrzpf8qin8vmnv7jdz20azjk4m8id"))))
2483 (build-system cmake-build-system)
2484 (arguments
2485 `(#:phases
2486 (modify-phases %standard-phases
2487 (add-after 'unpack 'disable-failing-tests
2488 ;; The following tests fail reporting a missing "/dev/dri"
2489 ;; file.
2490 (lambda _
2491 (substitute* "tests/cmake/AddTestMaps.cmake"
2492 ((".*1200_create_shader_from_source.*" all)
2493 (string-append "#" all))
2494 ((".*1210_shader_scaling_factor.*" all)
2495 (string-append "#" all)))
2496 #t))
2497 (add-before 'check 'set-home
2498 ;; Tests fail without setting the following environment
2499 ;; variables.
2500 (lambda _
2501 (setenv "HOME" (getcwd))
2502 (setenv "XDG_RUNTIME_DIR" (getcwd))
2503 #t)))))
2504 (native-inputs
2505 (list pkg-config qttools))
2506 (inputs
2507 `(("glm" ,glm)
2508 ("libmodplug" ,libmodplug)
2509 ("libogg" ,libogg)
2510 ("libvorbis" ,libvorbis)
2511 ("luajit" ,luajit)
2512 ("openal" ,openal)
2513 ("physfs" ,physfs)
2514 ("qtbase" ,qtbase-5)
2515 ("sdl2" ,(sdl-union (list sdl2 sdl2-image sdl2-ttf)))))
2516 (home-page "https://www.solarus-games.org/")
2517 (synopsis "Lightweight game engine for Action-RPGs")
2518 (description
2519 "Solarus is a 2D game engine written in C++, that can run games
2520 scripted in Lua. It has been designed with 16-bit classic Action-RPGs
2521 in mind.")
2522 ;; The source code is licensed under the terms of GPL-3.0.
2523 ;; Resources are licensed under the terms of CC-BY-SA-3.0 and
2524 ;; CC-BY-SA 4.0.
2525 (license (list license:gpl3 license:cc-by-sa3.0 license:cc-by-sa4.0))))
2526
2527 (define-public solarus-quest-editor
2528 (package
2529 (inherit solarus)
2530 (name "solarus-quest-editor")
2531 (version (package-version solarus))
2532 (source
2533 (origin
2534 (method git-fetch)
2535 (uri (git-reference
2536 (url "https://gitlab.com/solarus-games/solarus-quest-editor")
2537 (commit (string-append "v" version))))
2538 (file-name (git-file-name name version))
2539 (sha256
2540 (base32 "1pvjgd4faxii5sskw1h55lw90hlbazhwni8nxyywzrmkjbq7irm0"))))
2541 (arguments
2542 `(#:tests? #false)) ; no test suite
2543 (inputs
2544 (modify-inputs (package-inputs solarus)
2545 (prepend solarus)))
2546 (synopsis "Create and modify quests for the Solarus engine")
2547 (description
2548 "Solarus Quest Editor is a graphical user interface to create and
2549 modify quests for the Solarus engine.")))
2550
2551 (define-public superstarfighter
2552 (package
2553 (name "superstarfighter")
2554 (version "0.6.5")
2555 (source
2556 (origin
2557 (method git-fetch)
2558 (uri (git-reference
2559 (url "https://github.com/notapixelstudio/superstarfighter")
2560 ;; The commit is not tagged upstream:
2561 ;; https://github.com/notapixelstudio/superstarfighter/commit/350605bf5454c26ebe2c57d8217edd03689c0573
2562 (commit "32521f467616bb390e3929d07e1936ff43fe64da")))
2563 (file-name (git-file-name name version))
2564 (sha256
2565 (base32 "1ckghzrfgvk9z1n5f4ivnamm6s8h9sbv0a3aq9pp4a3yrhkgld0k"))))
2566 (build-system gnu-build-system)
2567 (arguments
2568 `(#:tests? #f ;there are no tests
2569 #:phases
2570 (modify-phases %standard-phases
2571 (replace 'configure
2572 (lambda _
2573 (chdir "godot")
2574 (setenv "HOME" (getcwd))
2575 (with-output-to-file "export_presets.cfg"
2576 (lambda ()
2577 (display
2578 "[preset.0]
2579 name=\"Guix\"
2580 platform=\"Linux/X11\"
2581 runnable=true
2582 [preset.0.options]")))
2583 #t))
2584 (replace 'build
2585 (lambda _
2586 (let ((godot (assoc-ref %build-inputs "godot-headless")))
2587 (invoke (string-append godot "/bin/godot_server")
2588 "--export-pack" "Guix"
2589 "superstarfighter.pck" "project.godot"))
2590 #t))
2591 (replace 'install
2592 (lambda* (#:key inputs outputs #:allow-other-keys)
2593 (let* ((out (assoc-ref outputs "out"))
2594 (bin (string-append out "/bin"))
2595 (share (string-append out "/share"))
2596 (data (string-append share "/superstarfighter"))
2597 (icons (string-append share "/icons/hicolor/256x256/apps")))
2598 (install-file "superstarfighter.pck" data)
2599 (mkdir-p bin)
2600 (call-with-output-file (string-append bin "/superstarfighter")
2601 (lambda (port)
2602 (format port
2603 "#!/bin/sh~@
2604 exec ~a/bin/godot --main-pack ~a/superstarfighter.pck~%"
2605 (assoc-ref inputs "godot")
2606 data)
2607 (chmod port #o755)))
2608 (mkdir-p icons)
2609 (copy-file "icon.png" (string-append icons "/" ,name ".png"))
2610 (make-desktop-entry-file
2611 (string-append share "/applications/" ,name ".desktop")
2612 #:name "SuperStarfighter"
2613 #:comment "Fast-paced arcade combat game"
2614 #:exec ,name
2615 #:icon ,name
2616 #:categories '("Game" "ArcadeGame")))
2617 #t)))))
2618 (native-inputs
2619 `(("godot-headless" ,godot "headless")))
2620 (inputs
2621 (list godot))
2622 (home-page "https://notapixel.itch.io/superstarfighter")
2623 (synopsis "Fast-paced local multiplayer arcade game")
2624 (description "In SuperStarfighter, up to four local players compete in a
2625 2D arena with fast-moving ships and missiles. Different game types are
2626 available, as well as a single-player mode with AI-controlled ships.")
2627 (license (list license:expat ; game
2628 license:silofl1.1)))) ; fonts
2629
2630 (define %ufoai-commit "a542a87a891f96b1ab2c44d35b2f6f16859a5019")
2631 (define %ufoai-revision "0")
2632 (define %ufoai-version (git-version "2.6.0_dev" %ufoai-revision %ufoai-commit))
2633 (define ufoai-source
2634 (origin
2635 (method git-fetch)
2636 (uri (git-reference
2637 (url "git://git.code.sf.net/p/ufoai/code") ;HTTPS fails mid-clone
2638 (commit %ufoai-commit)))
2639 (file-name (string-append "ufoai-" %ufoai-version "-checkout"))
2640 (sha256
2641 (base32
2642 "024s7b9rcg7iw8i2p72gwnvabk23ljlq0nldws0y4b6hpwzyn1wz"))
2643 (modules '((guix build utils)
2644 (srfi srfi-1)
2645 (ice-9 ftw)))
2646 (snippet
2647 '(begin
2648 ;; Delete ~32MiB of bundled dependencies.
2649 (with-directory-excursion "src/libs"
2650 (for-each delete-file-recursively
2651 (lset-difference equal? (scandir ".")
2652 '("." ".." "gtest" "mumble"))))
2653
2654 ;; Use relative path to Lua headers.
2655 (substitute* "src/common/scripts_lua.h"
2656 (("\\.\\./libs/lua/") ""))
2657
2658 ;; Adjust Makefile targets to not depend on 'ufo2map', since we build
2659 ;; it as a separate package. This way we don't need to make the same
2660 ;; adjustments for 'ufoai-data' and 'ufoai' below.
2661 (substitute* "build/maps.mk"
2662 (("\\./ufo2map") "ufo2map")
2663 (("maps: ufo2map") "maps:"))
2664 (substitute* "build/modules/testall.mk"
2665 (("testall: ufo2map") "testall:"))
2666
2667 ;; If no cURL headers are found, the build system will try to include
2668 ;; the bundled version, even when not required. Prevent that.
2669 (substitute* "build/default.mk"
2670 (("^include src/libs/curl/lib/Makefile\\.inc")
2671 ""))
2672
2673 ;; While here, improve reproducibility by adding the '-X' flag to the
2674 ;; zip command used to create the map files, in order to prevent time
2675 ;; stamps from making it into the generated archives.
2676 (substitute* "build/data.mk"
2677 (("\\$\\(call ZIP\\)")
2678 "$(call ZIP) -X"))
2679 #t))))
2680
2681 (define-public trigger-rally
2682 (package
2683 (name "trigger-rally")
2684 (version "0.6.6.1")
2685 (source
2686 (origin
2687 (method url-fetch)
2688 (uri (string-append "mirror://sourceforge/trigger-rally/"
2689 "trigger-" version "/"
2690 "trigger-rally-" version ".tar.gz"))
2691 (sha256
2692 (base32
2693 "016bc2hczqscfmngacim870hjcsmwl8r3aq8x03vpf22s49nw23z"))))
2694 (build-system gnu-build-system)
2695 (inputs
2696 `(("freealut" ,freealut)
2697 ("glew" ,glew)
2698 ("glu" ,glu)
2699 ("mesa" ,mesa)
2700 ("openal" ,openal)
2701 ("physfs" ,physfs)
2702 ("sdl" ,(sdl-union (list sdl2 sdl2-image)))
2703 ("tinyxml2" ,tinyxml2)))
2704 (arguments
2705 `(#:make-flags (list (string-append "prefix=" %output)
2706 "bindir=$(prefix)/bin"
2707 "datadir=$(datarootdir)"
2708 "OPTIMS=-Ofast")
2709 #:tests? #f ; No tests present
2710 #:phases
2711 (modify-phases %standard-phases
2712 (delete 'configure)
2713 (add-before 'build 'cd-src
2714 (lambda _ (chdir "src")))
2715 (add-before 'build 'remove-timestamps
2716 (lambda _
2717 (substitute* (list "Trigger/menu.cpp"
2718 "PEngine/app.cpp")
2719 ((".*__DATE__.*") ""))))
2720 (add-before 'build 'make-verbose
2721 (lambda _
2722 (substitute* "GNUmakefile"
2723 (("@\\$\\(CXX\\)") "$(CXX)"))))
2724 (add-after 'build 'set-data-path
2725 (lambda* (#:key outputs #:allow-other-keys)
2726 (let ((out (assoc-ref outputs "out")))
2727 (substitute* "../bin/trigger-rally.config.defs"
2728 (("<data path=\"C:[^\"]*\"")
2729 (string-append "<data path=\"" out "/share/trigger-rally\""))))))
2730 (add-after 'install 'create-desktop-entry
2731 (lambda* (#:key outputs #:allow-other-keys)
2732 (let* ((out (assoc-ref outputs "out"))
2733 (apps (string-append out "/share/applications")))
2734 (mkdir-p apps)
2735 (with-output-to-file
2736 (string-append apps "/trigger-rally.desktop")
2737 (lambda ()
2738 (format #t ; Borrowed from Debian package
2739 "[Desktop Entry]~@
2740 Name=Trigger Rally~@
2741 Icon=trigger-rally~@
2742 Comment=3D rally racing car game~@
2743 Comment[de]=3D Rally-Autorennen~@
2744 Comment[fr_FR]=un jeu de rally en 3D~@
2745 Comment[ro_RO]=Un joc în 3D cu curse de raliu~@
2746 Exec=~a/bin/trigger-rally~@
2747 Terminal=false~@
2748 StartupNotify=false~@
2749 Type=Application~@
2750 TryExec=~:*~a/bin/trigger-rally~@
2751 Categories=Game;ArcadeGame;~@
2752 Keywords=racing;tracks;~@
2753 Keywords[de]=Rennstrecke;~%"
2754 out)))))))))
2755 (home-page "http://trigger-rally.sourceforge.net")
2756 (synopsis "Fast-paced single-player racing game")
2757 (description "Trigger-rally is a 3D rally simulation with great physics
2758 for drifting on over 200 maps. Different terrain materials like dirt,
2759 asphalt, sand, ice, etc. and various weather, light, and fog conditions give
2760 this rally simulation the edge over many other games. You need to make it
2761 through the maps in often tight time limits and can further improve by beating
2762 the recorded high scores. All attached single races must be finished in time
2763 in order to win an event, unlocking additional events and cars. Most maps are
2764 equipped with spoken co-driver notes and co-driver icons.")
2765 (license (list license:cc0 ;textures and audio in data.zip
2766 license:gpl2+))))
2767
2768 (define-public ufo2map
2769 (package
2770 (name "ufo2map")
2771 (version %ufoai-version)
2772 (home-page "https://ufoai.org/")
2773 (source ufoai-source)
2774 (build-system gnu-build-system)
2775 (arguments
2776 '(#:configure-flags '("CC=gcc" "CXX=g++"
2777 "--enable-release"
2778 "--enable-ufo2map"
2779 "--disable-uforadiant"
2780 "--disable-cgame-campaign"
2781 "--disable-cgame-multiplayer"
2782 "--disable-cgame-skirmish"
2783 "--disable-game"
2784 "--disable-memory"
2785 "--disable-testall"
2786 "--disable-ufoded"
2787 "--disable-ufo"
2788 "--disable-ufomodel"
2789 "--disable-ufoslicer")
2790 #:tests? #f ;no tests
2791 #:phases (modify-phases %standard-phases
2792 (replace 'configure
2793 (lambda* (#:key (configure-flags '()) #:allow-other-keys)
2794 ;; The home-made configure script does not understand
2795 ;; some of the default flags of gnu-build-system.
2796 (apply invoke "./configure" configure-flags)))
2797 (replace 'install
2798 (lambda* (#:key outputs #:allow-other-keys)
2799 (let ((out (assoc-ref outputs "out")))
2800 (install-file "ufo2map" (string-append out "/bin"))
2801 (install-file "debian/ufo2map.6"
2802 (string-append out "/share/man/man6"))
2803 #t))))))
2804 (native-inputs
2805 (list pkg-config))
2806 (inputs
2807 `(("libjpeg" ,libjpeg-turbo)
2808 ("libpng" ,libpng)
2809 ("lua" ,lua-5.1)
2810 ("sdl-union" ,(sdl-union (list sdl2 sdl2-mixer sdl2-ttf)))))
2811 (synopsis "UFO: AI map generator")
2812 (description
2813 "This package provides @command{ufo2map}, a program used to generate
2814 maps for the UFO: Alien Invasion strategy game.")
2815 (license license:gpl2+)))
2816
2817 (define ufoai-data
2818 (package
2819 (name "ufoai-data")
2820 (version %ufoai-version)
2821 (home-page "https://ufoai.org/")
2822 (source ufoai-source)
2823 (build-system gnu-build-system)
2824 (arguments
2825 '(#:tests? #f
2826 #:configure-flags '("CC=gcc" "CXX=g++")
2827 #:phases (modify-phases %standard-phases
2828 (replace 'configure
2829 (lambda* (#:key outputs (configure-flags '()) #:allow-other-keys)
2830 (apply invoke "./configure" configure-flags)))
2831 (replace 'build
2832 (lambda* (#:key (parallel-build? #t) #:allow-other-keys)
2833 (invoke "make"
2834 "-j" (if parallel-build?
2835 (number->string (parallel-job-count))
2836 "1")
2837 "maps")))
2838 (add-after 'build 'pack
2839 (lambda _
2840 (invoke "make" "pk3")))
2841 (replace 'install
2842 (lambda* (#:key outputs #:allow-other-keys)
2843 (let ((out (assoc-ref outputs "out")))
2844 (for-each (lambda (file)
2845 (install-file file out))
2846 (find-files "base" "\\.pk3$"))
2847 #t))))))
2848 (native-inputs
2849 `(("python" ,python-2)
2850 ("ufo2map" ,ufo2map)
2851 ("which" ,which)
2852 ("zip" ,zip)))
2853 (synopsis "UFO: AI data files")
2854 (description
2855 "This package contains maps and other assets for UFO: Alien Invasion.")
2856 ;; Most assets are available under either GPL2 or GPL2+. Some use other
2857 ;; licenses, see LICENSES for details.
2858 (license (list license:gpl2+ license:gpl2 license:cc-by3.0
2859 license:cc-by-sa3.0 license:public-domain))))
2860
2861 (define-public ufoai
2862 (package
2863 (name "ufoai")
2864 (version %ufoai-version)
2865 (home-page "https://ufoai.org/")
2866 (source ufoai-source)
2867 (build-system gnu-build-system)
2868 (arguments
2869 `(#:configure-flags
2870 (list (string-append "--prefix=" (assoc-ref %outputs "out"))
2871 (string-append "--datadir=" (assoc-ref %outputs "out")
2872 "/share/games/ufo")
2873 "CC=gcc" "CXX=g++"
2874 "--enable-release"
2875 "--enable-game"
2876 "--disable-ufo2map"
2877 "--disable-dependency-tracking"
2878
2879 ;; Disable hard links to prevent huge NARs.
2880 "--disable-hardlinkedgame"
2881 "--disable-hardlinkedcgame")
2882 #:phases (modify-phases %standard-phases
2883 (add-after 'unpack 'symlink-data-files
2884 (lambda* (#:key inputs #:allow-other-keys)
2885 (let ((data (assoc-ref inputs "ufoai-data")))
2886 ;; Symlink the data files to where the build system
2887 ;; expects to find them. Ultimately these files are
2888 ;; copied to $out/share/games/ufoai/base, losing the
2889 ;; symlinks; we could fix that after install, but it
2890 ;; does not make a big difference in practice due to
2891 ;; deduplication.
2892 (with-directory-excursion "base"
2893 (for-each (lambda (file)
2894 (symlink file (basename file)))
2895 (find-files data "\\.pk3$")))
2896 #t)))
2897 (add-before 'configure 'create-language-files
2898 (lambda _
2899 (invoke "make" "lang")))
2900 (replace 'configure
2901 (lambda* (#:key outputs (configure-flags '()) #:allow-other-keys)
2902 (apply invoke "./configure" configure-flags)))
2903 (replace 'check
2904 (lambda* (#:key tests? #:allow-other-keys)
2905 (if tests?
2906 (invoke "./testall")
2907 (format #t "test suite not run~%"))
2908 #t))
2909 (add-after 'install 'install-man-pages
2910 (lambda* (#:key outputs #:allow-other-keys)
2911 (let* ((out (assoc-ref outputs "out"))
2912 (man6 (string-append out "/share/man/man6")))
2913 (install-file "debian/ufo.6" man6)
2914 (install-file "debian/ufoded.6" man6)
2915 #t))))
2916
2917 ;; TODO: Some map tests occasionally fail because of randomness issues,
2918 ;; e.g. not enough generated aliens. The test runner also fails early
2919 ;; in the build container with 'failed to shutdown server'?
2920 #:tests? #f))
2921 (native-inputs
2922 `(("gettext" ,gettext-minimal)
2923 ("pkg-config" ,pkg-config)
2924 ("python" ,python-2)
2925 ("ufo2map" ,ufo2map)
2926 ("ufoai-data" ,ufoai-data)))
2927 (inputs
2928 `(("curl" ,curl)
2929 ("libjpeg" ,libjpeg-turbo)
2930 ("libogg" ,libogg)
2931 ("libpng" ,libpng)
2932 ("libtheora" ,libtheora)
2933 ("libvorbis" ,libvorbis)
2934 ("libxml2" ,libxml2)
2935 ("lua" ,lua-5.1)
2936 ("mesa" ,mesa)
2937 ("minixml" ,minixml)
2938 ("sdl-union" ,(sdl-union (list sdl2 sdl2-mixer sdl2-ttf)))
2939 ("zlib" ,zlib)))
2940 (synopsis "Turn-based tactical strategy game")
2941 (description
2942 "UFO: Alien Invasion is a tactical strategy game set in the year 2084.
2943 You control a secret organisation charged with defending Earth from a brutal
2944 alien enemy. Build up your bases, prepare your team, and dive head-first into
2945 the fast and flowing turn-based combat.
2946
2947 Over the long term you will need to conduct research into the alien threat to
2948 figure out their mysterious goals and use their powerful weapons for your own
2949 ends. You will produce unique items and use them in combat against your
2950 enemies.
2951
2952 You can also use them against your friends with the multiplayer functionality.
2953
2954 Warning: This is a pre-release version of UFO: AI! Some things may not work
2955 properly.")
2956
2957 ;; The game code and most assets are GPL2+, but we use GPL2 only here
2958 ;; because some assets do not use the "or later" clause. Many individual
2959 ;; assets use Creative Commons or Public Domain; see the LICENSE file.
2960 (license (delete license:gpl2+ (package-license ufoai-data)))))
2961
2962 (define-public xshogi
2963 (package
2964 (name "xshogi")
2965 (version "1.4.2")
2966 (source
2967 (origin
2968 (method url-fetch)
2969 (uri (string-append "mirror://gnu/gnushogi/xshogi-"
2970 version ".tar.gz"))
2971 (sha256
2972 (base32
2973 "1dns0nhymak44by18sv48m4xb2skiwbi2i3nb9hl6w9iwd2i2brf"))))
2974 (build-system gnu-build-system)
2975 (inputs
2976 (list libxaw libxt))
2977 (home-page "https://www.gnu.org/software/gnushogi/")
2978 (synopsis "User interface for gnushogi")
2979 (description "A graphical user interface for the package @code{gnushogi}.")
2980 ;; Contains a copy of GPLv3 but the licence notices simply
2981 ;; state "GNU General Public Licence" without specifying a version.
2982 (license license:gpl1+)))
2983
2984 (define-public abbaye
2985 (package
2986 (name "abbaye")
2987 (version "2.0.1")
2988 (source
2989 (origin
2990 (method git-fetch)
2991 (uri (git-reference
2992 (url "https://github.com/nevat/abbayedesmorts-gpl")
2993 (commit (string-append "v" version))))
2994 (file-name (git-file-name name version))
2995 (sha256
2996 (base32 "1pwqf7r9bqb2p3xrw9i7y8pgr1401fy3mnnqpb1qkhmdl3gqi9hb"))
2997 (modules '((guix build utils)))
2998 (snippet
2999 ;; Unbundle fonts.
3000 '(begin
3001 (delete-file-recursively "fonts")
3002 #t))))
3003 (build-system gnu-build-system)
3004 (arguments
3005 '(#:make-flags '("CC=gcc")
3006 #:phases (modify-phases %standard-phases
3007 (add-after 'set-paths 'set-sdl-paths
3008 (lambda* (#:key inputs #:allow-other-keys)
3009 (setenv "CPATH"
3010 (string-append
3011 (search-input-directory inputs "include/SDL2")
3012 ":" (or (getenv "CPATH") "")))))
3013 (add-after 'patch-source-shebangs 'patch-makefile
3014 (lambda* (#:key outputs #:allow-other-keys)
3015 ;; Replace /usr with package output directory.
3016 (substitute* "Makefile"
3017 (("/usr") (assoc-ref outputs "out")))))
3018 (add-before 'install 'make-install-dirs
3019 (lambda* (#:key outputs #:allow-other-keys)
3020 (let ((prefix (assoc-ref outputs "out")))
3021 ;; Create directories that the makefile assumes exist.
3022 (mkdir-p (string-append prefix "/bin"))
3023 (mkdir-p (string-append prefix "/share/applications"))
3024 (mkdir-p (string-append prefix "/share/pixmaps")))))
3025 ;; No configure script.
3026 (delete 'configure))
3027 #:tests? #f)) ;; No check target.
3028 (native-inputs (list pkg-config))
3029 (inputs (list (sdl-union (list sdl2 sdl2-image sdl2-mixer))))
3030 (home-page "https://github.com/nevat/abbayedesmorts-gpl")
3031 (synopsis "GNU/Linux port of the indie game \"l'Abbaye des Morts\"")
3032 (description "L'Abbaye des Morts is a 2D platform game set in 13th century
3033 France. The Cathars, who preach about good Christian beliefs, were being
3034 expelled by the Catholic Church out of the Languedoc region in France. One of
3035 them, called Jean Raymond, found an old church in which to hide, not knowing
3036 that beneath its ruins lay buried an ancient evil.")
3037 (license license:gpl3)))
3038
3039 (define-public angband
3040 (package
3041 (name "angband")
3042 (version "4.2.3")
3043 (source
3044 (origin
3045 (method git-fetch)
3046 (uri (git-reference
3047 (url "https://github.com/angband/angband")
3048 (commit version)))
3049 (file-name (git-file-name name version))
3050 (sha256
3051 (base32 "1psrdbf90mb6dhq0b9z18pz1csnshz1kvwg82dvwa99apqdw0la8"))
3052 (modules '((guix build utils)))
3053 (snippet
3054 ;; So, some of the sounds/graphics/tilesets are under different
3055 ;; licenses... some of them even nonfree! This is a console-only
3056 ;; version of this package so we just remove them.
3057 ;; In the future, if someone tries to make a graphical variant of
3058 ;; this package, they can deal with that mess themselves. :)
3059 '(begin
3060 (for-each (lambda (subdir)
3061 (let ((lib-subdir (string-append "lib/" subdir)))
3062 (delete-file-recursively lib-subdir)))
3063 '("fonts" "icons" "sounds" "tiles"))
3064 (substitute* "lib/Makefile"
3065 ;; And don't try to invoke makefiles in the directories we removed.
3066 (("gamedata customize help screens fonts tiles sounds icons user")
3067 "gamedata customize help screens user"))
3068 #t))))
3069 (build-system gnu-build-system)
3070 (arguments
3071 `(#:tests? #f ; no check target
3072 #:configure-flags (list (string-append "--bindir=" %output "/bin"))))
3073 (native-inputs
3074 (list autoconf automake))
3075 (inputs (list ncurses))
3076 (home-page "https://rephial.org/")
3077 (synopsis "Dungeon exploration roguelike")
3078 (description "Angband is a Classic dungeon exploration roguelike. Explore
3079 the depths below Angband, seeking riches, fighting monsters, and preparing to
3080 fight Morgoth, the Lord of Darkness.")
3081 (license license:gpl2)))
3082
3083 (define-public pingus
3084 (package
3085 (name "pingus")
3086 (version "0.7.6")
3087 (source
3088 (origin
3089 (method git-fetch)
3090 (uri (git-reference
3091 (url "https://gitlab.com/pingus/pingus.git")
3092 (commit (string-append "v" version))))
3093 (file-name (git-file-name name version))
3094 (sha256
3095 (base32
3096 "0wp06kcmknsnxz7bjnsndb8x062z7r23fb3yrnbfnj68qhz18y74"))
3097 (patches (search-patches "pingus-boost-headers.patch"
3098 "pingus-sdl-libs-config.patch"))
3099 (modules '((guix build utils)))
3100 (snippet
3101 '(begin
3102 (substitute* "src/pingus/screens/demo_session.cpp"
3103 (("#include <iostream>")
3104 ;; std::function moved to <functional> with C++ 11.
3105 ;; Remove this for versions newer than 0.7.6.
3106 "#include <iostream>\n#include <functional>"))
3107 #t))))
3108 (build-system gnu-build-system)
3109 (native-inputs (list pkg-config scons-python2))
3110 (inputs (list sdl
3111 sdl-image
3112 sdl-mixer
3113 mesa
3114 glu
3115 libpng
3116 boost))
3117 (arguments
3118 '(#:make-flags (list (string-append "PREFIX=" %output))
3119 #:tests? #f ; no check target
3120 #:phases
3121 (modify-phases %standard-phases
3122 (delete 'configure)))) ; no configure script
3123 (home-page "https://pingus.seul.org/")
3124 (synopsis "Lemmings clone")
3125 (description
3126 "Pingus is a free Lemmings-like puzzle game in which the player takes
3127 command of a bunch of small animals and has to guide them through levels.
3128 Since the animals walk on their own, the player can only influence them by
3129 giving them commands, like build a bridge, dig a hole, or redirect all animals
3130 in the other direction. Multiple such commands are necessary to reach the
3131 level's exit. The game is presented in a 2D side view.")
3132 ;; Some source files are under bsd-3 and gpl2+ licenses.
3133 (license license:gpl3+)))
3134
3135 (define-public talkfilters
3136 (package
3137 (name "talkfilters")
3138 (version "2.3.8")
3139 (source
3140 (origin
3141 (method url-fetch)
3142 (uri (string-append "http://www.hyperrealm.com/talkfilters/"
3143 "talkfilters-" version ".tar.gz"))
3144 (sha256
3145 (base32 "19nc5vq4bnkjvhk8srqddzhcs93jyvpm9r6lzjzwc1mgf08yg0a6"))))
3146 (build-system gnu-build-system)
3147 (home-page "https://www.gnu.org/software/talkfilters/")
3148 (synopsis "Convert English text to humorous dialects")
3149 (description "The GNU Talk Filters are programs that convert English text
3150 into stereotyped or otherwise humorous dialects. The filters are provided as
3151 a C library, so they can easily be integrated into other programs.")
3152 (license license:gpl2+)))
3153
3154 (define-public taisei
3155 (package
3156 (name "taisei")
3157 (version "1.3.2")
3158 (source
3159 (origin
3160 (method url-fetch)
3161 (uri (string-append "https://github.com/taisei-project/"
3162 "taisei/releases/download/v" version
3163 "/taisei-v" version ".tar.xz"))
3164 (sha256
3165 (base32 "1g53fcyrlzmvlsb40pw90gaglysv6n1w42hk263iv61ibhdmzh6v"))))
3166 (build-system meson-build-system)
3167 (arguments
3168 `(#:build-type "release" ;comment out for bug-reporting (and cheats)
3169 #:configure-flags
3170 (list "-Dr_default=gles30"
3171 "-Dr_gles20=true"
3172 "-Dr_gles30=true"
3173 "-Dshader_transpiler=true")))
3174 (native-inputs
3175 (list pkg-config python python-docutils python-pygments))
3176 (inputs
3177 (list cglm
3178 freetype
3179 libpng
3180 libwebp
3181 libzip
3182 mesa
3183 openssl
3184 opusfile
3185 sdl2
3186 sdl2-mixer
3187 shaderc
3188 spirv-cross
3189 zlib))
3190 (home-page "https://taisei-project.org/")
3191 (synopsis "Shoot'em up fangame and libre clone of Touhou Project")
3192 (description
3193 "The player controls a character (one of three: Good, Bad, and Dead),
3194 dodges the missiles (lots of it cover the screen, but the character's hitbox
3195 is very small), and shoot at the adversaries that keep appear on the screen.")
3196 (license (list ;;game
3197 license:expat
3198 ;;resources/00-taisei.pkgdir/bgm/
3199 ;;atlas/portraits/
3200 license:cc-by4.0
3201 ;;miscellaneous
3202 license:cc0
3203 license:public-domain))))
3204
3205 (define-public cmatrix
3206 (package
3207 (name "cmatrix")
3208 (version "2.0")
3209 (source
3210 (origin
3211 (method git-fetch)
3212 (uri (git-reference
3213 (url "https://github.com/abishekvashok/cmatrix")
3214 (commit (string-append "v" version))))
3215 (file-name (git-file-name name version))
3216 (sha256
3217 (base32
3218 "1h9jz4m4s5l8c3figaq46ja0km1gimrkfxm4dg7mf4s84icmasbm"))))
3219 (build-system gnu-build-system)
3220 (native-inputs
3221 (list autoconf automake))
3222 (arguments
3223 '(#:phases
3224 (modify-phases %standard-phases
3225 (replace 'configure
3226 (lambda* (#:key outputs #:allow-other-keys)
3227 ;; This old ‘configure’ script doesn't support
3228 ;; variables passed as arguments.
3229 (let ((out (assoc-ref outputs "out")))
3230 (setenv "CONFIG_SHELL" (which "bash"))
3231 (invoke "./configure"
3232 (string-append "--prefix=" out))))))))
3233 (inputs (list ncurses))
3234 (home-page "http://www.asty.org/cmatrix")
3235 (synopsis "Simulate the display from \"The Matrix\"")
3236 (description "CMatrix simulates the display from \"The Matrix\" and is
3237 based on the screensaver from the movie's website. It works with terminal
3238 settings up to 132x300 and can scroll lines all at the same rate or
3239 asynchronously and at a user-defined speed.")
3240 (license license:gpl2+)))
3241
3242 (define-public chess
3243 (package
3244 (name "chess")
3245 (version "6.2.9")
3246 (source
3247 (origin
3248 (method url-fetch)
3249 (uri (string-append "mirror://gnu/chess/gnuchess-" version
3250 ".tar.gz"))
3251 (sha256
3252 (base32
3253 "140qqkmvldnf41s39khrgyzr6a0az7dcfhkcmflh0sbmvl5w5z6x"))))
3254 (build-system gnu-build-system)
3255 (arguments
3256 '(#:phases
3257 (modify-phases %standard-phases
3258 (add-after 'install 'fix-shell-scripts
3259 (lambda* (#:key outputs #:allow-other-keys)
3260 (let* ((out (assoc-ref outputs "out"))
3261 (bin (string-append out "/bin")))
3262 (chdir bin)
3263 (substitute* '("gnuchessx" "gnuchessu")
3264 (("^gnuchess") (string-append bin "/gnuchess")))))))))
3265 (home-page "https://www.gnu.org/software/chess/")
3266 (synopsis "Full chess implementation")
3267 (description "GNU Chess is a chess engine. It allows you to compete
3268 against the computer in a game of chess, either through the default terminal
3269 interface or via an external visual interface such as GNU XBoard.")
3270 (properties '((upstream-name . "gnuchess")
3271 (ftp-directory . "/chess")))
3272 (license license:gpl3+)))
3273
3274 (define-public freedink-engine
3275 (package
3276 (name "freedink-engine")
3277 (version "109.6")
3278 (source (origin
3279 (method url-fetch)
3280 (uri (string-append "mirror://gnu/freedink/freedink-" version
3281 ".tar.gz"))
3282 (patches (search-patches "freedink-engine-fix-sdl-hints.patch"))
3283 (sha256
3284 (base32
3285 "00hhk1bjdrc1np2qz44sa5n1mb62qzwxbvsnws3vpms6iyn3a2sy"))))
3286 (build-system gnu-build-system)
3287 (arguments
3288 `(#:configure-flags '("--disable-embedded-resources")
3289 #:phases
3290 (modify-phases %standard-phases
3291 (add-after 'unpack 'disable-graphical-tests
3292 (lambda _
3293 ;; These tests require a graphical interface.
3294 (substitute* "src/Makefile.am"
3295 (("test_gfx_fonts TestIOGfxDisplay") ""))
3296 #t))
3297 (add-before 'bootstrap 'autoreconf
3298 (lambda _
3299 ;; automake is out of date in the source
3300 ;; autoreconf updates the automake scripts
3301 (invoke "autoreconf")
3302 ;; Build fails when autom4te.cache exists.
3303 (delete-file-recursively "autom4te.cache")
3304 #t))
3305 (add-after 'install 'delete-freedinkedit-desktop
3306 (lambda* (#:key outputs #:allow-other-keys)
3307 (let ((out (assoc-ref outputs "out")))
3308 ;; freedinkedit does not know where to find freedink data
3309 ;; freedink data is read-only, so it cannot be edited anyway.
3310 ;; TODO: fix freedink.desktop
3311 (delete-file-recursively (string-append
3312 out "/share/applications"))
3313 #t))))))
3314 (native-inputs `(("autoconf" ,autoconf)
3315 ("automake" ,automake)
3316 ("cxxtest" ,cxxtest)
3317 ("gettext" ,gettext-minimal)
3318 ("help2man" ,help2man)
3319 ("pkg-config" ,pkg-config)))
3320 (inputs `(("sdl-union" ,(sdl-union (list sdl2 sdl2-image sdl2-mixer
3321 sdl2-ttf sdl2-gfx)))
3322 ("fontconfig" ,fontconfig)
3323 ("glm" ,glm)))
3324 (properties '((ftp-directory . "/freedink")
3325 (upstream-name . "freedink")))
3326 (home-page "https://www.gnu.org/software/freedink/")
3327 (synopsis "Twisted adventures of young pig farmer Dink Smallwood")
3328 (description
3329 "GNU FreeDink is a free and portable re-implementation of the engine
3330 for the role-playing game Dink Smallwood. It supports not only the original
3331 game data files but it also supports user-produced game mods or \"D-Mods\".
3332 To that extent, it also includes a front-end for managing all of your D-Mods.")
3333 (license license:gpl3+)))
3334
3335 (define-public freedink-data
3336 (package
3337 (name "freedink-data")
3338 (version "1.08.20190120")
3339 (source (origin
3340 (method url-fetch)
3341 (uri (string-append "mirror://gnu/freedink/freedink-data-"
3342 version ".tar.gz"))
3343 (sha256
3344 (base32
3345 "17gvryadlxk172mblbsil7hina1z5wahwaxnr6g3mdq57dvl8pvi"))))
3346 (build-system gnu-build-system)
3347 (arguments
3348 `(#:phases
3349 (modify-phases %standard-phases
3350 (delete 'configure) ; no configure script
3351 (delete 'check)) ; no tests
3352 #:make-flags (list (string-append "PREFIX=" (assoc-ref %outputs "out")))))
3353 (properties '((ftp-directory . "/freedink")))
3354 (home-page "https://www.gnu.org/software/freedink/")
3355 (synopsis "Game data for GNU Freedink")
3356 (description
3357 "This package contains the game data of GNU Freedink.")
3358 (license license:gpl3+)))
3359
3360 (define-public freedink-dfarc
3361 (package
3362 (name "freedink-dfarc")
3363 (version "3.14")
3364 (source (origin
3365 (method url-fetch)
3366 (uri (string-append "mirror://gnu/freedink/dfarc-"
3367 version ".tar.gz"))
3368 (sha256
3369 (base32
3370 "1yp8n3w426xnlp10xk06vfi2y3k9xrcfyck7s7qs1v0ys7n284d5"))))
3371 (build-system gnu-build-system)
3372 (native-inputs
3373 (list intltool))
3374 (inputs
3375 (list bzip2 wxwidgets))
3376 (properties '((ftp-directory . "/freedink")
3377 (upstream-name . "dfarc")))
3378 (home-page "https://www.gnu.org/software/freedink/")
3379 (synopsis "Front-end for managing and playing Dink Modules")
3380 (description "DFArc makes it easy to play and manage the GNU FreeDink game
3381 and its numerous D-Mods.")
3382 (license license:gpl3+)))
3383
3384 (define-public freedink
3385 ;; This is a wrapper that tells the engine where to find the data.
3386 (package (inherit freedink-engine)
3387 (name "freedink")
3388 (build-system trivial-build-system)
3389 (arguments
3390 '(#:builder (begin
3391 (use-modules (guix build utils))
3392
3393 (let* ((output (assoc-ref %outputs "out"))
3394 (bin (string-append output "/bin"))
3395 (executable (string-append bin "/freedink")))
3396 (mkdir-p bin)
3397 (call-with-output-file executable
3398 (lambda (port)
3399 (format port "#!~a/bin/sh
3400 exec ~a/bin/freedink -refdir ~a/share/dink\n"
3401 (assoc-ref %build-inputs "bash")
3402 (assoc-ref %build-inputs "engine")
3403 (assoc-ref %build-inputs "data"))
3404 (chmod port #o777)))
3405 #t))
3406 #:modules ((guix build utils))))
3407 (inputs `(("engine" ,freedink-engine)
3408 ("data" ,freedink-data)
3409 ("bash" ,bash)))
3410 (native-inputs '())))
3411
3412 (define-public xboard
3413 (package
3414 (name "xboard")
3415 (version "4.9.1")
3416 (source
3417 (origin
3418 (method url-fetch)
3419 (uri (string-append "mirror://gnu/xboard/xboard-" version
3420 ".tar.gz"))
3421 (sha256
3422 (base32
3423 "1mkh36xnnacnz9r00b5f9ld9309k32jv6mcavklbdnca8bl56bib"))))
3424 (build-system gnu-build-system)
3425 (arguments
3426 `(#:configure-flags '("CFLAGS=-fcommon")
3427 #:phases
3428 (modify-phases %standard-phases
3429 ;; Fixes https://issues.guix.gnu.org/47195.
3430 (add-after 'unpack 'patch-aplay-path
3431 (lambda* (#:key inputs #:allow-other-keys)
3432 (substitute* "xboard.conf"
3433 (("aplay -q")
3434 (string-append (search-input-file inputs "/bin/aplay")
3435 " -q")))))
3436 ;; Fixes https://issues.guix.gnu.org/45236.
3437 (add-after 'unpack 'patch-default-engine
3438 (lambda* (#:key inputs #:allow-other-keys)
3439 (substitute* "xboard.conf"
3440 (("-firstChessProgram fairymax")
3441 (string-append "-firstChessProgram "
3442 (assoc-ref inputs "chess")
3443 "/bin/gnuchessx"))))))))
3444 (inputs
3445 (list alsa-utils chess gtk+-2 librsvg))
3446 (native-inputs
3447 (list texinfo pkg-config))
3448 (home-page "https://www.gnu.org/software/xboard/")
3449 (synopsis "Graphical user interface for chess programs")
3450 (description "GNU XBoard is a graphical board for all varieties of chess,
3451 including international chess, xiangqi (Chinese chess), shogi (Japanese chess)
3452 and Makruk. Several lesser-known variants are also supported. It presents a
3453 fully interactive graphical interface and it can load and save games in the
3454 Portable Game Notation.")
3455 (license license:gpl3+)))
3456
3457 (define-public gtypist
3458 (package
3459 (name "gtypist")
3460 (version "2.9.5")
3461 (source (origin
3462 (method url-fetch)
3463 (uri (string-append "mirror://gnu/gtypist/gtypist-"
3464 version ".tar.xz"))
3465 (sha256
3466 (base32
3467 "0xzrkkmj0b1dw3yr0m9hml2y634cc4h61im6zwcq57s7285z8fn1"))
3468 (modules '((guix build utils)))
3469 (snippet
3470 ;; We do not provide `ncurses.h' within an `ncursesw'
3471 ;; sub-directory, so patch the source accordingly. See
3472 ;; <http://bugs.gnu.org/19018>.
3473 '(begin
3474 (for-each (lambda (file)
3475 (substitute* file
3476 (("ncursesw/ncurses.h")
3477 "ncurses.h")))
3478 (find-files "." "configure$|\\.c$"))
3479 #t))))
3480 (build-system gnu-build-system)
3481 (inputs (list ncurses perl))
3482 (home-page "https://www.gnu.org/software/gtypist/")
3483 (synopsis "Typing tutor")
3484 (description
3485 "GNU Typist is a universal typing tutor. It can be used to learn and
3486 practice touch-typing. Several tutorials are included; in addition to
3487 tutorials for the standard QWERTY layout, there are also tutorials for the
3488 alternative layouts Dvorak and Colemak, as well as for the numpad. Tutorials
3489 are primarily in English, however some in other languages are provided.")
3490 (license license:gpl3+)))
3491
3492 (define-public irrlicht
3493 (package
3494 (name "irrlicht")
3495 (version "1.8.4")
3496 (source (origin
3497 (method url-fetch)
3498 (uri (string-append
3499 "mirror://sourceforge/irrlicht/Irrlicht%20SDK/"
3500 (version-major+minor version)
3501 "/" version "/irrlicht-" version ".zip"))
3502 (sha256
3503 (base32
3504 "0cz4z4dwrv5ypl19ll67wl6jjpy5k6ly4vr042w4br88qq5jhazl"))
3505 (patches (search-patches "irrlicht-use-system-libs.patch"))
3506 (modules '((guix build utils)))
3507 (snippet
3508 '(begin
3509 (for-each delete-file-recursively
3510 '("bin" ; bundled compiled Windows binaries"
3511 "source/Irrlicht/MacOSX"
3512 "source/Irrlicht/bzip2"
3513 "source/Irrlicht/jpeglib"
3514 "source/Irrlicht/libpng"
3515 "source/Irrlicht/lzma"
3516 "source/Irrlicht/zlib"))
3517 (delete-file "source/Irrlicht/glext.h")
3518 (delete-file "source/Irrlicht/glxext.h")
3519 (delete-file "source/Irrlicht/wglext.h")
3520 #t))))
3521 (build-system gnu-build-system)
3522 (arguments
3523 `(#:phases
3524 (modify-phases %standard-phases
3525 (add-after 'unpack 'chdir-to-source
3526 (lambda _
3527 ;; The actual source is buried a few directories deep.
3528 (chdir "source/Irrlicht/")
3529 #t))
3530 (add-after 'chdir-to-source 'remove-<sys/sysctl.h>
3531 (lambda _
3532 (substitute* "COSOperator.cpp"
3533 (("#include <sys/sysctl.h>") ""))))
3534 (add-after 'chdir-to-source 'fix-build-env
3535 (lambda* (#:key outputs #:allow-other-keys)
3536 (let ((out (assoc-ref outputs "out")))
3537 (substitute* "Makefile"
3538 (("INSTALL_DIR = /usr/local/lib")
3539 (string-append "INSTALL_DIR = " out "/lib"))
3540 ;; Add '-fpermissive' to the CXXFLAGS
3541 (("-Wall") "-Wall -fpermissive")) ; CImageLoaderJPG.cpp
3542 ;; The Makefile assumes these directories exist.
3543 (mkdir-p (string-append out "/lib"))
3544 (mkdir-p (string-append out "/include")))))
3545 (delete 'configure)) ; no configure script
3546 #:tests? #f ; no check target
3547 #:make-flags '("CC=gcc" "sharedlib")))
3548 (inputs
3549 `(("bzip2" ,bzip2)
3550 ("libjpeg" ,libjpeg-turbo)
3551 ("libpng" ,libpng)
3552 ("libx11" ,libx11)
3553 ("libxxf86vm" ,libxxf86vm)
3554 ("mesa" ,mesa)))
3555 (synopsis "3D game engine written in C++")
3556 (description
3557 "The Irrlicht Engine is a high performance realtime 3D engine written in
3558 C++. Features include an OpenGL renderer, extensible materials, scene graph
3559 management, character animation, particle and other special effects, support
3560 for common mesh file formats, and collision detection.")
3561 (home-page "https://irrlicht.sourceforge.io/")
3562 (license license:zlib)))
3563
3564 (define-public mars
3565 ;; The latest release on SourceForge relies on an unreleased version of SFML
3566 ;; with a different API, so we take the latest version from the official
3567 ;; repository on Github.
3568 (let ((commit "c855d044094a1d92317e38935d81ba938946132e")
3569 (revision "1"))
3570 (package
3571 (name "mars")
3572 (version (string-append "0.7.5." revision "." (string-take commit 7) ))
3573 (source (origin
3574 (method git-fetch)
3575 (uri (git-reference
3576 (url "https://github.com/thelaui/M.A.R.S.")
3577 (commit commit)))
3578 (file-name (git-file-name name version))
3579 (sha256
3580 (base32
3581 "1r4c5gap1z2zsv4yjd34qriqkxaq4lb4rykapyzkkdf4g36lc3nh"))
3582 (patches (search-patches "mars-sfml-2.3.patch"
3583 "mars-install.patch"))))
3584 (build-system cmake-build-system)
3585 (arguments
3586 `(#:tests? #f ; There are no tests
3587 #:phases
3588 (modify-phases %standard-phases
3589 (add-after 'unpack 'fix-install-path
3590 (lambda _
3591 (substitute* "src/CMakeLists.txt"
3592 (("\\$\\{CMAKE_INSTALL_PREFIX\\}/games")
3593 "${CMAKE_INSTALL_PREFIX}/bin"))
3594 #t))
3595 (add-after 'unpack 'fix-data-path
3596 (lambda* (#:key outputs #:allow-other-keys)
3597 (substitute* "src/System/settings.cpp"
3598 (("C_dataPath = \"./data/\";")
3599 (string-append "C_dataPath = \""
3600 (assoc-ref outputs "out")
3601 "/share/games/marsshooter/\";")))
3602 #t)))))
3603 (inputs
3604 (list mesa fribidi taglib sfml))
3605 (home-page "http://mars-game.sourceforge.net/")
3606 (synopsis "2D space shooter")
3607 (description
3608 "M.A.R.S. is a 2D space shooter with pretty visual effects and
3609 attractive physics. Players can battle each other or computer controlled
3610 enemies in different game modes such as space ball, death match, team death
3611 match, cannon keep, and grave-itation pit.")
3612 (license license:gpl3+))))
3613
3614 (define glkterm
3615 (package
3616 (name "glkterm")
3617 (version "1.0.4")
3618 (source
3619 (origin
3620 (method url-fetch)
3621 (uri (string-append "http://www.ifarchive.org/if-archive/programming/"
3622 "glk/implementations/glkterm-104.tar.gz"))
3623 (sha256
3624 (base32
3625 "0zlj9nlnkdlvgbiliczinirqygiq8ikg5hzh5vgcmnpg9pvnwga7"))))
3626 (build-system gnu-build-system)
3627 (propagated-inputs `(("ncurses" ,ncurses))) ; required by Make.glkterm
3628 (arguments
3629 '(#:tests? #f ; no check target
3630 #:phases
3631 (modify-phases %standard-phases
3632 (replace 'install
3633 (lambda* (#:key outputs #:allow-other-keys)
3634 (let* ((out (assoc-ref outputs "out"))
3635 (inc (string-append out "/include"))
3636 (lib (string-append out "/lib")))
3637 (for-each
3638 (lambda (file)
3639 (install-file file inc))
3640 '("glk.h" "glkstart.h" "gi_blorb.h" "gi_dispa.h" "Make.glkterm"))
3641 (install-file "libglkterm.a" lib))
3642 #t))
3643 (delete 'configure)))) ; no configure script
3644 (home-page "http://www.eblong.com/zarf/glk/")
3645 (synopsis "Curses Implementation of the Glk API")
3646 (description
3647 "Glk defines a portable API for applications with text UIs. It was
3648 primarily designed for interactive fiction, but it should be suitable for many
3649 interactive text utilities, particularly those based on a command line.
3650 This is an implementation of the Glk library which runs in a terminal window,
3651 using the @code{curses.h} library for screen control.")
3652 (license (license:fsf-free "file://README"))))
3653
3654 (define-public glulxe
3655 (package
3656 (name "glulxe")
3657 (version "0.5.4")
3658 (source
3659 (origin
3660 (method url-fetch)
3661 (uri (string-append "http://www.ifarchive.org/if-archive/programming/"
3662 "glulx/interpreters/glulxe/glulxe-054.tar.gz"))
3663 (sha256
3664 (base32
3665 "0vipydg6ra90yf9b3ipgppwxyb2xdhcxwvirgjy0v20wlf56zhhz"))))
3666 (build-system gnu-build-system)
3667 (inputs `(("glk" ,glkterm)))
3668 (arguments
3669 '(#:tests? #f ; no check target
3670 #:make-flags
3671 (let* ((glk (assoc-ref %build-inputs "glk")))
3672 (list (string-append "GLKINCLUDEDIR=" glk "/include")
3673 (string-append "GLKLIBDIR=" glk "/lib")
3674 (string-append "GLKMAKEFILE=" "Make.glkterm")))
3675 #:phases
3676 (modify-phases %standard-phases
3677 (replace 'install
3678 (lambda* (#:key outputs #:allow-other-keys)
3679 (let* ((out (assoc-ref outputs "out"))
3680 (bin (string-append out "/bin")))
3681 (install-file "glulxe" bin))
3682 #t))
3683 (delete 'configure)))) ; no configure script
3684 (home-page "https://www.eblong.com/zarf/glulx/")
3685 (synopsis "Interpreter for Glulx VM")
3686 (description
3687 "Glulx is a 32-bit portable virtual machine intended for writing and
3688 playing interactive fiction. It was designed by Andrew Plotkin to relieve
3689 some of the restrictions in the venerable Z-machine format. This is the
3690 reference interpreter, using the Glk API.")
3691 (license license:expat)))
3692
3693 (define-public fifechan
3694 (package
3695 (name "fifechan")
3696 (version "0.1.5")
3697 (source (origin
3698 (method url-fetch)
3699 (uri (string-append "https://codeload.github.com/fifengine/"
3700 "fifechan/tar.gz/" version))
3701 (file-name (string-append name "-" version ".tar.gz"))
3702 (sha256
3703 (base32
3704 "0wxs9vz5x9y8chghd8vp7vfk089lfb0qnzggi17zrqkrngs5zgi9"))))
3705 (build-system cmake-build-system)
3706 (inputs
3707 (list sdl2 sdl2-image mesa))
3708 (arguments
3709 '(#:tests? #f)) ; No included tests
3710 (home-page "https://fifengine.github.io/fifechan/")
3711 (synopsis "Cross platform GUI library specifically for games")
3712 (description
3713 "Fifechan is a lightweight cross platform GUI library written in C++
3714 specifically designed for games. It has a built in set of extendable GUI
3715 Widgets, and allows users to create more.")
3716 (license license:lgpl2.1+)))
3717
3718 (define-public fifengine
3719 (package
3720 (name "fifengine")
3721 (version "0.4.2")
3722 (source (origin
3723 (method url-fetch)
3724 (uri (string-append "https://codeload.github.com/fifengine/"
3725 "fifengine/tar.gz/" version))
3726 (file-name (string-append name "-" version ".tar.gz"))
3727 (patches (search-patches "fifengine-swig-compat.patch"))
3728 (sha256
3729 (base32
3730 "1y4grw25cq5iqlg05rnbyxw1njl11ypidnlsm3qy4sm3xxdvb0p8"))))
3731 (build-system cmake-build-system)
3732 (arguments
3733 `(#:tests? #f ; TODO The test running fails to run some tests.
3734 #:imported-modules ,(cons '(guix build python-build-system)
3735 %cmake-build-system-modules)
3736 #:modules ((guix build cmake-build-system)
3737 ((guix build python-build-system) #:select (guix-pythonpath))
3738 (guix build utils)
3739 (srfi srfi-1))
3740 #:configure-flags
3741 (list
3742 (string-append "-DOPENALSOFT_INCLUDE_DIR="
3743 (assoc-ref %build-inputs "openal")
3744 "/include/AL")
3745 (string-append "-DPYTHON_SITE_PACKAGES="
3746 (assoc-ref %outputs "out")
3747 "/lib/python"
3748 ,(version-major+minor (package-version python))
3749 "/site-packages"))
3750 #:phases
3751 (modify-phases %standard-phases
3752 (add-after 'unpack 'patch-run_tests.py
3753 (lambda _
3754 ;; Patch the test runner to exit with a status of 1 if any test
3755 ;; fails, to allow detecting failures.
3756 (substitute* "run_tests.py"
3757 (("ERROR\\. One or more tests failed!'\\)")
3758 "ERROR. One or more tests failed!')
3759 \t\texit(1)"))
3760 #t))
3761 ;; Run tests after installation so that we can make use of the built
3762 ;; python modules.
3763 (delete 'check)
3764 (add-after 'install 'check
3765 (lambda* (#:key inputs outputs tests? #:allow-other-keys)
3766 (when tests?
3767 (add-installed-pythonpath inputs outputs)
3768 ;; The tests require an X server.
3769 (system "Xvfb :1 &")
3770 (setenv "DISPLAY" ":1")
3771 (setenv "XDG_RUNTIME_DIR" "/tmp")
3772 ;; Run tests
3773 (chdir ,(string-append "../" name "-" version))
3774 (invoke "python3" "run_tests.py" "-a")))))))
3775 (inputs
3776 (list sdl2
3777 sdl2-image
3778 sdl2-ttf
3779 tinyxml
3780 openal
3781 libogg
3782 glew
3783 libvorbis
3784 boost
3785 fifechan
3786 swig
3787 python))
3788 (native-inputs
3789 `(("python" ,python)
3790 ("swig" ,swig)
3791 ("xvfb" ,xorg-server)))
3792 (propagated-inputs
3793 (list python-future))
3794 (home-page "https://www.fifengine.net/")
3795 (synopsis "FIFE is a multi-platform isometric game engine written in C++")
3796 (description
3797 "@acronym{FIFE, Flexible Isometric Free Engine} is a multi-platform
3798 isometric game engine. Python bindings are included allowing users to create
3799 games using Python as well as C++.")
3800 (license license:lgpl2.1+)))
3801
3802 (define-public fizmo
3803 (package
3804 (name "fizmo")
3805 (version "0.8.5")
3806 (source (origin
3807 (method url-fetch)
3808 (uri (string-append "https://fizmo.spellbreaker.org/source/"
3809 "fizmo-" version ".tar.gz"))
3810 (sha256
3811 (base32
3812 "1amyc4n41jf08kxmdgkk30bzzx54miaxa97w28f417qwn8lrl98w"))))
3813 (build-system gnu-build-system)
3814 (arguments
3815 '(#:configure-flags
3816 (let ((libjpeg (assoc-ref %build-inputs "libjpeg"))
3817 (ncurses (assoc-ref %build-inputs "ncurses")))
3818 (list (string-append "--with-jpeg-includedir=" libjpeg "/include")))))
3819 (native-inputs
3820 (list pkg-config))
3821 (inputs
3822 `(("freetype" ,freetype)
3823 ("libjpeg" ,libjpeg-turbo)
3824 ("libpng" ,libpng)
3825 ("libsndfile" ,libsndfile)
3826 ("libxml2" ,libxml2)
3827 ("ncurses" ,ncurses)
3828 ("sdl2" ,sdl2)))
3829 (home-page "https://fizmo.spellbreaker.org/")
3830 (synopsis "Z-machine interpreter")
3831 (description
3832 "Fizmo is a console-based Z-machine interpreter. It is used to play
3833 interactive fiction, also known as text adventures, which were implemented
3834 either by Infocom or created using the Inform compiler.")
3835 (license license:bsd-3)))
3836
3837 (define-public gnugo
3838 (package
3839 (name "gnugo")
3840 (version "3.8")
3841 (source (origin
3842 (method url-fetch)
3843 (uri (string-append "mirror://gnu/gnugo/gnugo-" version
3844 ".tar.gz"))
3845 (sha256
3846 (base32
3847 "0wkahvqpzq6lzl5r49a4sd4p52frdmphnqsfdv7gdp24bykdfs6s"))))
3848 (build-system gnu-build-system)
3849 (inputs
3850 (list readline))
3851 (arguments
3852 `(#:configure-flags '("CFLAGS=-fcommon")))
3853 (synopsis "Play the game of Go")
3854 (description
3855 "GNU Go is a program that plays the game of Go, in which players
3856 place stones on a grid to form territory or capture other stones. While
3857 it can be played directly from the terminal, rendered in ASCII characters,
3858 it is also possible to play GNU Go with 3rd party graphical interfaces or
3859 even in Emacs. It supports the standard game storage format (SGF, Smart
3860 Game Format) and inter-process communication format (GMP, Go Modem
3861 Protocol).")
3862 (home-page "https://www.gnu.org/software/gnugo/")
3863 (license license:gpl3+)))
3864
3865 (define-public extremetuxracer
3866 (package
3867 (name "extremetuxracer")
3868 (version "0.8.1")
3869 (source (origin
3870 (method url-fetch)
3871 (uri (string-append
3872 "mirror://sourceforge/extremetuxracer/releases/"
3873 version "/etr-" version ".tar.xz"))
3874 (sha256
3875 (base32
3876 "0hc3qd9hv3h9qm53yxgc7iy1v1wyajwxyvil4vqvzf9ascz9dnlj"))))
3877 (build-system gnu-build-system)
3878 (native-inputs
3879 (list pkg-config))
3880 (inputs
3881 (list glu sfml))
3882 (synopsis "High-speed arctic racing game based on Tux Racer")
3883 ;; Snarfed straight from Debian.
3884 (description "Extreme Tux Racer, or etracer as it is called for short, is
3885 a simple OpenGL racing game featuring Tux, the Linux mascot. The goal of the
3886 game is to slide down a snow- and ice-covered mountain as quickly as possible,
3887 avoiding the trees and rocks that will slow you down.
3888
3889 Collect herrings and other goodies while sliding down the hill, but avoid fish
3890 bones.
3891
3892 This game is based on the GPL version of the famous game TuxRacer.")
3893 (home-page "https://sourceforge.net/projects/extremetuxracer/")
3894 (license license:gpl2+)))
3895
3896 (define-public supertuxkart
3897 (package
3898 (name "supertuxkart")
3899 (version "1.3")
3900 (source
3901 (origin
3902 (method url-fetch)
3903 (uri (string-append "https://github.com/supertuxkart/stk-code/"
3904 "releases/download/"
3905 version "/SuperTuxKart-" version "-src.tar.xz"))
3906 (sha256
3907 (base32
3908 "1z9z13zarv28h4jrmjna5hr6m9266pm7c2kgiwhqls01k06ypazf"))
3909 (modules '((guix build utils)))
3910 (snippet
3911 ;; Delete bundled library sources
3912 '(begin
3913 ;; Supertuxkart uses modified versions of the Irrlicht engine
3914 ;; and the bullet library. The developers gave an explanation
3915 ;; here: http://forum.freegamedev.net/viewtopic.php?f=17&t=3906
3916 ;; FIXME: try to unbundle angelscript, libmcpp and libraqm
3917 (for-each delete-file-recursively
3918 '("lib/dnsc"
3919 "lib/enet"
3920 "lib/mojoal"
3921 "lib/wiiuse"))
3922 #t))))
3923 (build-system cmake-build-system)
3924 (arguments
3925 `(#:tests? #f ; no check target
3926 #:configure-flags
3927 (list "-DUSE_WIIUSE=0"
3928 "-DUSE_SYSTEM_ENET=TRUE"
3929 "-DUSE_CRYPTO_OPENSSL=TRUE"
3930 ;; In order to use the system ENet library, IPv6 support (added in
3931 ;; SuperTuxKart version 1.1) must be disabled.
3932 "-DUSE_IPV6=FALSE"
3933 ;; FIXME: needs libopenglrecorder
3934 "-DBUILD_RECORDER=0")))
3935 (inputs
3936 `(("curl" ,curl)
3937 ("freetype" ,freetype)
3938 ("fribidi" ,fribidi)
3939 ("glew" ,glew)
3940 ("harfbuzz" ,harfbuzz)
3941 ("libvorbis" ,libvorbis)
3942 ("libx11" ,libx11)
3943 ("libxrandr" ,libxrandr)
3944 ("mesa" ,mesa)
3945 ("openal" ,openal)
3946 ("sdl2" ,sdl2)
3947 ("sqlite" ,sqlite)
3948 ("zlib" ,zlib)
3949 ;; The following input is needed to build the bundled and modified
3950 ;; version of irrlicht.
3951 ("enet" ,enet)
3952 ("libjpeg" ,libjpeg-turbo)
3953 ("openssl" ,openssl)))
3954 (native-inputs
3955 (list pkg-config))
3956 (home-page "https://supertuxkart.net/Main_Page")
3957 (synopsis "3D kart racing game")
3958 (description "SuperTuxKart is a 3D kart racing game, with a focus on
3959 having fun over realism. You can play with up to 4 friends on one PC, racing
3960 against each other or just trying to beat the computer; single-player mode is
3961 also available.")
3962 (license license:gpl3+)))
3963
3964 (define-public unknown-horizons
3965 (package
3966 (name "unknown-horizons")
3967 (version "2019.1")
3968 (source (origin
3969 (method url-fetch)
3970 (uri (string-append "https://codeload.github.com/unknown-horizons/"
3971 "unknown-horizons/tar.gz/" version))
3972 (file-name (string-append name "-" version ".tar.gz"))
3973 (sha256
3974 (base32
3975 "1n747p7h0qp48szgp262swg0xh8kxy1bw8ag1qczs4i26hyzs5x4"))
3976 (patches (search-patches "unknown-horizons-python-3.8-distro.patch"))))
3977 (build-system python-build-system)
3978 (arguments
3979 '(#:phases
3980 (modify-phases %standard-phases
3981 (add-before 'build 'set-HOME
3982 (lambda _
3983 (setenv "HOME" "/tmp")
3984 #t))
3985 (add-after 'build 'build-extra
3986 (lambda _
3987 (invoke "python3" "./setup.py" "build_i18n")
3988 (invoke "python3" "horizons/engine/generate_atlases.py" "2048")
3989 #t))
3990 (add-after 'install 'patch
3991 (lambda* (#:key outputs #:allow-other-keys)
3992 (let ((out (assoc-ref outputs "out")))
3993 (substitute* (string-append out "/bin/unknown-horizons")
3994 (("os\\.chdir\\(get\\_content\\_dir\\_parent_path\\(\\)\\)")
3995 (string-append "os.chdir(\""
3996 (assoc-ref outputs "out")
3997 "/share/unknown-horizons\")"))))
3998 #t))
3999 (add-before 'check 'fix-tests-with-pytest>=4
4000 (lambda _
4001 (substitute* "tests/conftest.py"
4002 (("pytest_namespace")
4003 "pytest_configure")
4004 (("get_marker")
4005 "get_closest_marker"))
4006 #t))
4007 ;; TODO: Run GUI tests as well
4008 (replace 'check
4009 (lambda _
4010 (substitute* "horizons/constants.py"
4011 (("IS_DEV_VERSION = False")
4012 "IS_DEV_VERSION = True"))
4013 (invoke "pytest" "tests")
4014 (substitute* "horizons/constants.py"
4015 (("IS_DEV_VERSION = True")
4016 "IS_DEV_VERSION = False"))
4017 #t)))))
4018 (inputs
4019 `(("fifengine" ,fifengine)
4020 ("python:tk" ,python "tk")
4021 ("python-pillow" ,python-pillow)
4022 ("python-pyyaml" ,python-pyyaml)))
4023 (native-inputs
4024 (list intltool
4025 python-distro
4026 ;; Required for tests
4027 python-greenlet
4028 python-polib
4029 python-pytest
4030 python-pytest-mock))
4031 (home-page "https://unknown-horizons.org/")
4032 (synopsis "Isometric realtime strategy, economy and city building simulation")
4033 (description
4034 "Unknown Horizons is a 2D realtime strategy simulation with an emphasis
4035 on economy and city building. Expand your small settlement to a strong and
4036 wealthy colony, collect taxes and supply your inhabitants with valuable
4037 goods. Increase your power with a well balanced economy and with strategic
4038 trade and diplomacy.")
4039 (license (list
4040 license:gpl2+ ; Covers code
4041 license:expat ; tests/dummy.py, ext/polib.py
4042 license:cc-by-sa3.0 ; Covers some media content
4043 license:cc-by3.0 ; Covers some media content
4044 license:bsd-3)))) ; horizons/ext/speaklater.py
4045
4046 (define-public gnujump
4047 (package
4048 (name "gnujump")
4049 (version "1.0.8")
4050 (source (origin
4051 (method url-fetch)
4052 (uri (string-append "mirror://gnu/gnujump/gnujump-"
4053 version ".tar.gz"))
4054 (sha256
4055 (base32
4056 "05syy9mzbyqcfnm0hrswlmhwlwx54f0l6zhcaq8c1c0f8dgzxhqk"))))
4057 (build-system gnu-build-system)
4058 (arguments
4059 '(#:phases
4060 (modify-phases %standard-phases
4061 (add-before
4062 'configure 'link-libm
4063 (lambda _ (setenv "LIBS" "-lm")))
4064 (add-after 'install 'create-desktop-entry
4065 (lambda* (#:key outputs #:allow-other-keys)
4066 (let* ((out (assoc-ref outputs "out"))
4067 (apps (string-append out "/share/applications")))
4068 (mkdir-p apps)
4069 (with-output-to-file
4070 (string-append apps "/gnujump.desktop")
4071 (lambda _
4072 (format #t
4073 "[Desktop Entry]~@
4074 Name=GNUjump~@
4075 Comment=Jump up the tower to survive~@
4076 Exec=~a/bin/gnujump~@
4077 Terminal=false~@
4078 Type=Application~@
4079 Categories=Game;ArcadeGame~%"
4080 out)))))))))
4081 (inputs
4082 (list glu mesa sdl sdl-image sdl-mixer))
4083 (home-page "http://gnujump.es.gnu.org/")
4084 (synopsis
4085 "Game of jumping to the next floor, trying not to fall")
4086 (description
4087 "GNUjump is a simple, yet addictive game in which you must jump from
4088 platform to platform to avoid falling, while the platforms drop at faster rates
4089 the higher you go. The game features multiplayer, unlimited FPS, smooth floor
4090 falling, themeable graphics and sounds, and replays.")
4091 (license license:gpl3+)))
4092
4093 (define-public wesnoth
4094 (package
4095 (name "wesnoth")
4096 (version "1.16.1")
4097 (source (origin
4098 (method url-fetch)
4099 (uri (string-append "mirror://sourceforge/wesnoth/wesnoth-"
4100 (version-major+minor version)
4101 "/wesnoth-" version "/"
4102 "wesnoth-" version ".tar.bz2"))
4103 (sha256
4104 (base32
4105 "0cyrwmdg93pqpdm7030540jznaky9rda355i9ym8am4k9civlcwf"))))
4106 (build-system cmake-build-system)
4107 (arguments
4108 `(#:tests? #f)) ;no check target
4109 (native-inputs
4110 `(("gettext" ,gettext-minimal)
4111 ("pkg-config" ,pkg-config)))
4112 (inputs
4113 (list boost
4114 dbus
4115 fribidi
4116 libvorbis
4117 openssl
4118 pango
4119 (sdl-union (list sdl2 sdl2-image sdl2-mixer sdl2-ttf))))
4120 (home-page "https://www.wesnoth.org/")
4121 (synopsis "Turn-based strategy game")
4122 (description
4123 "The Battle for Wesnoth is a fantasy, turn based tactical strategy game,
4124 with several single player campaigns, and multiplayer games (both networked and
4125 local).
4126
4127 Battle for control on a range of maps, using variety of units which have
4128 advantages and disadvantages against different types of attacks. Units gain
4129 experience and advance levels, and are carried over from one scenario to the
4130 next campaign.")
4131 (license license:gpl2+)))
4132
4133 (define-public wesnoth-server
4134 (package
4135 (inherit wesnoth)
4136 (name "wesnoth-server")
4137 (inputs
4138 (list boost icu4c openssl sdl2))
4139 (arguments
4140 `(#:configure-flags '("-DENABLE_GAME=OFF")
4141 ,@(package-arguments wesnoth)))
4142 (synopsis "Dedicated @emph{Battle for Wesnoth} server")
4143 (description "This package contains a dedicated server for @emph{The
4144 Battle for Wesnoth}.")))
4145
4146 (define-public gamine
4147 (package
4148 (name "gamine")
4149 (version "1.6")
4150 (source (origin
4151 (method url-fetch)
4152 (uri (string-append "mirror://sourceforge/gamine-game/"
4153 "gamine-" version ".tar.gz"))
4154 (sha256
4155 (base32
4156 "1sc6f4445ciigd6yw0ri92746k4hk6ps0bvj9fm1gbp3c3fslk5n"))))
4157 (build-system gnu-build-system)
4158 (native-inputs
4159 (list pkg-config intltool))
4160 (inputs
4161 (list gstreamer
4162 gst-plugins-base ; playbin plugin
4163 gst-plugins-good ; for wav playback
4164 gtk+))
4165 (arguments
4166 `(#:tests? #f
4167 #:make-flags
4168 (let ((out (assoc-ref %outputs "out")))
4169 (list (string-append "PREFIX=" out)
4170 (string-append "SYSCONFDIR=" out "/etc")))
4171 #:phases
4172 (modify-phases %standard-phases
4173 (delete 'configure)
4174 (add-after
4175 'install 'wrap-gamine
4176 (lambda* (#:key outputs #:allow-other-keys)
4177 (let ((out (assoc-ref outputs "out"))
4178 (gst-plugin-path (getenv "GST_PLUGIN_SYSTEM_PATH")))
4179 (wrap-program (string-append out "/bin/gamine")
4180 `("GST_PLUGIN_SYSTEM_PATH" ":" prefix (,gst-plugin-path))))
4181 #t)))))
4182 (home-page "http://gamine-game.sourceforge.net/")
4183 (synopsis "Mouse and keyboard discovery for children")
4184 (description
4185 "Gamine is a game designed for young children who are learning to use the
4186 mouse and keyboard. The child uses the mouse to draw colored dots and lines
4187 on the screen and keyboard to display letters.")
4188 ;; Most files under gpl2+ or gpl3+, but eat.wav under gpl3
4189 (license license:gpl3)))
4190
4191 (define-public manaplus
4192 (package
4193 (name "manaplus")
4194 (version "1.9.3.23")
4195 (source (origin
4196 (method url-fetch)
4197 (uri (string-append
4198 "https://repo.manaplus.org/manaplus/download/"
4199 version "/manaplus-" version ".tar.xz"))
4200 (sha256
4201 (base32
4202 "1ky182p4svwdqm6cf7jbns85hidkhkhq4s17cs2p381f0klapfjz"))))
4203 (build-system gnu-build-system)
4204 (arguments
4205 '(#:configure-flags
4206 (list (string-append "CPPFLAGS=-I"
4207 (assoc-ref %build-inputs "sdl-union")
4208 "/include/SDL"))))
4209 (native-inputs
4210 (list pkg-config))
4211 (inputs
4212 (list glu curl libxml2 mesa
4213 (sdl-union)))
4214 (home-page "https://manaplus.org")
4215 (synopsis "Client for 'The Mana World' and similar games")
4216 (description
4217 "ManaPlus is a 2D MMORPG client for game servers. It is the only
4218 fully supported client for @uref{http://www.themanaworld.org, The mana
4219 world}, @uref{http://evolonline.org, Evol Online} and
4220 @uref{http://landoffire.org, Land of fire}.")
4221 ;; "src/debug/*" and "src/sdl2gfx/*" are under Zlib.
4222 ;; "data/themes/{golden-delicious,jewelry}/*" are under CC-BY-SA.
4223 ;; The rest is under GPL2+.
4224 (license (list license:gpl2+ license:zlib license:cc-by-sa4.0))))
4225
4226 (define openttd-engine
4227 (package
4228 (name "openttd-engine")
4229 (version "12.0")
4230 (source
4231 (origin (method url-fetch)
4232 (uri (string-append "https://cdn.openttd.org/openttd-releases/"
4233 version "/openttd-" version "-source.tar.xz"))
4234 (sha256
4235 (base32
4236 "1p1j5cf4ry57dcgm7qx2g2s00z1c6qgjabb4kqjp00yz00wgv85v"))))
4237 (build-system cmake-build-system)
4238 (inputs
4239 `(("allegro" ,allegro)
4240 ("fontconfig" ,fontconfig)
4241 ("freetype" ,freetype)
4242 ("icu4c" ,icu4c)
4243 ("libpng" ,libpng)
4244 ("lzo" ,lzo)
4245 ("sdl" ,sdl)
4246 ("xz" ,xz)
4247 ("zlib" ,zlib)))
4248 (synopsis "Transportation economics simulator game")
4249 (description "OpenTTD is a game in which you transport goods and
4250 passengers by land, water and air. It is a re-implementation of Transport
4251 Tycoon Deluxe with many enhancements including multiplayer mode,
4252 internationalization support, conditional orders and the ability to clone,
4253 autoreplace and autoupdate vehicles. This package only includes the game
4254 engine. When you start it you will be prompted to download a graphics set.")
4255 (home-page "https://www.openttd.org/")
4256 ;; This package is GPLv2, except for a few files located in
4257 ;; "src/3rdparty/" which are under the 3-clause BSD, LGPLv2.1+ and Zlib
4258 ;; licenses. In addition, this software contains an in-game downloader
4259 ;; from which the user may find non-functional data licensed under
4260 ;; different terms.
4261 (license (list license:bsd-3 license:gpl2 license:lgpl2.1+ license:zlib))))
4262
4263 (define openttd-opengfx
4264 (package
4265 (name "openttd-opengfx")
4266 (version "7.1")
4267 (source
4268 (origin
4269 (method url-fetch)
4270 (uri (string-append "https://cdn.openttd.org/opengfx-releases/"
4271 version "/opengfx-" version "-source.tar.xz"))
4272 (sha256
4273 (base32
4274 "0nhzlk6s73qvznm5fdwcs1b42g2plf26s5ag39fvck45zm7m48jk"))))
4275 (build-system gnu-build-system)
4276 (arguments
4277 `(#:make-flags (list (string-append "CC=" ,(cc-for-target))
4278 (string-append "INSTALL_DIR="
4279 (assoc-ref %outputs "out")
4280 "/share/games/openttd/baseset/opengfx"))
4281 #:phases
4282 (modify-phases %standard-phases
4283 (replace 'configure
4284 (lambda _
4285 ;; Make sure HOME is writable for GIMP.
4286 (setenv "HOME" (getcwd))
4287
4288 ;; Redirect stdout, not stderr, to /dev/null. This prevents
4289 ;; dos2unix from receiving its version information as a flag.
4290 (substitute* "Makefile"
4291 (("\\$\\(UNIX2DOS\\) -q --version 2>/dev/null")
4292 "$(UNIX2DOS) -q --version 1>/dev/null")))))
4293 ;; The check phase for this package only checks the md5sums of the built
4294 ;; GRF files against the md5sums of the release versions. Because we use
4295 ;; different software versions than upstream does, some of the md5sums
4296 ;; are different. However, the package is still reproducible, it's safe
4297 ;; to disable this test.
4298 #:tests? #f
4299 #:parallel-build? #f))
4300 (native-inputs `(("dos2unix" ,dos2unix)
4301 ("gimp" ,gimp)
4302 ("grfcodec" ,grfcodec)
4303 ("nml" ,nml)
4304 ("which" ,which)
4305 ("python" ,python)))
4306 (home-page "http://dev.openttdcoop.org/projects/opengfx")
4307 (synopsis "Base graphics set for OpenTTD")
4308 (description
4309 "The OpenGFX project is an implementation of the OpenTTD base graphics
4310 set that aims to ensure the best possible out-of-the-box experience.
4311
4312 OpenGFX provides you with...
4313 @enumerate
4314 @item All graphics you need to enjoy OpenTTD.
4315 @item Uniquely drawn rail vehicles for every climate.
4316 @item Completely snow-aware rivers.
4317 @item Different river and sea water.
4318 @item Snow-aware buoys.
4319 @end enumerate")
4320 (license license:gpl2)))
4321
4322 (define openttd-opensfx
4323 (package
4324 (name "openttd-opensfx")
4325 (version "1.0.2")
4326 (source
4327 (origin
4328 (method url-fetch)
4329 (uri (string-append
4330 "https://cdn.openttd.org/opensfx-releases/"
4331 version "/opensfx-" version "-source.tar.xz"))
4332 (sha256
4333 (base32
4334 "0aym026lg0r7dp3jxxs9c0rj8lwy1fz3v9hmk3mml6sycsg3fv42"))))
4335 (build-system gnu-build-system)
4336 (native-inputs
4337 `(("catcodec" ,catcodec)
4338 ("python" ,python)
4339 ("tar" ,tar)))
4340 (arguments
4341 `(#:make-flags
4342 (list (string-append "DIR_NAME=opensfx")
4343 (string-append "TAR="
4344 (search-input-file %build-inputs "/bin/tar")))
4345 ;; The check phase only verifies md5sums, see openttd-opengfx.
4346 #:tests? #f
4347 #:phases
4348 (modify-phases %standard-phases
4349 (add-after 'unpack 'make-reproducible
4350 (lambda _
4351 ;; Remove the time dependency of the installed tarball by setting
4352 ;; the modification times if its members to 0.
4353 (substitute* "scripts/Makefile.def"
4354 (("-cf") " --mtime=@0 -cf"))
4355 #t))
4356 (delete 'configure)
4357 (add-before 'build 'prebuild
4358 (lambda _ (invoke "make" "opensfx.cat")))
4359 (replace 'install
4360 (lambda* (#:key outputs #:allow-other-keys)
4361 (copy-recursively "opensfx"
4362 (string-append (assoc-ref outputs "out")
4363 "/share/games/openttd/baseset"
4364 "/opensfx")))))))
4365 (home-page "http://dev.openttdcoop.org/projects/opensfx")
4366 (synopsis "Base sounds for OpenTTD")
4367 (description "OpenSFX is a set of free base sounds for OpenTTD which make
4368 it possible to play OpenTTD without requiring the proprietary sound files from
4369 the original Transport Tycoon Deluxe.")
4370 (license license:cc-by-sa3.0)))
4371
4372 (define openttd-openmsx
4373 (package
4374 (name "openttd-openmsx")
4375 (version "0.4.2")
4376 (source
4377 (origin
4378 (method url-fetch)
4379 (uri (string-append
4380 "https://cdn.openttd.org/openmsx-releases/"
4381 version "/openmsx-" version "-source.tar.xz"))
4382 (sha256
4383 (base32
4384 "0h583d8fxy78kc3jvpp78r76a48qhxrhm4q7jbnj74aw0kwrcl8g"))))
4385 (build-system gnu-build-system)
4386 (native-inputs
4387 `(("grfcodec" ,grfcodec)
4388 ; Scripts are Python3 compatible, but call the interpreter as
4389 ; python instead of python3.
4390 ("python" ,python-wrapper)
4391 ("tar" ,tar)))
4392 (arguments
4393 `(#:make-flags
4394 (list (string-append "DIR_NAME=openmsx")
4395 (string-append "TAR="
4396 (search-input-file %build-inputs "/bin/tar")))
4397 ;; The check phase only verifies md5sums, see openttd-opengfx.
4398 #:tests? #f
4399 #:phases
4400 (modify-phases %standard-phases
4401 (delete 'configure)
4402 (replace 'install
4403 (lambda* (#:key outputs #:allow-other-keys)
4404 (copy-recursively "openmsx"
4405 (string-append (assoc-ref outputs "out")
4406 "/share/games/openttd/baseset"
4407 "/openmsx")))))))
4408 (home-page "http://dev.openttdcoop.org/projects/openmsx")
4409 (synopsis "Music set for OpenTTD")
4410 (description "OpenMSX is a music set for OpenTTD which makes it possible
4411 to play OpenTTD without requiring the proprietary music from the original
4412 Transport Tycoon Deluxe.")
4413 (license license:gpl2)))
4414
4415 (define-public openttd
4416 (package
4417 (inherit openttd-engine)
4418 (name "openttd")
4419 (arguments
4420 `(#:configure-flags
4421 (let* ((out (assoc-ref %outputs "out")))
4422 (list (string-append "-DCMAKE_INSTALL_BINDIR=" out "/bin")))
4423 #:phases
4424 (modify-phases %standard-phases
4425 (add-before 'check 'install-data
4426 (lambda* (#:key inputs outputs #:allow-other-keys)
4427 (for-each
4428 (lambda (input)
4429 (copy-recursively (assoc-ref inputs input)
4430 (assoc-ref outputs "out")))
4431 (list "opengfx" "openmsx" "opensfx")))))))
4432 (inputs
4433 (modify-inputs (package-inputs openttd-engine)
4434 (prepend timidity++)))
4435 (native-inputs
4436 `(("opengfx" ,openttd-opengfx)
4437 ("openmsx" ,openttd-openmsx)
4438 ("opensfx" ,openttd-opensfx)
4439 ("gcc" ,gcc-9) ; for #include <charconv>
4440 ,@(package-native-inputs openttd-engine)))))
4441
4442 (define openrct2-title-sequences
4443 (package
4444 (name "openrct2-title-sequences")
4445 (version "0.1.2")
4446 (source
4447 (origin
4448 (method url-fetch)
4449 (uri (string-append "https://github.com/OpenRCT2/title-sequences/releases/download/v"
4450 version "/title-sequence-v" version ".zip"))
4451 (file-name (string-append name "-" version ".zip"))
4452 (sha256
4453 (base32
4454 "0qbyxrsw8hlgaq0r5d7lx7an3idy4qbfv7yiw9byhldk763n9cfw"))))
4455 (build-system trivial-build-system)
4456 (native-inputs
4457 `(("bash" ,bash)
4458 ("coreutils" ,coreutils)
4459 ("unzip" ,unzip)))
4460 (arguments
4461 `(#:modules ((guix build utils))
4462 #:builder
4463 (begin
4464 (use-modules (guix build utils))
4465 (let* ((out (assoc-ref %outputs "out"))
4466 (openrct2-title-sequences (string-append out
4467 "/share/openrct2/title-sequences"))
4468 (source (assoc-ref %build-inputs "source"))
4469 (unzip (search-input-file %build-inputs "/bin/unzip")))
4470 (copy-file source (string-append ,name "-" ,version ".zip"))
4471 (invoke unzip (string-append ,name "-" ,version ".zip"))
4472 (delete-file (string-append ,name "-" ,version ".zip"))
4473 (mkdir-p openrct2-title-sequences)
4474 (copy-recursively "."
4475 openrct2-title-sequences)
4476 #t))))
4477 (home-page "https://github.com/OpenRCT2/OpenRCT2")
4478 (synopsis "Title sequences for OpenRCT2")
4479 (description
4480 "openrct2-title-sequences is a set of title sequences for OpenRCT2.")
4481 (license license:gpl3+)))
4482
4483 (define openrct2-objects
4484 (package
4485 (name "openrct2-objects")
4486 (version "1.0.20")
4487 (source
4488 (origin
4489 (method url-fetch)
4490 (uri (string-append "https://github.com/OpenRCT2/objects/releases/download/v"
4491 version "/objects.zip"))
4492 (file-name (string-append name "-" version ".zip"))
4493 (sha256
4494 (base32 "1q7a38kcwrfijav6app1gf253yfv8b0rljbkah8040y6i7snw9mw"))))
4495 (build-system trivial-build-system)
4496 (native-inputs
4497 `(("bash" ,bash)
4498 ("coreutils" ,coreutils)
4499 ("unzip" ,unzip)))
4500 (arguments
4501 `(#:modules ((guix build utils))
4502 #:builder
4503 (begin
4504 (use-modules (guix build utils))
4505 (let* ((out (assoc-ref %outputs "out"))
4506 (openrct2-objects (string-append out
4507 "/share/openrct2/objects"))
4508 (source (assoc-ref %build-inputs "source"))
4509 (unzip (search-input-file %build-inputs "/bin/unzip")))
4510 (copy-file source (string-append ,name "-" ,version ".zip"))
4511 (invoke unzip (string-append ,name "-" ,version ".zip"))
4512 (delete-file (string-append ,name "-" ,version ".zip"))
4513 (mkdir-p openrct2-objects)
4514 (copy-recursively "."
4515 openrct2-objects)
4516 #t))))
4517 (home-page "https://github.com/OpenRCT2/OpenRCT2")
4518 (synopsis "Objects for OpenRCT2")
4519 (description
4520 "openrct2-objects is a set of objects for OpenRCT2.")
4521 (license license:gpl3+)))
4522
4523 (define-public openrct2
4524 (package
4525 (name "openrct2")
4526 (version "0.3.3")
4527 (source
4528 (origin
4529 (method git-fetch)
4530 (uri (git-reference
4531 (url "https://github.com/OpenRCT2/OpenRCT2")
4532 (commit (string-append "v" version))))
4533 (file-name (git-file-name name version))
4534 (sha256
4535 (base32 "01nanpbz5ycdhkyd46fjfvj18sw729l4vk7xg12600f9rjngjk76"))))
4536 (build-system cmake-build-system)
4537 (arguments
4538 `(#:configure-flags (list "-DDOWNLOAD_OBJECTS=OFF"
4539 "-DDOWNLOAD_TITLE_SEQUENCES=OFF")
4540 #:tests? #f ; tests require network access
4541 #:phases
4542 (modify-phases %standard-phases
4543 (add-after 'unpack 'fix-usr-share-paths&add-data
4544 (lambda* (#:key inputs outputs #:allow-other-keys)
4545 (let ((titles (assoc-ref inputs "openrct2-title-sequences"))
4546 (objects (assoc-ref inputs "openrct2-objects")))
4547 ;; Fix some references to /usr/share.
4548 (substitute* "src/openrct2/platform/Platform.Linux.cpp"
4549 (("/usr/share")
4550 (string-append (assoc-ref %outputs "out") "/share")))
4551 (copy-recursively
4552 (string-append titles "/share/openrct2/title-sequences")
4553 "data/title")
4554 (copy-recursively
4555 (string-append objects "/share/openrct2/objects")
4556 "data/object"))))
4557 (add-before 'configure 'get-rid-of-errors
4558 (lambda _
4559 ;; Don't treat warnings as errors.
4560 (substitute* "CMakeLists.txt"
4561 (("-Werror") ""))
4562 #t)))))
4563 (inputs `(("curl" ,curl)
4564 ("duktape" ,duktape)
4565 ("fontconfig" ,fontconfig)
4566 ("freetype" ,freetype)
4567 ("icu4c" ,icu4c)
4568 ("jansson" ,jansson)
4569 ("json-modern-cxx" ,json-modern-cxx)
4570 ("libpng" ,libpng)
4571 ("libzip" ,libzip)
4572 ("mesa" ,mesa)
4573 ("openrct2-objects" ,openrct2-objects)
4574 ("openrct2-title-sequences" ,openrct2-title-sequences)
4575 ("openssl" ,openssl)
4576 ("sdl2" ,sdl2)
4577 ("speexdsp" ,speexdsp)
4578 ("zlib" ,zlib)))
4579 (native-inputs
4580 (list pkg-config))
4581 (home-page "https://github.com/OpenRCT2/OpenRCT2")
4582 (synopsis "Free software re-implementation of RollerCoaster Tycoon 2")
4583 (description "OpenRCT2 is a free software re-implementation of
4584 RollerCoaster Tycoon 2 (RCT2). The gameplay revolves around building and
4585 maintaining an amusement park containing attractions, shops and facilities.
4586
4587 Note that this package does @emph{not} provide the game assets (sounds,
4588 images, etc.)")
4589 ;; See <https://github.com/OpenRCT2/OpenRCT2/wiki/Required-RCT2-files>
4590 ;; regarding assets.
4591 (license license:gpl3+)))
4592
4593 (define-public pinball
4594 (package
4595 (name "pinball")
4596 (version "0.3.20201218")
4597 (source
4598 (origin (method git-fetch)
4599 (uri (git-reference
4600 (url "https://github.com/adoptware/pinball")
4601 (commit version)))
4602 (file-name (git-file-name name version))
4603 (sha256
4604 (base32
4605 "056jk98v6zlkrj9vjm06p0pmpnav1x658n6qw10v5klg5gr6ldf7"))
4606 (patches (search-patches "pinball-system-ltdl.patch"))))
4607 (build-system gnu-build-system)
4608 (native-inputs
4609 (list autoconf automake pkg-config libtool))
4610 (inputs
4611 (list glu
4612 libltdl
4613 mesa
4614 sdl
4615 sdl-image
4616 sdl-mixer))
4617 (arguments
4618 '(#:configure-flags
4619 ;; Configure tries to use pkg-config, but falls short, so:
4620 (list (string-append "CPPFLAGS=-I"
4621 (assoc-ref %build-inputs "sdl-image")
4622 "/include/SDL -I"
4623 (assoc-ref %build-inputs "sdl-mixer")
4624 "/include/SDL"))
4625 #:phases
4626 (modify-phases %standard-phases
4627 (replace 'bootstrap
4628 ;; The `bootstrap` script tries to call a script with
4629 ;; `/usr/bin/make` in the shebang, but ultimately does the same as
4630 ;; autoreconf would do, so just use that.
4631 (lambda _
4632 (symlink "README.md" "README")
4633 (display (which "autoreconf")) (newline)
4634 (invoke "autoreconf" "-vif"))))))
4635 (home-page "http://pinball.sourceforge.net")
4636 (synopsis "Pinball simulator")
4637 (description "The Emilia Pinball Project is a pinball simulator. There
4638 are only two levels to play with, but they are very addictive.")
4639 (license license:gpl2)))
4640
4641 (define-public pioneers
4642 (package
4643 (name "pioneers")
4644 (version "15.6")
4645 (source (origin
4646 (method url-fetch)
4647 (uri (string-append "https://downloads.sourceforge.net/pio/"
4648 "pioneers-" version ".tar.gz"))
4649 (sha256
4650 (base32
4651 "07b3xdd81n8ybsb4fzc5lx0813y9crzp1hj69khncf4faj48sdcs"))))
4652 (build-system gnu-build-system)
4653 (arguments
4654 `(#:phases
4655 (modify-phases %standard-phases
4656 ;; Fixes https://issues.guix.gnu.org/47131.
4657 (add-after 'unpack 'patch-beep-path
4658 (lambda* (#:key inputs #:allow-other-keys)
4659 (substitute* "client/gtk/audio.c"
4660 (("\"beep\"")
4661 (string-append "\"" (assoc-ref inputs "beep") "/bin/beep\"")))
4662 #t)))))
4663 (inputs (list avahi beep gtk+ librsvg))
4664 (native-inputs (list intltool itstool libxml2 pkg-config))
4665 (synopsis "Board game inspired by The Settlers of Catan")
4666 (description "Pioneers is an emulation of the board game The Settlers of
4667 Catan. It can be played on a local network, on the internet, and with AI
4668 players.")
4669 (home-page "http://pio.sourceforge.net/")
4670 (license license:gpl2+)))
4671
4672 (define-public einstein
4673 (package
4674 (name "einstein")
4675 (version "2.0")
4676 (source (origin
4677 (method url-fetch)
4678 (uri (string-append "mirror://debian/pool/main/e/"
4679 "einstein/einstein_2.0.dfsg.2.orig.tar.gz"))
4680 (sha256
4681 (base32
4682 "1hxrlv6n8py48j487i6wbb4n4vd55w0na69r7ccmmr9vmrsw5mlk"))
4683 (patches (search-patches "einstein-build.patch"))))
4684 (build-system gnu-build-system)
4685 (inputs
4686 `(("freetype" ,freetype)
4687 ("sdl" ,(sdl-union (list sdl sdl-mixer sdl-ttf)))
4688 ("zlib" ,zlib)))
4689 (native-inputs
4690 (list font-dejavu))
4691 (arguments
4692 `(#:tests? #f ; no check target
4693 #:phases
4694 (modify-phases %standard-phases
4695 (replace 'configure
4696 (lambda* (#:key outputs inputs #:allow-other-keys)
4697 (let ((out (assoc-ref outputs "out"))
4698 (dejavu (search-input-file
4699 inputs "/share/fonts/truetype/DejaVuSans.ttf")))
4700 (substitute* "Makefile"
4701 (("PREFIX=/usr/local") (string-append "PREFIX=" out)))
4702 ;; The patch above registers a free font for use by the binary,
4703 ;; but the font is copied during the compile phase into a
4704 ;; resources file, so we need to make the ttf file available.
4705 (symlink dejavu "res/DejaVuSans.ttf")
4706 #t))))))
4707 (synopsis "Logic puzzle game")
4708 (description "The goal of this logic game is to open all cards in a 6x6
4709 grid, using a number of hints as to their relative position. The game idea
4710 is attributed to Albert Einstein.")
4711 ;; The original home page has disappeared.
4712 (home-page (string-append "http://web.archive.org/web/20120521062745/"
4713 "http://games.flowix.com/en/index.html"))
4714 ;; License according to
4715 ;; http://web.archive.org/web/20150222180355/http://www.babichev.info/en/projects/index.html
4716 ;; The source code is a DFSG-sanitized tarball and does not contain any
4717 ;; license information.
4718 (license license:gpl3+)))
4719
4720 (define-public powwow
4721 (package
4722 (name "powwow")
4723 (version "1.2.23")
4724 (source (origin
4725 (method url-fetch)
4726 (uri (string-append
4727 "https://www.hoopajoo.net/static/projects/powwow-"
4728 version ".tar.gz"))
4729 (sha256
4730 (base32
4731 "1wkl6j91pp40aps2hhnsv0bndgq49smfffws4hqcn7847bpnwwm6"))))
4732 (inputs
4733 (list ncurses))
4734 (build-system gnu-build-system)
4735 (home-page "https://www.hoopajoo.net/projects/powwow.html")
4736 (synopsis "MUD and telnet client")
4737 (description
4738 "POWWOW is a client software which can be used for telnet as well as for
4739 @dfn{Multi-User Dungeon} (MUD). Additionally it can serve as a nice client for
4740 the chat server psyced with the specific config located at
4741 http://lavachat.symlynx.com/unix/")
4742 (license license:gpl2+)))
4743
4744 (define-public red-eclipse
4745 (let ((release "2.0.0")
4746 (revision 0))
4747 (package
4748 (name "red-eclipse")
4749 (version (if (zero? revision)
4750 release
4751 (string-append release "-"
4752 (number->string revision))))
4753 (source
4754 (origin
4755 (method git-fetch)
4756 (uri (git-reference
4757 (url "https://github.com/redeclipse/base")
4758 (commit (string-append "v" release))
4759 (recursive? #t))) ; for game data
4760 (file-name (git-file-name name version))
4761 (sha256
4762 (base32 "0sz0mqhwx8r9n4mk3qrxw420nlsm3y0n48gd0lazgd64lfqjh3ab"))
4763 (modules '((guix build utils)))
4764 (snippet
4765 ;; Remove proprietary libraries and other pre-compiled binaries.
4766 '(begin
4767 (delete-file-recursively "bin")
4768 #t))))
4769 (build-system gnu-build-system)
4770 (arguments
4771 `(#:tests? #f ; no check target
4772 #:make-flags (list "CC=gcc" "-Csrc"
4773 (string-append "INSTDIR="
4774 (assoc-ref %outputs "out") "/bin")
4775 (string-append "prefix="
4776 (assoc-ref %outputs "out")))
4777 #:phases
4778 (modify-phases %standard-phases
4779 (add-after 'unpack 'add-store-data-package-path-as-default
4780 (lambda* (#:key outputs #:allow-other-keys)
4781 (substitute* "src/engine/server.cpp"
4782 (("data = \"data\"")
4783 (string-append "data = \""
4784 (assoc-ref outputs "out")
4785 "/share/redeclipse/data\"")))
4786 #t))
4787 (delete 'configure) ; no configure script
4788 (add-after 'set-paths 'set-sdl-paths
4789 (lambda* (#:key inputs #:allow-other-keys)
4790 (setenv "CPATH"
4791 (string-append
4792 (search-input-directory inputs "/include/SDL2")
4793 ":" (or (getenv "CPATH") "")))))
4794 (add-after 'install 'copy-data
4795 (lambda* (#:key outputs #:allow-other-keys)
4796 (let ((out (assoc-ref outputs "out")))
4797 (copy-recursively "config"
4798 (string-append out "/config"))
4799 (copy-file "doc/examples/servinit.cfg"
4800 (string-append out "/config/servinit.cfg"))
4801 (copy-recursively "data"
4802 (string-append out "/share/redeclipse/data"))
4803 (mkdir-p (string-append out "/lib/redeclipse"))
4804 (symlink (string-append out "/share/redeclipse/data")
4805 (string-append out "/lib/redeclipse/data")))
4806 #t))
4807 (add-after 'copy-data 'wrap-program
4808 (lambda* (#:key inputs outputs #:allow-other-keys)
4809 (let* ((out (assoc-ref outputs "out"))
4810 (bin (string-append out "/bin")))
4811 (with-directory-excursion bin
4812 (rename-file "redeclipse_linux"
4813 ".redeclipse_linux-real")
4814 (rename-file "redeclipse_server_linux"
4815 ".redeclipse_server_linux-real")
4816 (call-with-output-file "redeclipse_linux"
4817 (lambda (port)
4818 (format port "#!~a/bin/sh
4819 # Run the thing from its home, otherwise it just bails out.
4820 cd \"~a\"
4821 exec -a \"$0\" ~a/.redeclipse_linux-real~%"
4822 (assoc-ref inputs "bash") ;implicit input
4823 (string-append out)
4824 (string-append bin))))
4825 (call-with-output-file "redeclipse_server_linux"
4826 (lambda (port)
4827 (format port "#!~a/bin/sh
4828 # Run the thing from its home, otherwise it just bails out.
4829 cd \"~a\"
4830 exec -a \"$0\" ~a/.redeclipse_server_linux-real~%"
4831 (assoc-ref inputs "bash") ;implicit input
4832 (string-append out)
4833 (string-append bin))))
4834 (chmod "redeclipse_linux" #o555)
4835 (chmod "redeclipse_server_linux" #o555)))
4836 #t)))))
4837 (native-inputs
4838 (list pkg-config))
4839 (inputs
4840 (list curl freetype glu
4841 (sdl-union (list sdl2 sdl2-image sdl2-mixer))))
4842 (home-page "https://redeclipse.net/")
4843 (synopsis "Arena shooter derived from the Cube 2 engine")
4844 (description
4845 "Red Eclipse is an arena shooter, created from the Cube2 engine.
4846 Offering an innovative parkour system and distinct but all potent weapons,
4847 Red Eclipse provides fast paced and accessible gameplay.")
4848 ;; The engine is under Zlib; data files are covered by the other
4849 ;; licenses. More details at file:///doc/all-licenses.txt.
4850 (license (list license:expat
4851 license:zlib
4852 license:cc-by-sa4.0
4853 license:cc-by-sa3.0
4854 license:cc-by3.0
4855 license:cc0
4856 license:public-domain
4857 license:silofl1.1)))))
4858
4859 (define-public grue-hunter
4860 (package
4861 (name "grue-hunter")
4862 (version "1.0")
4863 (source (origin
4864 (method url-fetch)
4865 (uri (string-append "https://jxself.org/grue-hunter.tar.gz"))
4866 (sha256
4867 (base32
4868 "1hjcpy5439qs3v2zykis7hsi0i17zjs62gks3zd8mnfw9ni4i2h3"))))
4869 (build-system trivial-build-system) ; no Makefile.PL
4870 (arguments `(#:modules ((guix build utils))
4871 #:builder
4872 (begin
4873 (use-modules (guix build utils))
4874 (use-modules (srfi srfi-1))
4875
4876 (let* ((tarball (assoc-ref %build-inputs "tarball"))
4877 (perl (string-append (assoc-ref %build-inputs
4878 "perl")
4879 "/bin"))
4880 (gzip (string-append (assoc-ref %build-inputs
4881 "gzip")
4882 "/bin/gzip"))
4883 (tar (string-append (assoc-ref %build-inputs
4884 "tar")
4885 "/bin/tar"))
4886 (out (assoc-ref %outputs "out"))
4887 (bin (string-append out "/bin"))
4888 (doc (string-append out
4889 "/share/doc/grue-hunter")))
4890 (copy-file tarball "grue-hunter.tar.gz")
4891 (invoke gzip "-d" "grue-hunter.tar.gz")
4892 (invoke tar "xvf" "grue-hunter.tar")
4893
4894 (mkdir-p bin)
4895 (copy-file "grue-hunter/gh.pl"
4896 (string-append bin "/grue-hunter"))
4897 (patch-shebang (string-append bin "/grue-hunter")
4898 (list perl))
4899
4900 (install-file "grue-hunter/AGPLv3.txt" doc)
4901
4902 #t))))
4903 (inputs `(("perl" ,perl)
4904 ("tar" ,tar)
4905 ("gzip" ,gzip)
4906 ("tarball" ,source)))
4907 (home-page "https://jxself.org/grue-hunter.shtml")
4908 (synopsis "Text adventure game")
4909 (description
4910 "Grue Hunter is a text adventure game written in Perl. You must make
4911 your way through an underground cave system in search of the Grue. Can you
4912 capture it and get out alive?")
4913 (license license:agpl3+)))
4914
4915 (define-public lierolibre
4916 (package
4917 (name "lierolibre")
4918 (version "0.5")
4919 (source (origin
4920 (method url-fetch)
4921 (uri (string-append "https://launchpad.net/lierolibre/trunk/"
4922 version "/+download/lierolibre-"
4923 version ".tar.xz"))
4924 (sha256
4925 (base32
4926 "1cf1gvsn4qq190lrf9k5bpjnqwlcfw7pajvdnh7z5r4jqw0rsbl9"))
4927 (patches
4928 (search-patches "lierolibre-check-unaligned-access.patch"
4929 "lierolibre-try-building-other-arch.patch"
4930 "lierolibre-remove-arch-warning.patch"
4931 "lierolibre-newer-libconfig.patch"
4932 "lierolibre-is-free-software.patch"))
4933 (modules '((guix build utils)))
4934 (snippet
4935 '(begin
4936 ;; Delete pre-compiled files.
4937 (delete-file "data/LIERO.CHR")
4938 (delete-file "data/LIERO.SND")
4939 #t))))
4940 (build-system gnu-build-system)
4941 (native-inputs
4942 (list imagemagick pkg-config util-linux sox))
4943 (inputs
4944 (list boost libconfig
4945 (sdl-union (list sdl sdl-image sdl-mixer)) zlib))
4946 (home-page "https://gitlab.com/lierolibre/lierolibre")
4947 (synopsis "Old-school earthworm action game")
4948 (description
4949 "lierolibre is an earthworm action game where you fight another player
4950 (or the computer) underground using a wide array of weapons.
4951
4952 Features:
4953 @itemize
4954 @item 2 worms, 40 weapons, great playability, two game modes: Kill'em All
4955 and Game of Tag, plus AI-players without true intelligence!
4956 @item Dat nostalgia.
4957 @item Extensions via a hidden F1 menu:
4958 @itemize
4959 @item Replays
4960 @item Game controller support
4961 @item Powerlevel palettes
4962 @end itemize
4963 @item Ability to write game variables to plain text files.
4964 @item Ability to load game variables from both EXE and plain text files.
4965 @item Scripts to extract and repack graphics, sounds and levels.
4966 @end itemize
4967
4968 To switch between different window sizes, use F6, F7 and F8, to switch to
4969 fullscreen, use F5 or Alt+Enter.")
4970 ;; Code mainly BSD-2, some parts under Boost 1.0. All assets are WTFPL2.
4971 (license (list license:bsd-2 license:boost1.0 license:wtfpl2))))
4972
4973 (define-public tennix
4974 (package
4975 (name "tennix")
4976 (version "1.3.1")
4977 (source
4978 (origin
4979 (method git-fetch)
4980 (uri (git-reference
4981 (url "https://repo.or.cz/tennix.git")
4982 (commit (string-append "tennix-" version))))
4983 (file-name (git-file-name name version))
4984 (sha256
4985 (base32 "02cj4lrdrisal5s9pnbf2smx7qz9czczjzndfkhfx0qy67b957sk"))
4986 ;; Remove non-free images.
4987 (modules '((guix build utils)))
4988 (snippet
4989 '(begin
4990 (for-each delete-file
4991 '("data/loc_training_camp.png"
4992 "data/loc_austrian_open.png"
4993 "data/loc_olympic_green_tennis.png"))
4994 #t))))
4995 (build-system gnu-build-system)
4996 (arguments
4997 `(#:tests? #f ;no test
4998 #:phases
4999 (modify-phases %standard-phases
5000 (add-after 'unpack 'fix-include
5001 (lambda _
5002 (substitute* '("src/graphics.h" "src/sound.h")
5003 (("#include \"(SDL_(image|ttf|mixer)\\.h)\"" _ header)
5004 (string-append "#include \"SDL/" header "\"")))
5005 (substitute* '("src/tennix.h" "src/network.h" "src/SDL_rotozoom.h")
5006 (("#include <SDL.h>") "#include <SDL/SDL.h>")
5007 (("#include <SDL_net.h>") "#include <SDL/SDL_net.h>"))
5008 #t))
5009 (add-after 'unpack 'locate-install
5010 ;; Build process cannot expand "$(INSTALL)" in Makefile.
5011 (lambda _
5012 (substitute* "makefile"
5013 (("^CONFIGURE_OUTPUT :=.*" all)
5014 (string-append "INSTALL := install -c\n" all)))
5015 #t))
5016 (replace 'configure
5017 ;; The "configure" script is picky about the arguments it
5018 ;; gets. Call it ourselves.
5019 (lambda _
5020 (invoke "./configure" "--prefix" (assoc-ref %outputs "out")))))))
5021 (native-inputs
5022 (list which))
5023 (inputs
5024 `(("python" ,python-wrapper)
5025 ("sdl" ,(sdl-union (list sdl sdl-image sdl-mixer sdl-ttf sdl-net)))))
5026 (home-page "http://icculus.org/tennix/")
5027 (synopsis "Play tennis against the computer or a friend")
5028 (description "Tennix is a 2D tennis game. You can play against the
5029 computer or against another player using the keyboard. The game runs
5030 in-window at 640x480 resolution or fullscreen.")
5031 ;; Project is licensed under GPL2+ terms. It includes images
5032 ;; released under Public Domain terms, and SDL_rotozoom, released
5033 ;; under LGPL2.1 terms.
5034 (license (list license:gpl2+ license:public-domain license:lgpl2.1))))
5035
5036 (define-public warzone2100
5037 (package
5038 (name "warzone2100")
5039 (version "4.0.1")
5040 (source
5041 (origin
5042 (method url-fetch)
5043 (uri (string-append "mirror://sourceforge/warzone2100/releases/"
5044 version
5045 "/warzone2100_src.tar.xz"))
5046 (sha256
5047 (base32 "1f8a4kflslsjl8jrryhwg034h1yc9y3y1zmllgww3fqkz3aj4xik"))
5048 (modules '((guix build utils)))
5049 (snippet
5050 '(begin
5051 (with-directory-excursion "3rdparty"
5052 (for-each
5053 delete-file-recursively
5054 '("discord-rpc"
5055 "miniupnp"
5056 "utfcpp")))
5057 #t))))
5058 (build-system cmake-build-system)
5059 (arguments
5060 `(#:configure-flags '("-DWZ_DISTRIBUTOR=Guix"
5061 "-DWZ_ENABLE_BACKEND_VULKAN=off"
5062 "-DENABLE_DISCORD=off")
5063 #:tests? #f ; TODO: Tests seem to be broken, configure.ac is missing.
5064 #:phases
5065 (modify-phases %standard-phases
5066 (add-after 'unpack 'fix-utfcpp-include
5067 (lambda _
5068 (substitute* "lib/framework/wzstring.cpp"
5069 (("<utfcpp/source/utf8.h>") "<utf8.h>"))
5070 #t))
5071 (add-after 'unpack 'link-tests-with-qt
5072 (lambda _
5073 (substitute* "tests/Makefile.am"
5074 (("(framework_linktest_LDADD|maptest_LDADD) = " prefix)
5075 (string-append prefix "$(QT5_LIBS) ")))
5076 #t))
5077 (add-after 'unpack 'fix-ivis-linktest
5078 (lambda _
5079 (substitute* "tests/ivis_linktest.cpp"
5080 (("iV_DrawTextRotated.*;")
5081 (string-append "iV_DrawTextRotated(\"Press ESC to exit.\", "
5082 "100, 100, 0.0f, font_regular);")))
5083 #t)))))
5084 (native-inputs `(("asciidoc" ,asciidoc)
5085 ("asciidoctor" ,ruby-asciidoctor)
5086 ("gettext" ,gettext-minimal)
5087 ("pkg-config" ,pkg-config)
5088 ("unzip" ,unzip)
5089 ;; 7z is used to create .zip archive, not `zip' as in version 3.2.*.
5090 ("p7zip" ,p7zip)))
5091 (inputs `(("curl" ,curl)
5092 ("fontconfig" ,fontconfig)
5093 ("freetype" ,freetype)
5094 ("glew" ,glew)
5095 ("harfbuzz" ,harfbuzz)
5096 ("libtheora" ,libtheora)
5097 ("libvorbis" ,libvorbis)
5098 ("libxrandr" ,libxrandr)
5099 ("libsodium" ,libsodium)
5100 ("miniupnpc" ,miniupnpc)
5101 ("openal" ,openal)
5102 ("physfs" ,physfs)
5103 ("qtbase" ,qtbase-5)
5104 ("qtscript" ,qtscript)
5105 ("openssl" ,openssl)
5106 ("sdl2" ,sdl2)
5107 ("sqlite" ,sqlite)
5108 ("utfcpp" ,utfcpp)))
5109 (home-page "https://wz2100.net")
5110 (synopsis "3D Real-time strategy and real-time tactics game")
5111 (description
5112 "Warzone 2100 offers campaign, multi-player, and single-player skirmish
5113 modes. An extensive tech tree with over 400 different technologies, combined
5114 with the unit design system, allows for a wide variety of possible units and
5115 tactics.")
5116 ;; Everything is GPLv2+ unless otherwise specified in COPYING.NONGPL
5117 (license (list license:bsd-3
5118 license:cc0
5119 license:cc-by-sa3.0
5120 license:expat
5121 license:gpl2+
5122 license:lgpl2.1+))))
5123
5124 (define-public widelands
5125 (package
5126 (name "widelands")
5127 (version "1.0")
5128 (source
5129 (origin
5130 (method git-fetch)
5131 (uri (git-reference
5132 (url "https://github.com/widelands/widelands")
5133 (commit (string-append "v" version))))
5134 (file-name (git-file-name name version))
5135 (sha256
5136 (base32 "1hw51binnbia15mj1gzx1cbk3cw9r91sisqci2qzcy4ahxiadnw0"))
5137 (modules '((guix build utils)))
5138 (snippet
5139 '(begin
5140 (delete-file-recursively "src/third_party/minizip")
5141 #t))
5142 (patches
5143 ;; Use system Minizip. Patch is provided by Debian, and discussed
5144 ;; upstream at <https://github.com/widelands/widelands/issues/399>.
5145 (search-patches "widelands-system-wide_minizip.patch"))))
5146 (build-system cmake-build-system)
5147 (arguments
5148 `(#:configure-flags
5149 (let* ((out (assoc-ref %outputs "out"))
5150 (share (string-append out "/share")))
5151 (list (string-append "-DCMAKE_INSTALL_PREFIX=" out "/bin")
5152 (string-append "-DWL_INSTALL_BASEDIR=" share "/widelands")
5153 (string-append "-DWL_INSTALL_DATADIR=" share "/widelands")
5154 "-DOPTION_BUILD_WEBSITE_TOOLS=OFF"
5155 ;; CMakeLists.txt does not handle properly RelWithDebInfo build
5156 ;; type. When used, no game data is installed!
5157 "-DCMAKE_BUILD_TYPE=Release"))
5158 #:phases
5159 (modify-phases %standard-phases
5160 (add-after 'unpack 'unbundle-fonts
5161 ;; Unbundle fonts already packaged in Guix. XXX: missing fonts are
5162 ;; amiri, Culmus, mmrCensus, Nakula, and Sinhala.
5163 (lambda* (#:key inputs #:allow-other-keys)
5164 (with-directory-excursion "data/i18n/fonts"
5165 (for-each (lambda (font)
5166 (delete-file-recursively font)
5167 (symlink (string-append (assoc-ref inputs font)
5168 "/share/fonts/truetype")
5169 font))
5170 '("DejaVu" "MicroHei")))
5171 #t)))))
5172 (native-inputs
5173 `(("gettext" ,gettext-minimal)
5174 ("python" ,python-wrapper)))
5175 (inputs
5176 `(("curl" ,curl)
5177 ("boost" ,boost)
5178 ("glew" ,glew)
5179 ("icu4c" ,icu4c)
5180 ("libpng" ,libpng)
5181 ("minizip" ,minizip)
5182 ("sdl" ,(sdl-union (list sdl2 sdl2-image sdl2-mixer sdl2-ttf)))
5183 ("zlib" ,zlib)
5184 ;; Fonts for the ‘unbundle-fonts’ phase. Case matters in name!
5185 ("DejaVu" ,font-dejavu)
5186 ("MicroHei" ,font-wqy-microhei)))
5187 (home-page "https://www.widelands.org/")
5188 (synopsis "Fantasy real-time strategy game")
5189 (description
5190 "In Widelands, you are the regent of a small clan. You start out with
5191 nothing but your headquarters, where all your resources are stored.
5192
5193 In the course of the game, you will build an ever growing settlement. Every
5194 member of your clan will do his or her part to produce more resources---wood,
5195 food, iron, gold and more---to further this growth. The economic network is
5196 complex and different in the five tribes (Barbarians, Empire, Atlanteans,
5197 Frisians and Amazons).
5198
5199 As you are not alone in the world, you will meet other clans sooner or later.
5200 Some of them may be friendly and you may eventually trade with them. However,
5201 if you want to rule the world, you will have to train soldiers and fight.
5202
5203 Widelands offers single-player mode with different campaigns; the campaigns
5204 all tell stories of tribes and their struggle in the Widelands universe!
5205 However, settling really starts when you unite with friends over the Internet
5206 or LAN to build up new empires together---or to crush each other in the dusts
5207 of war. Widelands also offers an Artificial Intelligence to challenge you.")
5208 ;; Game is released as GPL2+. Some parts, e.g., art, are released under
5209 ;; different licenses.
5210 (license (list license:gpl2+
5211 license:expat ;src/third_party/eris
5212 license:silofl1.1 ;Widelands.ttf
5213 license:cc-by-sa3.0)))) ;some music files
5214
5215 (define-public widelands-21
5216 (package
5217 (inherit widelands)
5218 (version "21")
5219 (properties `((superseded . ,widelands)))))
5220
5221 (define-public starfighter
5222 (package
5223 (name "starfighter")
5224 (version "2.4")
5225 (source (origin
5226 (method url-fetch)
5227 (uri (string-append
5228 "https://github.com/pr-starfighter/starfighter/releases"
5229 "/download/v" version "/starfighter-"
5230 version "-src.tar.gz"))
5231 (sha256
5232 (base32
5233 "0ips79j3sdy8wa64jqka0skbbqkzqiln9bbiiilh4z717q7vz9r5"))))
5234 (build-system gnu-build-system)
5235 (native-inputs
5236 (list pkg-config))
5237 (inputs
5238 (list pango sdl2 sdl2-image sdl2-mixer sdl2-ttf))
5239 (home-page "https://pr-starfighter.github.io/")
5240 (synopsis "2D scrolling shooter game")
5241 (description
5242 "In the year 2579, the intergalactic weapons corporation, WEAPCO, has
5243 dominated the galaxy. Guide Chris Bainfield and his friend Sid Wilson on
5244 their quest to liberate the galaxy from the clutches of WEAPCO. Along the
5245 way, you will encounter new foes, make new allies, and assist local rebels
5246 in strikes against the evil corporation.")
5247 ;; gfx and music are under CC-BY 3.0, CC-BY-SA 3.0, CC0 or Public Domain.
5248 (license (list license:gpl3+
5249 license:cc-by3.0
5250 license:cc-by-sa3.0
5251 license:cc0
5252 license:public-domain))))
5253
5254 (define-public chromium-bsu
5255 (package
5256 (name "chromium-bsu")
5257 (version "0.9.16.1")
5258 (source (origin
5259 (method url-fetch)
5260 (uri (string-append "mirror://sourceforge/chromium-bsu"
5261 "/Chromium B.S.U. source code/"
5262 "chromium-bsu-" version ".tar.gz"))
5263 (sha256
5264 (base32
5265 "0jk2w5b6s6nkzri585bbz16cif2fhqcnl5l1mq3rd98r9nil3hd1"))))
5266 (build-system gnu-build-system)
5267 (native-inputs (list pkg-config))
5268 (inputs (list gettext-minimal glu quesoglc
5269 (sdl-union (list sdl sdl-image sdl-mixer))))
5270 (home-page "http://chromium-bsu.sourceforge.net/")
5271 (synopsis "Fast-paced, arcade-style, top-scrolling space shooter")
5272 (description
5273 "In this game you are the captain of the cargo ship Chromium B.S.U. and
5274 are responsible for delivering supplies to the troops on the front line. Your
5275 ship has a small fleet of robotic fighters which you control from the relative
5276 safety of the Chromium vessel.")
5277 ;; Clarified Artistic License for everything but sound, which is covered
5278 ;; by the Expat License.
5279 (license (list license:clarified-artistic license:expat))))
5280
5281 (define-public tuxpaint
5282 (package
5283 (name "tuxpaint")
5284 (version "0.9.23") ;keep VER_DATE below in sync
5285 (source
5286 (origin
5287 (method url-fetch)
5288 (uri (string-append "mirror://sourceforge/tuxpaint/tuxpaint/"
5289 version "/tuxpaint-" version ".tar.gz"))
5290 (sha256
5291 (base32
5292 "09k9pxi88r3dx6dyjwf9h85d4qpva4i29qz63dc558hg9v21k69l"))
5293 (modules '((guix build utils)))
5294 (snippet
5295 '(begin
5296 ;; Remove win32 directory which contains binary dll's and the
5297 ;; deprecated visualc directory.
5298 (for-each delete-file-recursively '("win32" "visualc"))
5299 (substitute* "Makefile"
5300 ;; Do not rely on $(GPERF) being an absolute file name
5301 (("\\[ -x \\$\\(GPERF\\) \\]")
5302 "$(GPERF) --version >/dev/null 2>&1"))
5303 #t))
5304 (patches (search-patches "tuxpaint-stamps-path.patch"))))
5305 (build-system gnu-build-system)
5306 (native-inputs
5307 (list gperf pkg-config))
5308 (inputs
5309 `(("cairo" ,cairo)
5310 ("fribidi" ,fribidi)
5311 ("gettext" ,gettext-minimal)
5312 ("libpng" ,libpng)
5313 ("librsvg" ,librsvg)
5314 ("libpaper" ,libpaper)
5315 ("netpbm" ,netpbm)
5316 ("sdl" ,(sdl-union (list sdl sdl-mixer sdl-ttf sdl-image)))))
5317 ;; TODO: Use system fonts rather than those in data/fonts
5318 (arguments
5319 `(#:make-flags `("VER_DATE=2018-09-02"
5320 "GPERF=gperf" "CC=gcc"
5321 "SDL_PCNAME=sdl SDL_image SDL_mixer SDL_ttf"
5322 ,(string-append "PREFIX=" %output)
5323 "KDE_PREFIX=$(PREFIX)/share/applications"
5324 "KDE_ICON_PREFIX=$(PREFIX)/share/icons/"
5325 "COMPLETIONDIR=$(PREFIX)/etc/bash_completion.d")
5326 #:parallel-build? #f ;fails on some systems
5327 #:tests? #f ;No tests
5328 #:phases (modify-phases %standard-phases
5329 (delete 'configure) ;no configure phase
5330 (add-before 'install 'no-sys-cache
5331 (lambda _ ;do not rebuild system conf cache
5332 (substitute* "Makefile"
5333 (("kbuildsycoca4") ""))
5334 #t))
5335 (add-after 'install 'fix-import
5336 (lambda* (#:key inputs outputs #:allow-other-keys)
5337 (let* ((out (assoc-ref outputs "out"))
5338 (net (assoc-ref inputs "netpbm"))
5339 (tpi (string-append out "/bin/tuxpaint-import")))
5340 (substitute* tpi
5341 ;; Point to installation prefix so that the default
5342 ;; configure file is found.
5343 (("/usr/local") out))
5344 ;; tuxpaint-import uses a bunch of programs from
5345 ;; netpbm, so make sure it knows where those are
5346 (wrap-program tpi
5347 `("PATH" ":" prefix
5348 (,(string-append net "/bin"))))))))))
5349 (native-search-paths
5350 (list (search-path-specification
5351 (variable "TUXPAINT_STAMPS_PATH")
5352 (files '("share/tuxpaint/stamps")))))
5353 (home-page "http://www.tuxpaint.org")
5354 (synopsis "Drawing software for children")
5355 (description
5356 "Tux Paint is a free drawing program designed for young children (kids
5357 ages 3 and up). It has a simple, easy-to-use interface; fun sound effects;
5358 and an encouraging cartoon mascot who helps guide children as they use the
5359 program. It provides a blank canvas and a variety of drawing tools to help
5360 your child be creative.")
5361 (license license:gpl2+)))
5362
5363 (define-public tuxpaint-stamps
5364 (package
5365 (name "tuxpaint-stamps")
5366 (version "2018.09.01")
5367 (source
5368 (origin
5369 (method url-fetch)
5370 (uri (string-append "mirror://sourceforge/tuxpaint/tuxpaint-stamps/"
5371 (string-map (λ (x) (if (eq? x #\.) #\- x)) version)
5372 "/tuxpaint-stamps-" version ".tar.gz"))
5373 (sha256
5374 (base32
5375 "1skr23k27yj3vgwfazpzxp90lb2a278gxrkr3bxw7az6zpkmb3yp"))))
5376 (build-system trivial-build-system)
5377 (native-inputs
5378 (list tar gzip))
5379 (arguments
5380 `(#:modules ((guix build utils))
5381 #:builder (begin
5382 (use-modules (guix build utils))
5383 (setenv "PATH"
5384 (string-append
5385 (assoc-ref %build-inputs "tar") "/bin" ":"
5386 (assoc-ref %build-inputs "gzip") "/bin"))
5387 (invoke "tar" "xvf" (assoc-ref %build-inputs "source"))
5388 (chdir (string-append ,name "-" ,version))
5389 (let ((dir (string-append %output "/share/tuxpaint/stamps")))
5390 (mkdir-p dir)
5391 (copy-recursively "stamps" dir))
5392 #t)))
5393 (home-page (package-home-page tuxpaint))
5394 (synopsis "Stamp images for Tux Paint")
5395 (description
5396 "This package contains a set of \"Rubber Stamp\" images which can be used
5397 with the \"Stamp\" tool within Tux Paint.")
5398 (license license:gpl2+)))
5399
5400 (define-public tuxpaint-config
5401 (package
5402 (name "tuxpaint-config")
5403 (version "0.0.14") ;keep VER_DATE below in sync
5404 (source
5405 (origin
5406 (method url-fetch)
5407 (uri (string-append "mirror://sourceforge/tuxpaint/tuxpaint-config/"
5408 version "/tuxpaint-config-" version ".tar.gz"))
5409 (sha256
5410 (base32
5411 "0zkgxk436nqcp43zghkfmh397c7dvh5bwn2as7gwvv208bzyij6g"))))
5412 (build-system gnu-build-system)
5413 (native-inputs
5414 `(("gettext" ,gettext-minimal)))
5415 (inputs
5416 (list fltk
5417 libpaper
5418 ;; TODO: Should the following be propagated by fltk?
5419 libx11
5420 libxft
5421 mesa))
5422 (arguments
5423 `(#:make-flags `("VER_DATE=2018-09-01"
5424 "CONFDIR=/etc/tuxpaint" ;don't write to store
5425 ,(string-append "PREFIX=" %output)
5426 "GNOME_PREFIX=$(PREFIX)")
5427 #:parallel-build? #f ;race conditions
5428 #:tests? #f ;no tests
5429 #:phases (modify-phases %standard-phases
5430 (delete 'configure) ;no configure phase
5431 (add-before 'install 'gzip-no-name
5432 (lambda* _
5433 (substitute* "Makefile"
5434 ;; tuxpaint-config compresses its own documentation;
5435 ;; make sure it uses flags for reproducibility.
5436 (("gzip") "gzip --no-name"))))
5437 (add-before 'install 'make-install-dirs
5438 (lambda* (#:key outputs #:allow-other-keys)
5439 (let ((out (assoc-ref outputs "out")))
5440 (mkdir-p (string-append out "/bin"))
5441 #t))))))
5442 (home-page (package-home-page tuxpaint))
5443 (synopsis "Configure Tux Paint")
5444 (description
5445 "Tux Paint Config is a graphical configuration editor for Tux Paint.")
5446 (license license:gpl2))) ;no "or later" present
5447
5448 (define-public supertux
5449 (package
5450 (name "supertux")
5451 (version "0.6.2")
5452 (source (origin
5453 (method url-fetch)
5454 (uri (string-append "https://github.com/SuperTux/supertux/"
5455 "releases/download/v" version "/SuperTux-v"
5456 version "-Source.tar.gz"))
5457 (file-name (string-append name "-" version ".tar.gz"))
5458 (sha256
5459 (base32
5460 "167m3z4m8n76dvbv42m1fnvabpbpsxvr28zk9641916jl9pfba96"))
5461 (patches
5462 (search-patches "supertux-unbundle-squirrel.patch"))))
5463 (arguments
5464 '(#:tests? #f
5465 #:configure-flags '("-DINSTALL_SUBDIR_BIN=bin"
5466 "-DUSE_SYSTEM_PHYSFS=ON")
5467 #:phases
5468 (modify-phases %standard-phases
5469 (add-after 'unpack 'patch-squirrel-path
5470 (lambda* (#:key inputs #:allow-other-keys)
5471 (let ((squirrel (assoc-ref inputs "squirrel")))
5472 (substitute* "CMakeLists.txt"
5473 (("set\\(SQUIRREL_PREFIX.*")
5474 (string-append "set(SQUIRREL_PREFIX " squirrel ")"))
5475 (("add_dependencies\\(supertux2_lib squirrel\\)") "")
5476 (("\\$\\{SQUIRREL_PREFIX\\}/include")
5477 (string-append "${SQUIRREL_PREFIX}/include/squirrel"))))
5478 #t)))))
5479 (build-system cmake-build-system)
5480 (inputs (list sdl2
5481 sdl2-image
5482 sdl2-mixer
5483 openal
5484 mesa
5485 glew
5486 libvorbis
5487 libogg
5488 physfs
5489 curl
5490 boost
5491 freetype
5492 squirrel))
5493 (native-inputs
5494 (list pkg-config))
5495 (synopsis "2D platformer game")
5496 (description "SuperTux is a classic 2D jump'n run sidescroller game in
5497 a style similar to the original Super Mario games.")
5498 (home-page "https://supertux.org/")
5499 (license license:gpl3+)))
5500
5501 (define-public tintin++
5502 (package
5503 (name "tintin++")
5504 (version "2.02.11")
5505 (source
5506 (origin
5507 (method url-fetch)
5508 (uri (string-append "mirror://sourceforge/tintin/TinTin++ Source Code/"
5509 (string-drop-right version 1)
5510 "/tintin-" version ".tar.gz"))
5511 (sha256
5512 (base32 "1xdim1ckq1kgjyxmghcnvnahq1llv2y70gz3yyvzbli63vpqk4mk"))))
5513 (inputs
5514 (list gnutls pcre readline zlib))
5515 (arguments
5516 '(#:tests? #f ; no test suite
5517 #:phases
5518 (modify-phases %standard-phases
5519 ;; The source is in tt/src.
5520 (add-before 'configure 'chdir
5521 (lambda _
5522 (chdir "src")
5523 #t)))))
5524 (build-system gnu-build-system)
5525 (home-page "https://tintin.mudhalla.net/")
5526 (synopsis "MUD client")
5527 (description
5528 "TinTin++ is a MUD client which supports MCCP (Mud Client Compression
5529 Protocol), MMCP (Mud Master Chat Protocol), xterm 256 colors, most TELNET
5530 options used by MUDs, as well as those required to login via telnet on
5531 Linux / Mac OS X servers, and an auto mapper with a VT100 map display.")
5532 (license license:gpl3+)))
5533
5534 (define-public laby
5535 (package
5536 (name "laby")
5537 (version "0.7.0")
5538 (source
5539 (origin (method git-fetch)
5540 (uri (git-reference
5541 (url "https://github.com/sgimenez/laby")
5542 (commit (string-append name "-" version))))
5543 (file-name (git-file-name name version))
5544 (sha256
5545 (base32
5546 "1y6nfxcjhqg9bb81hs0wijg7kcwk5kff81rgd8bsv5ps7ia9nj6b"))
5547 (patches (search-patches "laby-make-install.patch"))))
5548 (build-system gnu-build-system)
5549 (inputs
5550 `(("lablgtk3" ,lablgtk3)
5551 ("ocaml" ,ocaml)
5552 ("ocaml-findlib" ,ocaml-findlib)
5553 ("ocamlbuild" ,ocamlbuild)))
5554 (arguments
5555 '(#:phases
5556 (modify-phases %standard-phases
5557 (delete 'configure)
5558 (add-before 'build 'set-library-path
5559 (lambda* (#:key inputs #:allow-other-keys)
5560 (let ((lablgtk (assoc-ref inputs "lablgtk3")))
5561 (setenv "LD_LIBRARY_PATH"
5562 (string-append lablgtk "/lib/ocaml/stublibs"))))))
5563 #:tests? #f ; no 'check' target
5564 #:make-flags
5565 (list (string-append "PREFIX=" (assoc-ref %outputs "out")) "all")))
5566 (home-page "https://sgimenez.github.io/laby/")
5567 (synopsis "Programming game")
5568 (description "Learn programming, playing with ants and spider webs ;-)
5569 Your robot ant can be programmed in many languages: OCaml, Python, C, C++,
5570 Java, Ruby, Lua, JavaScript, Pascal, Perl, Scheme, Vala, Prolog. Experienced
5571 programmers may also add their own favorite language.")
5572 (license license:gpl3+)))
5573
5574 (define-public bambam
5575 (package
5576 (name "bambam")
5577 (version "1.0.0")
5578 (source
5579 (origin
5580 (method git-fetch)
5581 (uri (git-reference
5582 (url "https://github.com/porridge/bambam")
5583 (commit (string-append "v" version))))
5584 (file-name (git-file-name name version))
5585 (sha256
5586 (base32 "18cwd1wpyyx8y61cags9bkdhx9x858xicc4y1c9c2s0xjmgzhl3i"))))
5587 (build-system python-build-system)
5588 (arguments
5589 `(#:tests? #f ; no tests
5590 #:phases
5591 (modify-phases %standard-phases
5592 (delete 'build) ; nothing to build
5593 (replace 'install
5594 (lambda* (#:key outputs #:allow-other-keys)
5595 (let* ((out (assoc-ref outputs "out"))
5596 (bin (string-append out "/bin"))
5597 (share (string-append out "/share")))
5598 (mkdir-p bin)
5599 (copy-file "bambam.py" (string-append bin "/bambam"))
5600 (install-file "bambam.6" (string-append share "/man/man6"))
5601 (copy-recursively "data" (string-append share "/bambam/data")))
5602 #t)))))
5603 (inputs
5604 (list python-pygame))
5605 (home-page "https://github.com/porridge/bambam")
5606 (synopsis "Keyboard mashing and doodling game for babies")
5607 (description "Bambam is a simple baby keyboard (and gamepad) masher
5608 application that locks the keyboard and mouse and instead displays bright
5609 colors, pictures, and sounds.")
5610 (license license:gpl3+)))
5611
5612 (define-public mrrescue
5613 (package
5614 (name "mrrescue")
5615 (version "1.02e")
5616 (source (origin
5617 (method url-fetch)
5618 (uri (string-append
5619 "https://github.com/SimonLarsen/mrrescue/releases/"
5620 "download/" version "/mrrescue" version ".love"))
5621 (file-name (string-append name "-" version ".love"))
5622 (sha256
5623 (base32
5624 "0jwzbwkgp1l5ia6c7s760gmdirbsncp6nfqp7vqdqsfb63la9gl2"))))
5625 (build-system trivial-build-system)
5626 (arguments
5627 `(#:modules ((guix build utils))
5628 #:builder
5629 (begin
5630 (use-modules (guix build utils))
5631 (let* ((out (assoc-ref %outputs "out"))
5632 (script (string-append out "/bin/" ,name))
5633 (data (string-append out "/share/" ,name))
5634 (source (assoc-ref %build-inputs "source"))
5635 (unzip (search-input-file %build-inputs "/bin/unzip"))
5636 (patch (search-input-file %build-inputs "/bin/patch"))
5637 (bash (search-input-file %build-inputs "/bin/bash"))
5638 (love (search-input-file %build-inputs "/bin/love")))
5639
5640 (mkdir-p (dirname script))
5641 (with-output-to-file script
5642 (lambda ()
5643 (format #t "#!~a~%" bash)
5644 (format #t "exec -a ~a \"~a\" \"~a\"~%" ,name love data)))
5645 (chmod script #o755)
5646
5647 ;; The better way to package this game would be to install *only* the
5648 ;; script above, pointing to the unextracted .love file in the store.
5649 ;; However, mrrescue 1.02e needs to be patched to work with Love 11.
5650 ;; Instead of extracting the .love file, patching it, and re-zipping
5651 ;; it to the store, simply point the script to the extracted patched
5652 ;; data directory directly.
5653 (mkdir-p data)
5654 (with-directory-excursion data
5655 (invoke unzip source)
5656 (invoke patch "-p1" "-i"
5657 (assoc-ref %build-inputs "love-11.patch")))
5658 #t))))
5659 (native-inputs
5660 `(("unzip" ,unzip)
5661 ("patch" ,patch)
5662 ("love-11.patch" ,(search-patch "mrrescue-support-love-11.patch"))))
5663 (inputs
5664 (list bash love))
5665 (home-page "https://tangramgames.dk/games/mrrescue")
5666 (synopsis "Arcade-style fire fighting game")
5667 (description
5668 "Mr. Rescue is an arcade styled 2d action game centered around evacuating
5669 civilians from burning buildings. The game features fast-paced fire
5670 extinguishing action, intense boss battles, a catchy soundtrack, and lots of
5671 throwing people around in pseudo-randomly generated buildings.")
5672 (license (list license:zlib ; for source code
5673 license:cc-by-sa3.0)))) ; for graphics and music assets
5674
5675 (define-public hyperrogue
5676 (package
5677 (name "hyperrogue")
5678 (version "11.3a")
5679 ;; When updating this package, be sure to update the "hyperrogue-data"
5680 ;; origin in native-inputs.
5681 (source (origin
5682 (method url-fetch)
5683 (uri (string-append
5684 "https://www.roguetemple.com/z/hyper/hyperrogue"
5685 (string-join (string-split version #\.) "")
5686 "-src.tgz"))
5687 (sha256
5688 (base32
5689 "1yxabbswq02fc5frigvs43f83m5vlxybc7n5mynkwzj2c70lfp2k"))))
5690 (build-system gnu-build-system)
5691 (arguments
5692 `(#:tests? #f ; no check target
5693 #:make-flags '("HYPERROGUE_USE_GLEW=1"
5694 "HYPERROGUE_USE_PNG=1")
5695 #:phases
5696 (modify-phases %standard-phases
5697 (add-after 'set-paths 'set-sdl-paths
5698 (lambda* (#:key inputs #:allow-other-keys)
5699 (setenv "CPATH"
5700 (string-append (or (getenv "CPATH") "") ":"
5701 (assoc-ref inputs "sdl-union")
5702 "/include/SDL"))))
5703 (replace 'configure
5704 (lambda* (#:key inputs outputs #:allow-other-keys)
5705 (let* ((out (assoc-ref outputs "out"))
5706 (share-dir (string-append out "/share/hyperrogue"))
5707 (dejavu-dir (string-append
5708 (assoc-ref inputs "font-dejavu")
5709 "/share/fonts/truetype"))
5710 (dejavu-font "DejaVuSans-Bold.ttf")
5711 (music-file "hyperrogue-music.txt"))
5712 ;; Fix font and music paths.
5713 (substitute* "basegraph.cpp"
5714 ((dejavu-font)
5715 (string-append dejavu-dir "/" dejavu-font)))
5716 (substitute* music-file
5717 (("\\*/")
5718 (string-append share-dir "/sounds/")))
5719 (substitute* "sound.cpp"
5720 (("musicfile = \"\"")
5721 (string-append "musicfile = \""
5722 share-dir "/" music-file "\"")))
5723 ;; Disable build machine CPU optimizations and warnings treated
5724 ;; as errors.
5725 (substitute* "Makefile"
5726 (("-march=native") "")
5727 (("-Werror") "")))
5728 #t))
5729 (replace 'install
5730 (lambda* (#:key inputs outputs #:allow-other-keys)
5731 (let* ((out (assoc-ref outputs "out"))
5732 (bin (string-append out "/bin"))
5733 (share-dir (string-append out "/share/hyperrogue")))
5734 (mkdir-p bin)
5735 (install-file "hyperrogue" bin)
5736 (install-file "hyperrogue-music.txt" share-dir))
5737 #t))
5738 (add-after 'install 'install-data
5739 (lambda* (#:key inputs outputs #:allow-other-keys)
5740 (let* ((data (assoc-ref inputs "hyperrogue-data"))
5741 (out (assoc-ref outputs "out"))
5742 (sounds (string-append out "/share/hyperrogue/sounds"))
5743 (unzip (search-input-file inputs "/bin/unzip")))
5744 ;; Extract media license information into sounds directory.
5745 (invoke unzip "-j" data
5746 (string-append
5747 "hyperrogue"
5748 (string-join (string-split ,version #\.) "")
5749 "/sounds/credits.txt") "-d" sounds)
5750 ;; Extract sounds and music into sounds directory.
5751 (invoke "unzip" "-j" data
5752 (string-append
5753 "hyperrogue"
5754 (string-join (string-split ,version #\.) "")
5755 "/*.ogg") "-d" sounds)))))))
5756 (native-inputs
5757 `(("hyperrogue-data"
5758 ,(origin
5759 (method url-fetch)
5760 (uri
5761 (string-append
5762 "https://www.roguetemple.com/z/hyper/hyperrogue"
5763 (string-join (string-split version #\.) "")
5764 "-win.zip"))
5765 (sha256
5766 (base32
5767 "11yhbia45f1w9z0j67h9nynwjqmvakr9l6rnrmdrdkzin6lvzzj4"))))
5768 ("unzip" ,unzip)))
5769 (inputs
5770 (list font-dejavu glew libpng
5771 (sdl-union (list sdl sdl-gfx sdl-mixer sdl-ttf))))
5772 (home-page "https://www.roguetemple.com/z/hyper/")
5773 (synopsis "Non-euclidean graphical rogue-like game")
5774 (description
5775 "HyperRogue is a game in which the player collects treasures and fights
5776 monsters -- rogue-like but for the fact that it is played on the hyperbolic
5777 plane and not in euclidean space.
5778
5779 In HyperRogue, the player can move through different parts of the world, which
5780 are home to particular creatures and may be subject to their own rules of
5781 \"physics\".
5782
5783 While the game can use ASCII characters to display the the classical rogue
5784 symbols, it still needs graphics to render the non-euclidean world.")
5785 (license (list license:bsd-3 ; glew.c, mtrand.*
5786 license:cc-by-sa3.0 ; music
5787 license:cc-by-sa4.0 ; sounds
5788 license:cc0
5789 license:public-domain ; direntx.*, some sounds
5790 license:zlib ; savepng.*
5791 license:gpl2+)))) ; remaining files
5792
5793 (define-public kobodeluxe
5794 (package
5795 (name "kobodeluxe")
5796 (version "0.5.1")
5797 (source (origin
5798 (method url-fetch)
5799 (uri (string-append "http://olofson.net/kobodl/download/KoboDeluxe-"
5800 version ".tar.bz2"))
5801 (sha256
5802 (base32
5803 "0b2wvdpnmaibsy419c16dfwj5kvd3pccby2aaqvm964x74592yqg"))
5804 (patches (search-patches
5805 "kobodeluxe-const-charp-conversion.patch"
5806 "kobodeluxe-enemies-pipe-decl.patch"
5807 "kobodeluxe-graphics-window-signed-char.patch"
5808 "kobodeluxe-manpage-minus-not-hyphen.patch"
5809 "kobodeluxe-midicon-segmentation-fault.patch"
5810 "kobodeluxe-paths.patch"))))
5811 (build-system gnu-build-system)
5812 (arguments
5813 '(#:configure-flags
5814 (list (string-append "CPPFLAGS=-I"
5815 (assoc-ref %build-inputs "sdl-union")
5816 "/include/SDL"))))
5817 (inputs
5818 (list glu
5819 (sdl-union (list sdl sdl-image))))
5820 (synopsis "Shooter with space station destruction")
5821 (description
5822 "Kobo Deluxe is an enhanced version of Akira Higuchi's XKobo graphical game
5823 for Un*x systems with X11.")
5824 (home-page "http://olofson.net/kobodl/")
5825 (license license:gpl2+)))
5826
5827 (define-public freeciv
5828 (package
5829 (name "freeciv")
5830 (version "2.6.5")
5831 (source
5832 (origin
5833 (method url-fetch)
5834 (uri (list (string-append
5835 "http://files.freeciv.org/stable/freeciv-"
5836 version ".tar.bz2")
5837 (string-append
5838 "mirror://sourceforge/freeciv/Freeciv%20"
5839 (version-major+minor version) "/" version
5840 "/freeciv-" version ".tar.bz2")))
5841 (sha256
5842 (base32 "0ngcj59ak71i6m8yvbr0g3aryzpw1scalpdzgfqsq4mf9p3y2r1f"))))
5843 (build-system gnu-build-system)
5844 (inputs
5845 (list curl cyrus-sasl gtk+ sdl-mixer zlib))
5846 (native-inputs
5847 (list pkg-config))
5848 (home-page "http://www.freeciv.org/")
5849 (synopsis "Turn-based empire building strategy game")
5850 (description "Freeciv is a turn-based empire building strategy game
5851 inspired by the history of human civilization. The game commences in
5852 prehistory and your mission is to lead your tribe from the Stone Age
5853 into the Space Age.")
5854 (license license:gpl2+)))
5855
5856 (define-public no-more-secrets
5857 (package
5858 (name "no-more-secrets")
5859 (version "0.3.3")
5860 (source
5861 (origin
5862 (method git-fetch)
5863 (uri (git-reference
5864 (url "https://github.com/bartobri/no-more-secrets")
5865 (commit (string-append "v" version))))
5866 (file-name (git-file-name name version))
5867 (sha256
5868 (base32 "1zfv4qabikf8w9winsr4brxrdvs3f0d7xvydksyx8bydadsm2v2h"))))
5869 (build-system gnu-build-system)
5870 (arguments
5871 `(#:tests? #f
5872 #:make-flags (list "CC=gcc" "all-ncurses"
5873 (string-append "prefix="
5874 (assoc-ref %outputs "out")))
5875 #:phases
5876 (modify-phases %standard-phases
5877 (delete 'configure))))
5878 (inputs
5879 (list ncurses))
5880 (home-page "https://github.com/bartobri/no-more-secrets")
5881 (synopsis "Recreation of data decryption effect in \"Sneakers\"")
5882 (description
5883 "@code{No More Secrets} provides a command line tool called \"nms\"
5884 that recreates the famous data decryption effect seen on screen in the 1992
5885 movie \"Sneakers\".
5886
5887 This command works on piped data. Pipe any ASCII or UTF-8 text to nms, and
5888 it will apply the hollywood effect, initially showing encrypted data, then
5889 starting a decryption sequence to reveal the original plaintext characters.")
5890 (license license:expat)))
5891
5892 (define-public megaglest-data
5893 (package
5894 (name "megaglest-data")
5895 (version "3.13.0")
5896 (source
5897 (origin
5898 (method url-fetch)
5899 (uri (string-append
5900 "https://github.com/MegaGlest/megaglest-data"
5901 "/releases/download/" version "/megaglest-data-"
5902 version ".tar.xz"))
5903 (sha256
5904 (base32
5905 "0ipgza33z89fw3si32iafm981f3fvm0zldvbxj29whghd2k3rpj3"))))
5906 (build-system cmake-build-system)
5907 (arguments
5908 `(#:tests? #f))
5909 (home-page "https://megaglest.org/")
5910 (synopsis "Data files for MegaGlest")
5911 (description "This package contains the data files required for MegaGlest.")
5912 (license license:cc-by-sa3.0)))
5913
5914 (define-public megaglest
5915 (package
5916 (name "megaglest")
5917 (version "3.13.0")
5918 (source
5919 (origin
5920 (method url-fetch)
5921 (uri (string-append
5922 "https://github.com/MegaGlest/megaglest-source"
5923 "/releases/download/" version "/megaglest-source-"
5924 version ".tar.xz"))
5925 (sha256
5926 (base32
5927 "1ffck3ii1wp5k3nn5p0ga06jgp7pzk4zw0xln3xim2w7qrxzdzh9"))))
5928 (build-system cmake-build-system)
5929 (inputs
5930 `(("curl" ,curl)
5931 ("fontconfig" ,fontconfig)
5932 ("ftgl" ,ftgl)
5933 ("glew" ,glew)
5934 ("libjpeg-turbo" ,libjpeg-turbo)
5935 ("megaglest-data" ,megaglest-data)
5936 ("mesa" ,mesa)
5937 ("miniupnpc" ,miniupnpc)
5938 ("openal" ,openal)
5939 ("libircclient" ,libircclient)
5940 ("libpng" ,libpng)
5941 ("libvorbis" ,libvorbis)
5942 ("lua" ,lua)
5943 ("sdl2" ,sdl2)
5944 ("wxwidgets" ,wxwidgets)))
5945 (native-inputs
5946 (list cppunit pkg-config))
5947 (arguments
5948 `(#:configure-flags
5949 (list "-DCMAKE_CXX_FLAGS=-fcommon"
5950 "-DCMAKE_C_FLAGS=-fcommon"
5951 (string-append "-DCUSTOM_DATA_INSTALL_PATH="
5952 (assoc-ref %build-inputs "megaglest-data")
5953 "/share/megaglest")
5954 "-DBUILD_MEGAGLEST_TESTS=ON")
5955 #:phases
5956 (modify-phases %standard-phases
5957 (add-after 'unpack 'fix-ini-search-path
5958 (lambda* (#:key outputs #:allow-other-keys)
5959 (substitute* "source/glest_game/global/config.cpp"
5960 (("/usr/share/megaglest/")
5961 (string-append (assoc-ref outputs "out")
5962 "/share/megaglest/"))))))
5963 #:test-target "megaglest_tests"))
5964 (home-page "https://megaglest.org/")
5965 (synopsis "3D real-time strategy (RTS) game")
5966 (description "MegaGlest is a cross-platform 3D real-time strategy (RTS)
5967 game, where you control the armies of one of seven different factions: Tech,
5968 Magic, Egypt, Indians, Norsemen, Persian or Romans.")
5969 (license license:gpl2+)))
5970
5971 (define-public freegish
5972 (let ((commit "8795cd7adc95957883f2d3465eb9036a774667a7")
5973 (revision "1"))
5974 (package
5975 (name "freegish")
5976 (version (string-append "0-" revision "." (string-take commit 9)))
5977 (source (origin
5978 (method git-fetch)
5979 (uri (git-reference
5980 (url "https://github.com/freegish/freegish")
5981 (commit commit)))
5982 (file-name (git-file-name name version))
5983 (sha256
5984 (base32
5985 "1p1zf5qqagmcpi1db2bs02cnalpy3qiymp6yzan7k1bhmv859gsx"))
5986 (modules '((guix build utils)))
5987 ;; The audio files in the "music" directory are licensed under
5988 ;; CC-BY-NC, so we delete them.
5989 (snippet
5990 '(begin
5991 (delete-file-recursively "music")
5992 #t))))
5993 (build-system cmake-build-system)
5994 (arguments
5995 `(#:tests? #f ; no tests included
5996 #:configure-flags
5997 (list "-DCMAKE_INSTALL_FHS=ON")
5998 #:phases
5999 (modify-phases %standard-phases
6000 (add-after 'unpack 'set-DATAPATH
6001 (lambda* (#:key outputs #:allow-other-keys)
6002 (substitute* "CMakeLists.txt"
6003 (("^option\\(INSTALL_FHS" line)
6004 (string-append "add_definitions(-DDATAPATH=\""
6005 (assoc-ref outputs "out") "/share/freegish\")\n"
6006 line)))
6007 #t)))))
6008 (inputs
6009 (list (sdl-union (list sdl sdl-mixer))
6010 openal
6011 libvorbis
6012 libogg
6013 mesa
6014 libpng
6015 zlib))
6016 (home-page "https://github.com/freegish/freegish")
6017 (synopsis "Side-scrolling physics platformer with a ball of tar")
6018 (description "In FreeGish you control Gish, a ball of tar who lives
6019 happily with his girlfriend Brea, until one day a mysterious dark creature
6020 emerges from a sewer hole and pulls her below ground.")
6021 ;; The textures are available under the Expat license. All other assets
6022 ;; (including levels) are covered under CC-BY-SA or public domain. The
6023 ;; source code is under GPLv2+.
6024 (license (list license:gpl2+
6025 license:expat
6026 license:public-domain
6027 license:cc-by-sa3.0)))))
6028
6029 (define-public cdogs-sdl
6030 (package
6031 (name "cdogs-sdl")
6032 (version "0.8.0")
6033 (source
6034 (origin
6035 (method git-fetch)
6036 (uri (git-reference
6037 (url "https://github.com/cxong/cdogs-sdl")
6038 (commit version)))
6039 (file-name (git-file-name name version))
6040 (sha256
6041 (base32 "0vx37zb2iw7sfw5a2bs97ydlmb301nvy485ybdm8g46c5hn9s13c"))))
6042 (build-system cmake-build-system)
6043 (arguments
6044 `(#:configure-flags
6045 (list (string-append "-DCDOGS_DATA_DIR="
6046 (assoc-ref %outputs "out")
6047 "/share/cdogs-sdl/"))))
6048 (native-inputs
6049 (list pkg-config))
6050 (inputs
6051 (list gtk+ mesa sdl2 sdl2-image sdl2-mixer))
6052 (home-page "https://cxong.github.io/cdogs-sdl/")
6053 (synopsis "Classic overhead run-and-gun game")
6054 (description "C-Dogs SDL is a classic overhead run-and-gun game,
6055 supporting up to 4 players in co-op and deathmatch modes. Customize your
6056 player, choose from many weapons, and blast, slide and slash your way through
6057 over 100 user-created campaigns.")
6058 ;; GPLv2+ for code (includes files under BSD-2 and BSD-3),
6059 ;; CC0/CC-BY/CC-BY-SA for assets.
6060 (license (list license:gpl2+
6061 license:bsd-2
6062 license:bsd-3
6063 license:cc0
6064 license:cc-by3.0
6065 license:cc-by-sa3.0))))
6066
6067 (define-public kiki
6068 (package
6069 (name "kiki")
6070 (version "1.0.2")
6071 (source (origin
6072 (method url-fetch)
6073 (uri (string-append "mirror://sourceforge/kiki/kiki-src/"
6074 version "/kiki-" version "-src.tgz"))
6075 (sha256
6076 (base32
6077 "0ihjdsxbn8z3cz0gpcprafiipcqaiskgdnh1rhmw4qff8dszalbn"))
6078 (modules '((guix build utils)))
6079 (snippet
6080 '(begin
6081 (for-each delete-file (find-files "." "\\.dll$"))
6082 #t))
6083 (patches
6084 (search-patches "kiki-level-selection-crash.patch"
6085 "kiki-makefile.patch"
6086 "kiki-missing-includes.patch"
6087 "kiki-portability-64bit.patch"))))
6088 (build-system gnu-build-system)
6089 (arguments
6090 `(#:tests? #f ; there are no tests
6091 #:make-flags '("CXX=g++")
6092 #:phases
6093 (modify-phases %standard-phases
6094 (replace 'configure
6095 (lambda* (#:key inputs outputs #:allow-other-keys)
6096 (setenv "CPLUS_INCLUDE_PATH"
6097 (string-append
6098 (search-input-directory inputs "include/SDL") ":"
6099 (search-input-directory inputs "include/python2.7")
6100 ":" (or (getenv "CPLUS_INCLUDE_PATH") "")))
6101 (substitute* "src/main/main.cpp"
6102 (("#include <SDL.h>" line)
6103 (string-append line "
6104 #define K_INCLUDE_GLUT
6105 #include \"KIncludeTools.h\""))
6106 (("// initialize SDL" line)
6107 (string-append "glutInit(&argc,argv);\n" line)))
6108 (substitute* "src/main/KikiController.cpp"
6109 (("getenv\\(\"KIKI_HOME\"\\)")
6110 (string-append "\"" (assoc-ref outputs "out") "/share/kiki/\"")))
6111 (substitute* "linux/Makefile"
6112 (("CXXOPTS =" line)
6113 (string-append line " -fpermissive"))
6114 (("PYTHON_VERSION=.*") "PYTHON_VERSION=2.7")
6115 (("PYTHONHOME =.*")
6116 (string-append "PYTHONHOME = "
6117 (assoc-ref inputs "python")
6118 "/lib/python2.7/"))
6119 (("\\$\\(GLLIBS\\)" line)
6120 (string-append line " -lm -lpython2.7")))
6121 (substitute* "src/main/KikiPythonWidget.h"
6122 (("#define __KikiPythonWidget" line)
6123 (string-append line "\n#include \"KikiPython.h\"")))
6124 #t))
6125 (add-before 'build 'build-kodilib
6126 (lambda* (#:key make-flags #:allow-other-keys)
6127 (with-directory-excursion "kodilib/linux"
6128 (apply invoke "make" make-flags))))
6129 (add-after 'build-kodilib 'chdir
6130 (lambda _ (chdir "linux") #t))
6131 (replace 'install
6132 (lambda* (#:key outputs #:allow-other-keys)
6133 (let* ((out (assoc-ref outputs "out"))
6134 (bin (string-append out "/bin"))
6135 (share (string-append out "/share/kiki")))
6136 (mkdir-p bin)
6137 (mkdir-p share)
6138 (install-file "kiki" bin)
6139 (copy-recursively "../py" (string-append share "/py"))
6140 (copy-recursively "../sound" (string-append share "/sound"))
6141 #t))))))
6142 (inputs
6143 `(("glu" ,glu)
6144 ;; Kiki builds fine with freeglut 3.0.0 but segfaults on start.
6145 ("freeglut" ,freeglut-2.8)
6146 ("sdl-union" ,(sdl-union (list sdl
6147 sdl-mixer
6148 sdl-image)))
6149 ("python" ,python-2)))
6150 (native-inputs
6151 (list swig))
6152 (home-page "http://kiki.sourceforge.net/")
6153 (synopsis "3D puzzle game")
6154 (description "Kiki the nano bot is a 3D puzzle game. It is basically a
6155 mixture of the games Sokoban and Kula-World. Your task is to help Kiki, a
6156 small robot living in the nano world, repair its maker.")
6157 ;; See <http://metadata.ftp-master.debian.org/changelogs/main/k/
6158 ;; kiki-the-nano-bot/kiki-the-nano-bot_1.0.2+dfsg1-4_copyright>
6159 ;; for a statement from the author.
6160 (license license:public-domain)))
6161
6162 (define-public teeworlds
6163 (package
6164 (name "teeworlds")
6165 (version "0.7.5")
6166 (source (origin
6167 (method git-fetch)
6168 (uri (git-reference
6169 (url "https://github.com/teeworlds/teeworlds")
6170 (commit version)
6171 ;; There are two submodules in datasrc/{languages,maps}
6172 (recursive? #t)))
6173 (file-name (git-file-name name version))
6174 (sha256
6175 (base32
6176 "1l19ksmimg6b8zzjy0skyhh7z11ql7n5gvilkv7ay5x2b9ndbqwz"))
6177 (modules '((guix build utils)
6178 (ice-9 ftw)
6179 (ice-9 regex)
6180 (srfi srfi-1)
6181 (srfi srfi-26)))
6182 (snippet ; remove bundled libraries except md5
6183 '(let ((base-dir "src/engine/external/"))
6184 (for-each (compose (cut delete-file-recursively <>)
6185 (cut string-append base-dir <>))
6186 (remove (cut string-match "(^.)|(^md5$)" <>)
6187 (scandir base-dir)))
6188 #t))))
6189 (build-system cmake-build-system)
6190 (arguments
6191 `(#:test-target "run_tests"
6192 #:phases
6193 (modify-phases %standard-phases
6194 (add-after 'unpack 'patch-paths
6195 (lambda* (#:key outputs #:allow-other-keys)
6196 ;; Embed path to assets.
6197 (substitute* "src/engine/shared/storage.cpp"
6198 (("#define DATA_DIR.*")
6199 (string-append "#define DATA_DIR \""
6200 (assoc-ref outputs "out")
6201 "/share/teeworlds/data"
6202 "\"")))
6203 #t))
6204 (add-after 'unpack 'replace-font
6205 (lambda* (#:key inputs #:allow-other-keys)
6206 (delete-file "datasrc/fonts/DejaVuSans.ttf")
6207 (symlink (string-append (assoc-ref inputs "font-dejavu")
6208 "/share/fonts/truetype/DejaVuSans.ttf")
6209 "datasrc/fonts/DejaVuSans.ttf")
6210 #t)))))
6211 (inputs
6212 (list freetype
6213 font-dejavu
6214 glu
6215 json-parser
6216 mesa
6217 pnglite
6218 sdl2
6219 sdl2-image
6220 sdl2-mixer
6221 wavpack
6222 openssl
6223 zlib))
6224 (native-inputs
6225 `(("googletest" ,googletest)
6226 ("python" ,python-wrapper)
6227 ("pkg-config" ,pkg-config)))
6228 (home-page "https://www.teeworlds.com")
6229 (synopsis "2D retro multiplayer shooter game")
6230 (description "Teeworlds is an online multiplayer game. Battle with up to
6231 16 players in a variety of game modes, including Team Deathmatch and Capture
6232 The Flag. You can even design your own maps!")
6233 (license (list license:bsd-3 license:cc-by-sa3.0)))) ; game+maps&languages
6234
6235 (define-public enigma
6236 (package
6237 (name "enigma")
6238 (version "1.21")
6239 (source (origin
6240 (method url-fetch)
6241 (uri (string-append "mirror://sourceforge/enigma-game/"
6242 "Release%20" version "/enigma-"
6243 version ".tar.gz"))
6244 (sha256
6245 (base32
6246 "00ffh9pypj1948pg3q9sjp1nmiabh52p5c8wpg9n1dcfgl3cywnq"))))
6247 (build-system gnu-build-system)
6248 (arguments
6249 `(#:configure-flags
6250 (list "--with-system-enet")
6251 #:phases
6252 (modify-phases %standard-phases
6253 (add-after 'unpack 'fix-build-with-new-gcc
6254 (lambda _
6255 ;; Fix build with GCC6 and later by avoiding comparing ifstream
6256 ;; to NULL. Can be removed for versions > 1.21.
6257 (substitute* "src/lev/Proxy.cc"
6258 (("ifs != NULL")
6259 "ifs"))
6260 #t))
6261 (add-after 'unpack 'find-sdl
6262 (lambda _
6263 (substitute* "configure"
6264 (("SDL_ttf.h") "SDL/SDL_ttf.h"))
6265 (substitute* '("tools/ttf2bmf.cc"
6266 "lib-src/enigma-core/ecl_font.cc"
6267 "lib-src/enigma-core/ecl_video.cc"
6268 "lib-src/enigma-core/ecl_buffer.hh"
6269 "src/SoundEngine.cc"
6270 "src/SoundEngine.hh"
6271 "src/MusicManager.cc"
6272 "src/MusicManager.hh"
6273 "src/d_models.cc"
6274 "src/main.cc"
6275 "src/network.cc")
6276 (("#include \"SDL_(image|ttf|mixer|types|syswm|mutex).h\"" line header)
6277 (string-append "#include \"SDL/SDL_" header ".h\"")))
6278 (substitute* "src/main.cc"
6279 (("#include <SDL_(image|ttf|mixer).h>" line header)
6280 (string-append "#include \"SDL/SDL_" header ".h\"")))
6281 #t)))))
6282 (inputs
6283 (list xerces-c
6284 (sdl-union (list sdl sdl-image sdl-mixer sdl-ttf)) curl
6285 enet))
6286 (native-inputs
6287 (list pkg-config imagemagick))
6288 (home-page "https://www.nongnu.org/enigma")
6289 (synopsis "Puzzle game with a dexterity component")
6290 (description "Enigma is a puzzle game with 550 unique levels. The object
6291 of the game is to find and uncover pairs of identically colored ‘Oxyd’ stones.
6292 Simple? Yes. Easy? Certainly not! Hidden traps, vast mazes, laser beams,
6293 and most of all, countless hairy puzzles usually block your direct way to the
6294 Oxyd stones. Enigma’s game objects (and there are hundreds of them, lest you
6295 get bored) interact in many unexpected ways, and since many of them follow the
6296 laws of physics (Enigma’s special laws of physics, that is), controlling them
6297 with the mouse isn’t always trivial.")
6298 (license license:gpl2+)))
6299
6300 (define-public chroma
6301 (package
6302 (name "chroma")
6303 (version "1.20")
6304 (source (origin
6305 (method url-fetch)
6306 (uri (string-append "http://level7.org.uk/chroma/download/chroma-"
6307 version ".tar.bz2"))
6308 (sha256
6309 (base32
6310 "02hn448ckfxbx2fqr9wgf66rwl0vr4gl87yvsr5fc99zz9zw2f5v"))))
6311 (build-system gnu-build-system)
6312 (arguments
6313 `(#:tests? #f)) ; no tests included
6314 (inputs
6315 `(("sdl-union" ,(sdl-union (list sdl sdl-image sdl-mixer sdl-ttf)))
6316 ("freetype" ,freetype)
6317 ("ncurses" ,ncurses)
6318 ("fontconfig" ,fontconfig)
6319 ("libxft" ,libxft)))
6320 (native-inputs
6321 (list pkg-config))
6322 (home-page "http://level7.org.uk/chroma/")
6323 (synopsis "Abstract puzzle game")
6324 (description "Chroma is an abstract puzzle game. A variety of colourful
6325 shapes are arranged in a series of increasingly complex patterns, forming
6326 fiendish traps that must be disarmed and mysterious puzzles that must be
6327 manipulated in order to give up their subtle secrets. Initially so
6328 straightforward that anyone can pick it up and begin to play, yet gradually
6329 becoming difficult enough to tax even the brightest of minds.")
6330 (license license:gpl2+)))
6331
6332 (define-public fillets-ng
6333 (package
6334 (name "fillets-ng")
6335 (version "1.0.1")
6336 (source (origin
6337 (method url-fetch)
6338 (uri (string-append "mirror://sourceforge/fillets/"
6339 "Fish%20Fillets%20-%20Next%20Generation/"
6340 version "/fillets-ng-" version ".tar.gz"))
6341 (sha256
6342 (base32
6343 "1nljp75aqqb35qq3x7abhs2kp69vjcj0h1vxcpdyn2yn2nalv6ij"))))
6344 (build-system gnu-build-system)
6345 (arguments
6346 `(#:configure-flags
6347 (list (string-append "--with-lua="
6348 (assoc-ref %build-inputs "lua")))
6349 #:make-flags
6350 (list (string-append "CFLAGS=-I"
6351 (assoc-ref %build-inputs "sdl-union")
6352 "/include/SDL")
6353 (string-append "CXXFLAGS=-I"
6354 (assoc-ref %build-inputs "sdl-union")
6355 "/include/SDL"))
6356 #:phases
6357 (modify-phases %standard-phases
6358 ;; Lua 5.1 does not provide it.
6359 (add-after 'unpack 'do-not-link-with-lualib
6360 (lambda _
6361 (substitute* "configure"
6362 (("-llualib") ""))
6363 #t))
6364 (add-after 'install 'install-data
6365 (lambda* (#:key inputs outputs #:allow-other-keys)
6366 (let ((data (string-append (assoc-ref outputs "out")
6367 "/share/games/fillets-ng")))
6368 (mkdir-p data)
6369 (invoke "tar" "-xvf"
6370 (assoc-ref inputs "fillets-ng-data")
6371 "--strip-components=1"
6372 "-C" data)))))))
6373 (inputs
6374 (list (sdl-union (list sdl sdl-mixer sdl-image sdl-ttf)) fribidi
6375 libx11 lua-5.1))
6376 (native-inputs
6377 `(("pkg-config" ,pkg-config)
6378 ("fillets-ng-data"
6379 ,(origin
6380 (method url-fetch)
6381 (uri (string-append "mirror://sourceforge/fillets/"
6382 "Fish%20Fillets%20-%20Next%20Generation/"
6383 version "/fillets-ng-data-" version ".tar.gz"))
6384 (sha256
6385 (base32
6386 "169p0yqh2gxvhdilvjc2ld8aap7lv2nhkhkg4i1hlmgc6pxpkjgh"))))))
6387 (home-page "http://fillets.sourceforge.net/")
6388 (synopsis "Puzzle game")
6389 (description "Fish Fillets NG is strictly a puzzle game. The goal in
6390 every of the seventy levels is always the same: find a safe way out. The fish
6391 utter witty remarks about their surroundings, the various inhabitants of their
6392 underwater realm quarrel among themselves or comment on the efforts of your
6393 fish. The whole game is accompanied by quiet, comforting music.")
6394 (license license:gpl2+)))
6395
6396 (define-public crawl
6397 (package
6398 (name "crawl")
6399 (version "0.27.1")
6400 (source
6401 (origin
6402 (method url-fetch)
6403 (uri (string-append "https://github.com/crawl/crawl/releases/download/"
6404 version "/stone_soup-" version "-nodeps.tar.xz"))
6405 (sha256
6406 (base32 "0nkhyhrrma8gmwxp15j84cn1k2yvyq7ar9rd0j2qjjlv2kdis5z2"))
6407 (patches (search-patches "crawl-upgrade-saves.patch"))))
6408 (build-system gnu-build-system)
6409 (inputs
6410 `(("lua51" ,lua-5.1)
6411 ("ncurses" ,ncurses)
6412 ("sqlite" ,sqlite)
6413 ("zlib" ,zlib)))
6414 (native-inputs
6415 `(("bison" ,bison)
6416 ("flex" ,flex)
6417 ("perl" ,perl)
6418 ("python" ,python-wrapper)
6419 ("python-pyyaml" ,python-pyyaml)
6420 ("pkg-config" ,pkg-config)))
6421 (arguments
6422 `(#:make-flags
6423 (let* ((sqlite (assoc-ref %build-inputs "sqlite"))
6424 (out (assoc-ref %outputs "out")))
6425 (list (string-append "SQLITE_INCLUDE_DIR=" sqlite "/include")
6426 (string-append "prefix=" out)
6427 "SAVEDIR=~/.crawl"
6428 ;; Don't compile with SSE on systems which don't have it.
6429 ,@(match (%current-system)
6430 ((or "i686-linux" "x86_64-linux")
6431 '())
6432 (_ '("NOSSE=TRUE")))
6433 ;; don't build any bundled dependencies
6434 "BUILD_LUA="
6435 "BUILD_SQLITE="
6436 "BUILD_ZLIB="
6437 "-Csource"))
6438 #:phases
6439 (modify-phases %standard-phases
6440 (add-after 'unpack 'find-SDL-image
6441 (lambda _
6442 (substitute* "source/windowmanager-sdl.cc"
6443 (("SDL_image.h") "SDL2/SDL_image.h"))
6444 #t))
6445 (delete 'configure)
6446 (replace 'check
6447 (lambda* (#:key inputs outputs make-flags #:allow-other-keys)
6448 (setenv "HOME" (getcwd))
6449 ;; Fake a terminal for the test cases.
6450 (setenv "TERM" "xterm-256color")
6451 ;; Run the tests that don't require a debug build.
6452 (apply invoke "make" "nondebugtest"
6453 (format #f "-j~d" (parallel-job-count))
6454 ;; Force command line build for test cases.
6455 (append make-flags '("GAME=crawl" "TILES="))))))))
6456 (synopsis "Roguelike dungeon crawler game")
6457 (description "Dungeon Crawl Stone Soup (also known as \"Crawl\" or DCSS
6458 for short) is a roguelike adventure through dungeons filled with dangerous
6459 monsters in a quest to find the mystifyingly fabulous Orb of Zot.")
6460 (home-page "https://crawl.develz.org")
6461 (license (list license:gpl2+
6462 license:bsd-2
6463 license:bsd-3
6464 license:cc0
6465 license:expat
6466 license:zlib
6467 license:asl2.0))))
6468
6469 ;; The linter here claims that patch file names should start with the package
6470 ;; name. But, in this case, the patches are inherited from crawl with the
6471 ;; "crawl-" prefix instead of "crawl-tiles-".
6472 (define-public crawl-tiles
6473 (package
6474 (inherit crawl)
6475 (name "crawl-tiles")
6476 (arguments
6477 (substitute-keyword-arguments
6478 (package-arguments crawl)
6479 ((#:make-flags flags)
6480 `(let ((dejavu (assoc-ref %build-inputs "font-dejavu")))
6481 (cons*
6482 (string-append "PROPORTIONAL_FONT=" dejavu
6483 "/share/fonts/truetype/DejaVuSans.ttf")
6484 (string-append "MONOSPACED_FONT=" dejavu
6485 "/share/fonts/truetype/DejaVuSansMono.ttf")
6486 "TILES=y"
6487 ;; Rename the executable to allow parallel installation with crawl.
6488 "GAME=crawl-tiles"
6489 ,flags)))))
6490 (inputs
6491 `(,@(package-inputs crawl)
6492 ("font-dejavu" ,font-dejavu)
6493 ("freetype6" ,freetype)
6494 ("glu" ,glu)
6495 ("libpng" ,libpng)
6496 ("sdl2" ,sdl2)
6497 ("sdl2-image" ,sdl2-image)
6498 ("sdl2-mixer" ,sdl2-mixer)))
6499 (native-inputs
6500 `(,@(package-native-inputs crawl)
6501 ("pngcrush" ,pngcrush)
6502 ("which" ,which)))
6503 (synopsis "Graphical roguelike dungeon crawler game")))
6504
6505 (define-public lugaru
6506 (package
6507 (name "lugaru")
6508 (version "1.2")
6509 (source (origin
6510 (method url-fetch)
6511 (uri (string-append "https://bitbucket.org/osslugaru/lugaru/downloads/"
6512 "lugaru-" version ".tar.xz"))
6513 (sha256
6514 (base32
6515 "15zgcshy22q51rm72zi6y9z7qlgnz5iw3gczjdlir4bqmxy4gspk"))))
6516 (build-system cmake-build-system)
6517 (arguments
6518 `(#:configure-flags
6519 (list "-DSYSTEM_INSTALL=ON")
6520 ;; no test target
6521 #:tests? #f))
6522 (native-inputs
6523 (list pkg-config))
6524 (inputs
6525 `(("sdl2" ,sdl2)
6526 ("glu" ,glu)
6527 ("libjpeg" ,libjpeg-turbo)
6528 ("libpng" ,libpng)
6529 ("openal" ,openal)
6530 ("vorbis" ,libvorbis)
6531 ("zlib" ,zlib)))
6532 (home-page "https://osslugaru.gitlab.io")
6533 (synopsis "Cross-platform third-person action game")
6534 (description "Lugaru is a third-person action game. The main character,
6535 Turner, is an anthropomorphic rebel bunny rabbit with impressive combat skills.
6536 In his quest to find those responsible for slaughtering his village, he uncovers
6537 a far-reaching conspiracy involving the corrupt leaders of the rabbit republic
6538 and the starving wolves from a nearby den. Turner takes it upon himself to
6539 fight against their plot and save his fellow rabbits from slavery.")
6540 (license (list license:gpl2+ ; code
6541 ;; assets:
6542 license:cc-by-sa3.0
6543 license:cc-by-sa4.0))))
6544
6545 (define-public 0ad-data
6546 (package
6547 (name "0ad-data")
6548 (version "0.0.25b-alpha")
6549 (source
6550 (origin
6551 (method url-fetch)
6552 (uri (string-append "https://releases.wildfiregames.com/0ad-"
6553 version "-unix-data.tar.xz"))
6554 (file-name (string-append name "-" version ".tar.xz"))
6555 (sha256
6556 (base32 "1c9zrddmjxvvacismld6fbwbw9vrdbq6g6d3424p8w5p6xg5wlwy"))))
6557 (build-system trivial-build-system)
6558 (native-inputs (list tar unzip xz))
6559 (arguments
6560 `(#:modules ((guix build utils))
6561 #:builder
6562 (begin
6563 (use-modules (guix build utils))
6564 (let ((out (assoc-ref %outputs "out"))
6565 (source (assoc-ref %build-inputs "source"))
6566 (tar (search-input-file %build-inputs "/bin/tar"))
6567 (unzip (search-input-file %build-inputs "/bin/unzip"))
6568 (xz-path (string-append (assoc-ref %build-inputs "xz") "/bin")))
6569 (setenv "PATH" xz-path)
6570 (mkdir out)
6571 (invoke tar "xvf" source "-C" out "--strip=3")
6572 (for-each (lambda (name)
6573 (let* ((dir (string-append out "/mods/" name))
6574 (file (string-append dir "/" name ".zip")))
6575 (invoke unzip "-o" "-d" dir file)
6576 (delete-file file)))
6577 '("mod" "public"))))))
6578 (synopsis "Data files for 0ad")
6579 (description "0ad-data provides the data files required by the game 0ad.")
6580 (home-page "https://play0ad.com")
6581 (license (list (license:fsdg-compatible
6582 "http://tavmjong.free.fr/FONTS/ArevCopyright.txt"
6583 "Similar to the license of the Bitstream Vera fonts.")
6584 (license:fsdg-compatible
6585 "https://www.gnome.org/fonts/#Final_Bitstream_Vera_Fonts")
6586 license:cc-by-sa3.0
6587 license:expat
6588 license:gfl1.0
6589 license:gpl2+
6590 license:gpl3+))))
6591
6592 (define-public 0ad
6593 (package
6594 (name "0ad")
6595 (version "0.0.25b-alpha")
6596 (source
6597 (origin
6598 (method url-fetch)
6599 (uri (string-append "https://releases.wildfiregames.com/0ad-"
6600 version "-unix-build.tar.xz"))
6601 (file-name (string-append name "-" version ".tar.xz"))
6602 (sha256
6603 (base32 "1p9fa8f7sjb9c5wl3mawzyfqvgr614kdkhrj2k4db9vkyisws3fp"))))
6604 ;; A snippet here would cause a build failure because of timestamps
6605 ;; reset. See https://bugs.gnu.org/26734.
6606 (inputs
6607 (list #{0ad-data}#
6608 curl
6609 enet
6610 fmt
6611 gloox
6612 icu4c-68
6613 libidn
6614 libpng
6615 libsodium
6616 libvorbis
6617 libxcursor
6618 libxml2
6619 miniupnpc
6620 mozjs-78
6621 openal
6622 sdl2
6623 wxwidgets
6624 zlib))
6625 (native-inputs
6626 `(("boost" ,boost)
6627 ("cmake" ,cmake-minimal)
6628 ("cxxtest" ,cxxtest)
6629 ("mesa" ,mesa)
6630 ("pkg-config" ,pkg-config)
6631 ("python-2" ,python-2)))
6632 (build-system gnu-build-system)
6633 (arguments
6634 `(#:make-flags '("config=release" "verbose=1" "-C" "build/workspaces/gcc")
6635 #:tests? #f ;tests fail currently
6636 #:phases
6637 (modify-phases %standard-phases
6638 (add-after 'unpack 'delete-bundles
6639 (lambda* (#:key inputs #:allow-other-keys)
6640 (delete-file-recursively "libraries/source/spidermonkey")
6641 (delete-file-recursively "libraries/source/cxxtest-4.4")
6642 (substitute* "build/premake/premake5.lua"
6643 (("rootdir\\.\\.\"\\/libraries\\/source\\/cxxtest-4.4\\/bin\\/cxxtestgen\"")
6644 (string-append "\"" (assoc-ref inputs "cxxtest")
6645 "/bin/cxxtestgen"
6646 "\"")))))
6647 (replace 'configure
6648 (lambda* (#:key inputs outputs tests? #:allow-other-keys)
6649 (let* ((jobs (number->string (parallel-job-count)))
6650 (out (assoc-ref outputs "out"))
6651 (lib (string-append out "/lib"))
6652 (data (string-append out "/share/0ad")))
6653 (setenv "JOBS" (string-append "-j" jobs))
6654 (setenv "CC" "gcc")
6655 (with-directory-excursion "build/workspaces"
6656 (apply invoke
6657 `("./update-workspaces.sh"
6658 ,(string-append "--libdir=" lib)
6659 ,(string-append "--datadir=" data)
6660 ;; TODO: "--with-system-nvtt"
6661 "--with-system-mozjs"
6662 ,@(if tests? '() '("--without-tests"))))))))
6663 (delete 'check)
6664 (replace 'install
6665 (lambda* (#:key inputs outputs #:allow-other-keys)
6666 (chdir "binaries")
6667 (let* ((out (assoc-ref outputs "out"))
6668 (bin (string-append out "/bin"))
6669 (lib (string-append out "/lib"))
6670 (data (string-append out "/share/0ad"))
6671 (applications (string-append out "/share/applications"))
6672 (hicolor (string-append out "/share/icons/hicolor/128x128/apps"))
6673 (metainfo (string-append out "/share/metainfo"))
6674 (mime (string-append out "/share/mime/application"))
6675 (0ad-data (assoc-ref inputs "0ad-data")))
6676 ;; data
6677 (copy-recursively "data" data)
6678 (for-each (lambda (file)
6679 (symlink (string-append 0ad-data "/" file)
6680 (string-append data "/" file)))
6681 '("config" "mods/mod" "mods/public" "tools"))
6682 ;; libraries
6683 (for-each (lambda (file)
6684 (install-file file lib))
6685 (find-files "system" "\\.so$"))
6686 ;; binaries
6687 (install-file "system/pyrogenesis" bin)
6688 (with-directory-excursion bin
6689 (symlink "pyrogenesis" "0ad"))
6690 ;; resources
6691 (with-directory-excursion "../build/resources"
6692 (install-file "0ad.desktop" applications)
6693 (install-file "0ad.png" hicolor)
6694 (install-file "0ad.appdata.xml" metainfo)
6695 (install-file "pyrogenesis.xml" mime)))))
6696 (add-after 'install 'check
6697 (lambda* (#:key tests? #:allow-other-keys)
6698 (when tests?
6699 (with-directory-excursion "system"
6700 (invoke "./test"))))))))
6701 (home-page "https://play0ad.com")
6702 (synopsis "3D real-time strategy game of ancient warfare")
6703 (description "0 A.D. is a real-time strategy (RTS) game of ancient
6704 warfare. It's a historically-based war/economy game that allows players to
6705 relive or rewrite the history of twelve ancient civilizations, each depicted
6706 at their peak of economic growth and military prowess.
6707
6708 0ad needs a window manager that supports 'Extended Window Manager Hints'.")
6709 (license (list license:bsd-2
6710 license:bsd-3
6711 license:expat
6712 license:gpl2+
6713 license:ibmpl1.0
6714 license:isc
6715 license:lgpl2.1
6716 license:lgpl3
6717 license:mpl2.0
6718 license:zlib))))
6719
6720 (define-public open-adventure
6721 (package
6722 (name "open-adventure")
6723 (version "1.9")
6724 (source
6725 (origin
6726 (method git-fetch)
6727 (uri (git-reference
6728 (url "https://gitlab.com/esr/open-adventure")
6729 (commit version)))
6730 (file-name (git-file-name name version))
6731 (sha256
6732 (base32 "123svzy7xczdklx6plbafp22yv9bcvwfibjk0jv2c9i22dfsr07f"))))
6733 (build-system gnu-build-system)
6734 (arguments
6735 `(#:make-flags (list "CC=gcc")
6736 #:phases
6737 (modify-phases %standard-phases
6738 (delete 'configure) ;no configure script
6739 (add-before 'build 'use-echo
6740 (lambda _
6741 (substitute* "tests/Makefile"
6742 (("/bin/echo") (which "echo")))
6743 #t))
6744 (add-after 'build 'build-manpage
6745 (lambda _
6746 ;; This target is missing a dependency
6747 (substitute* "Makefile"
6748 ((".adoc.6:" line)
6749 (string-append line " advent.adoc")))
6750 (invoke "make" ".adoc.6")))
6751 ;; There is no install target.
6752 (replace 'install
6753 (lambda* (#:key outputs #:allow-other-keys)
6754 (let* ((out (assoc-ref outputs "out"))
6755 (bin (string-append out "/bin"))
6756 (man (string-append out "/share/man/man6")))
6757 (install-file "advent" bin)
6758 (install-file "advent.6" man))
6759 #t)))))
6760 (native-inputs
6761 `(("asciidoc" ,asciidoc)
6762 ("libedit" ,libedit)
6763 ("pkg-config" ,pkg-config)
6764 ("python" ,python-wrapper)
6765 ("python-pyyaml" ,python-pyyaml)))
6766 (home-page "https://gitlab.com/esr/open-adventure")
6767 (synopsis "Colossal Cave Adventure")
6768 (description
6769 "The original Colossal Cave Adventure from 1976 was the origin of all
6770 text adventures, dungeon-crawl (computer) games, and computer-hosted
6771 roleplaying games. This is a forward port of the last version released by
6772 Crowther & Woods, its original authors, in 1995. It has been known as
6773 ``adventure 2.5'' and ``430-point adventure''.")
6774 (license license:bsd-2)))
6775
6776 (define-public open-adventure-2.5
6777 (package
6778 (inherit open-adventure)
6779 (version "2.5")
6780 (properties `((superseded . ,open-adventure)))))
6781
6782 (define-public tome4
6783 (package
6784 (name "tome4")
6785 (version "1.7.4")
6786 (synopsis "Single-player, RPG roguelike game set in the world of Eyal")
6787 (source
6788 (origin
6789 (method url-fetch)
6790 (uri (string-append "https://te4.org/dl/t-engine/t-engine4-src-"
6791 version ".tar.bz2"))
6792 (sha256
6793 (base32 "197jmd99l3w3sig32pvdlq9fcgdjjx7g9csy08kz174cyhrlyly3"))
6794 (modules '((guix build utils)))
6795 (snippet
6796 '(begin
6797 (substitute* '("src/music.h" "src/tSDL.h")
6798 (("#elif defined(__FreeBSD__)" line)
6799 (string-append
6800 line " || defined(__GNUC__)")))
6801 (substitute* '("src/tgl.h")
6802 (("#include <GL/glext.h>") ""))))))
6803 (build-system gnu-build-system)
6804 (native-inputs
6805 (list unzip))
6806 (inputs
6807 `(("sdl-union" ,(sdl-union (list sdl2 sdl2-image sdl2-mixer sdl2-ttf)))
6808 ("glu" ,glu)
6809 ("premake4" ,premake4)
6810 ("openal" ,openal)
6811 ("vorbis" ,libvorbis)
6812 ("luajit" ,luajit)))
6813 (arguments
6814 `(#:make-flags
6815 (list (string-append "CC=" ,(cc-for-target))
6816 "config=release")
6817 ;; XXX: Building in parallel occasionally causes this build failure:
6818 ;; ../src/luajit2/src/host/buildvm.c:73:10: fatal error: buildvm_arch.h:
6819 ;; No such file or directory
6820 #:parallel-build? #f
6821 #:phases (modify-phases %standard-phases
6822 (delete 'bootstrap)
6823 (replace 'configure
6824 (lambda _
6825 (invoke "premake4" "gmake")))
6826 (add-after 'set-paths 'set-sdl-paths
6827 (lambda* (#:key inputs #:allow-other-keys)
6828 (setenv "CPATH"
6829 (string-append
6830 (search-input-directory inputs "/include/SDL2")
6831 ":" (or (getenv "CPATH") "")))))
6832 (delete 'check)
6833 ;; premake doesn't provide install target
6834 (replace 'install
6835 (lambda* (#:key inputs outputs #:allow-other-keys)
6836 (let* ((out (assoc-ref outputs "out"))
6837 (usr (string-append out "/usr"))
6838 (bin (string-append out "/bin"))
6839 (licenses (string-append out "/share/licenses"))
6840 (documents (string-append out "/share/doc"))
6841 (pixmaps (string-append out "/share/pixmaps"))
6842 (icon "te4-icon.png")
6843 (data (string-append out "/share/" ,name))
6844 (applications (string-append
6845 out "/share/applications"))
6846 (unzip (string-append
6847 (assoc-ref inputs "unzip") "/bin/unzip"))
6848 (wrapper (string-append bin "/" ,name)))
6849 ;; icon
6850 (mkdir-p pixmaps)
6851 (invoke unzip "-j"
6852 (string-append
6853 "game/engines/te4-" ,version ".teae")
6854 (string-append
6855 "data/gfx/" icon) "-d" pixmaps)
6856 ;; game executable
6857 (install-file "t-engine" data)
6858 (mkdir-p bin)
6859 (with-output-to-file wrapper
6860 (lambda ()
6861 (display
6862 (string-append
6863 "#!/bin/sh\n"
6864 ;; No bootstrap code found,
6865 ;; defaulting to working directory
6866 ;; for engine code!
6867 "cd " data "\n"
6868 "exec -a tome4 ./t-engine \"$@\"\n"))))
6869 (chmod wrapper #o555)
6870 ;; licenses
6871 (for-each (lambda (file)
6872 (install-file file licenses))
6873 '("COPYING" "COPYING-MEDIA"))
6874 ;; documents
6875 (for-each (lambda (file)
6876 (install-file file documents))
6877 '("CONTRIBUTING" "CREDITS"))
6878 ;; data
6879 (copy-recursively "bootstrap" (string-append
6880 data "/bootstrap"))
6881 (copy-recursively "game" (string-append data "/game"))
6882 ;; launcher
6883 (mkdir-p applications)
6884 (make-desktop-entry-file
6885 (string-append applications "/" ,name ".desktop")
6886 #:name "ToME4"
6887 #:comment ,synopsis
6888 #:exec ,name
6889 #:icon icon
6890 #:categories '("Game" "RolePlaying"))))))))
6891 (home-page "https://te4.org")
6892 (description "Tales of Maj’Eyal (ToME) RPG, featuring tactical turn-based
6893 combat and advanced character building. Play as one of many unique races and
6894 classes in the lore-filled world of Eyal, exploring random dungeons, facing
6895 challenging battles, and developing characters with your own tailored mix of
6896 abilities and powers. With a modern graphical and customisable interface,
6897 intuitive mouse control, streamlined mechanics and deep, challenging combat,
6898 Tales of Maj’Eyal offers engaging roguelike gameplay for the 21st century.")
6899 (license license:gpl3+)))
6900
6901 (define-public quakespasm
6902 (package
6903 (name "quakespasm")
6904 (version "0.93.2")
6905 (source
6906 (origin
6907 (method url-fetch)
6908 (uri (string-append "mirror://sourceforge/quakespasm/Source/quakespasm-"
6909 version ".tgz"))
6910 (sha256
6911 (base32 "0qm0j5drybvvq8xadfyppkpk3rxqsxbywzm6iwsjwdf0iia3gss5"))))
6912 (arguments
6913 `(#:tests? #f
6914 #:make-flags '("CC=gcc"
6915 "MP3LIB=mpg123"
6916 "USE_CODEC_FLAC=1"
6917 "USE_CODEC_MIKMOD=1"
6918 "USE_SDL2=1"
6919 "-CQuake")
6920 #:phases (modify-phases %standard-phases
6921 (delete 'configure)
6922 (add-after 'unpack 'fix-makefile-paths
6923 (lambda* (#:key outputs #:allow-other-keys)
6924 (let ((out (assoc-ref outputs "out")))
6925 (mkdir-p (string-append out "/bin"))
6926 (substitute* "Quake/Makefile"
6927 (("/usr/local/games")
6928 (string-append out "/bin")))
6929 #t))))))
6930 (build-system gnu-build-system)
6931 (inputs (list libmikmod
6932 libvorbis
6933 flac
6934 mesa
6935 mpg123
6936 sdl2))
6937 (synopsis "First person shooter engine for Quake 1")
6938 (description "Quakespasm is a modern engine for id software's Quake 1.
6939 It includes support for 64 bit CPUs, custom music playback, a new sound driver,
6940 some graphical niceities, and numerous bug-fixes and other improvements.")
6941 (home-page "http://quakespasm.sourceforge.net/")
6942 (license license:gpl2+)))
6943
6944 (define-public vkquake
6945 (package
6946 (inherit quakespasm)
6947 (name "vkquake")
6948 (version "1.01.0")
6949 (source
6950 (origin
6951 (method git-fetch)
6952 (uri (git-reference
6953 (url "https://github.com/Novum/vkQuake")
6954 (commit version)))
6955 (file-name (git-file-name name version))
6956 (sha256
6957 (base32 "1iwin8j5kbyrknbkhjgpy8nmm7pxqzr0daa9gn7p38qhg2mh0a39"))))
6958 (arguments
6959 `(#:make-flags
6960 (let ((vulkanlib (string-append (assoc-ref %build-inputs
6961 "vulkan-loader") "/lib")))
6962 (list "CC=gcc"
6963 "MP3LIB=mpg123"
6964 "USE_CODEC_FLAC=1"
6965 "USE_CODEC_MIKMOD=1"
6966 "USE_SDL2=1"
6967 (string-append "LDFLAGS=-Wl,-rpath=" vulkanlib)
6968 "-CQuake"))
6969 #:phases (modify-phases %standard-phases
6970 (add-after 'unpack 'patch-for-new-vulkan
6971 (lambda _
6972 ;; Mimic upstream commit a869a22d9b51c68e for
6973 ;; compatibility with newer vulkan-headers.
6974 (substitute* "Quake/gl_rmisc.c"
6975 (("VK_DYNAMIC_STATE_RANGE_SIZE")
6976 "3"))
6977 #t))
6978 (delete 'configure)
6979 (add-after 'unpack 'fix-makefile-paths
6980 (lambda* (#:key outputs #:allow-other-keys)
6981 (let ((vulkan (assoc-ref %build-inputs
6982 "vulkan-loader"))
6983 (out (assoc-ref outputs "out")))
6984 (mkdir-p (string-append out "/bin"))
6985 (substitute* "Quake/Makefile" ((" /usr")
6986 (string-append " " out)))
6987 (substitute* "Quake/Makefile" (("/games")
6988 (string-append "/bin")))
6989 (substitute* "Quake/Makefile" (("..VULKAN_SDK.") vulkan))
6990 #t))))
6991 ,@(strip-keyword-arguments '(#:make-flags #:phases)
6992 (package-arguments quakespasm))))
6993 (inputs (modify-inputs (package-inputs quakespasm)
6994 (prepend vulkan-headers vulkan-loader)))
6995 (description "vkquake is a modern engine for id software's Quake 1.
6996 It includes support for 64 bit CPUs, custom music playback, a new sound driver,
6997 some graphical niceities, and numerous bug-fixes and other improvements.")
6998 (home-page "https://github.com/Novum/vkQuake")))
6999
7000 (define-public yamagi-quake2
7001 (package
7002 (name "yamagi-quake2")
7003 (version "7.45")
7004 (source
7005 (origin
7006 (method url-fetch)
7007 (uri (string-append "https://deponie.yamagi.org/quake2/quake2-"
7008 version ".tar.xz"))
7009 (sha256
7010 (base32 "0rgz8x7lzd0zb0xqd0gvnf2641nr9xpfm6v14mgh99hspxklaln7"))))
7011 (build-system gnu-build-system)
7012 (arguments
7013 `(#:tests? #f
7014 #:make-flags
7015 (list "CC=gcc"
7016 ;; An optional directory where it will look for quake2 data files
7017 ;; in addition to the current working directory.
7018 "WITH_SYSTEMWIDE=yes"
7019 "WITH_SYSTEMDIR=\"/opt/quake2\"")
7020 #:phases
7021 (modify-phases %standard-phases
7022 (delete 'configure)
7023 (add-before 'build 'patch-libraries
7024 (lambda* (#:key inputs #:allow-other-keys)
7025 ;; The game writes paths to openal.so and curl.so to ~/.yq2/...
7026 ;; Workaround: hard-code the compiled paths where it loads them;
7027 ;; this prevents loading old or garbage collected libraries.
7028 (substitute* "src/client/sound/qal.c"
7029 (("al_driver->string")
7030 (string-append "\"" (assoc-ref inputs "openal")
7031 "/lib/libopenal.so\"")))
7032 (substitute* "src/client/curl/qcurl.c"
7033 (("cl_libcurl->string")
7034 (string-append "\"" (assoc-ref inputs "curl")
7035 "/lib/libcurl.so\"")))))
7036 (replace 'install
7037 (lambda* (#:key outputs #:allow-other-keys)
7038 (let ((out (assoc-ref outputs "out")))
7039 (mkdir-p (string-append out "/lib"))
7040 (mkdir-p (string-append out "/bin"))
7041 ;; The yamagi-quake2 binary must be in the same directory
7042 ;; as its engine libraries, but symlinking it to /bin is okay.
7043 ;; https://github.com/yquake2/yquake2/blob/master/stuff/packaging.md
7044 (copy-recursively "release"
7045 (string-append out "/lib/yamagi-quake2"))
7046 (symlink (string-append out "/lib/yamagi-quake2/quake2")
7047 (string-append out "/bin/yamagi-quake2"))
7048 (symlink (string-append out "/lib/yamagi-quake2/q2ded")
7049 (string-append out "/bin/yamagi-q2ded"))))))))
7050 (native-inputs
7051 (list pkg-config))
7052 (inputs
7053 (list curl
7054 libvorbis
7055 mesa
7056 openal
7057 sdl2
7058 zlib))
7059 (synopsis "First person shooter engine based on quake2")
7060 (description "Yamagi Quake II is an enhanced client for id Software's Quake II.
7061 The main focus is an unchanged single player experience like back in 1997,
7062 thus the gameplay and the graphics are unaltered. However the user may use one
7063 of the unofficial retexturing packs. In comparison with the official client,
7064 over 1000 bugs were fixed and an extensive code audit done,
7065 making Yamagi Quake II one of the most solid Quake II implementations available.")
7066 (home-page "https://www.yamagi.org/quake2/")
7067 (license (list license:gpl2+ ; game and server
7068 (license:non-copyleft ; info-zip
7069 "file://LICENSE"
7070 "See Info-Zip section.")
7071 license:public-domain)))) ; stb
7072
7073 (define-public nudoku
7074 (package
7075 (name "nudoku")
7076 (version "2.1.0")
7077 (source
7078 (origin
7079 (method git-fetch)
7080 (uri (git-reference
7081 (url "https://github.com/jubalh/nudoku")
7082 (commit version)))
7083 (file-name (git-file-name name version))
7084 (sha256
7085 (base32 "12v00z3p0ymi8f3w4b4bgl4c76irawn3kmd147r0ap6s9ssx2q6m"))))
7086 (build-system gnu-build-system)
7087 (native-inputs
7088 (list autoconf automake gettext-minimal pkg-config))
7089 (inputs
7090 (list ncurses))
7091 (home-page "https://jubalh.github.io/nudoku/")
7092 (synopsis "Sudoku for your terminal")
7093 (description "Nudoku is a ncurses-based Sudoku game for your terminal.")
7094 (license license:gpl3+)))
7095
7096 (define-public the-butterfly-effect
7097 (package
7098 (name "the-butterfly-effect")
7099 (version "0.9.3.1")
7100 (source
7101 (origin
7102 (method git-fetch)
7103 (uri (git-reference
7104 (url "https://github.com/the-butterfly-effect/tbe")
7105 (commit (string-append "v" version))))
7106 (file-name (git-file-name name version))
7107 (sha256
7108 (base32
7109 "1ag2cp346f9bz9qy6za6q54id44d2ypvkyhvnjha14qzzapwaysj"))))
7110 (build-system gnu-build-system)
7111 (arguments
7112 `(#:phases
7113 (modify-phases %standard-phases
7114 (delete 'configure)
7115 ;; There is no "install" phase. By default, tbe is installed
7116 ;; in the build directory. Provide our own installation.
7117 (replace 'install
7118 (lambda* (#:key outputs #:allow-other-keys)
7119 (let* ((out (assoc-ref outputs "out"))
7120 (bin (string-append out "/bin"))
7121 (share (string-append out "/share")))
7122 (install-file "usr/games/tbe" bin)
7123 (mkdir-p share)
7124 (copy-recursively "usr/share" share)
7125 #t))))
7126 ;; Test suite requires a running Xorg server. Even when
7127 ;; provided, it fails with "D-Bus library appears to be
7128 ;; incorrectly set up; failed to read machine uuid: Failed to
7129 ;; open "/etc/machine-id": No such file or directory" along
7130 ;; with multiple "QPainter:: ... Painter not active" warnings.
7131 #:tests? #f))
7132 (inputs
7133 (list qtbase-5 qtsvg))
7134 (native-inputs
7135 `(("cmake" ,cmake-minimal)
7136 ("gettext-minimal" ,gettext-minimal)
7137 ("qttools" ,qttools)))
7138 (synopsis "Realistic physics puzzle game")
7139 (description "The Butterfly Effect (tbe) is a game that uses
7140 realistic physics simulations to combine lots of simple mechanical
7141 elements to achieve a simple goal in the most complex way possible.")
7142 (home-page "http://the-butterfly-effect.org/")
7143 ;; Main license is GPL2-only. However, artwork is distributed
7144 ;; under various licenses, listed here.
7145 (license (list license:gpl2 license:public-domain license:expat
7146 license:cc-by-sa3.0 license:gpl3+ license:wtfpl2))))
7147
7148 (define-public pioneer
7149 (package
7150 (name "pioneer")
7151 (version "20210723")
7152 (source (origin
7153 (method git-fetch)
7154 (uri (git-reference
7155 (url "https://github.com/pioneerspacesim/pioneer")
7156 (commit version)))
7157 (file-name (git-file-name name version))
7158 (sha256
7159 (base32
7160 "1hj99jxb9n3r0bkq87p1c24862xa1xyzjyfdyyx88ckszxb05qf3"))))
7161 (build-system cmake-build-system)
7162 (native-inputs
7163 (list pkg-config))
7164 (inputs
7165 `(("assimp" ,assimp)
7166 ("curl" ,curl)
7167 ("freetype" ,freetype)
7168 ("glew" ,glew)
7169 ("glu" ,glu)
7170 ("libpng" ,libpng)
7171 ("libsigc++" ,libsigc++)
7172 ("libvorbis" ,libvorbis)
7173 ("lua" ,lua-5.2) ;not compatible with 5.3
7174 ("mesa" ,mesa)
7175 ("sdl" ,(sdl-union (list sdl2 sdl2-image)))))
7176 (arguments
7177 `(#:tests? #f ;tests are broken
7178 #:configure-flags (list "-DUSE_SYSTEM_LIBLUA:BOOL=YES"
7179 (string-append "-DPIONEER_DATA_DIR="
7180 %output "/share/games/pioneer"))
7181 #:make-flags (list "all" "build-data")))
7182 (home-page "https://pioneerspacesim.net")
7183 (synopsis "Game of lonely space adventure")
7184 (description
7185 "Pioneer is a space adventure game set in our galaxy at the turn of the
7186 31st century. The game is open-ended, and you are free to eke out whatever
7187 kind of space-faring existence you can think of. Look for fame or fortune by
7188 exploring the millions of star systems. Turn to a life of crime as a pirate,
7189 smuggler or bounty hunter. Forge and break alliances with the various
7190 factions fighting for power, freedom or self-determination. The universe is
7191 whatever you make of it.")
7192 (license license:gpl3)))
7193
7194 (define-public badass
7195 (let ((commit "3c3cd669b4fc8f73a102e3702788f7b28dc47dbb")
7196 (revision "0"))
7197 (package
7198 (name "badass")
7199 (version (git-version "0.0" revision commit))
7200 (source (origin
7201 (method git-fetch)
7202 (uri (git-reference
7203 (url "https://github.com/umayr/badass")
7204 (commit commit)))
7205 (file-name (git-file-name name version))
7206 (sha256
7207 (base32
7208 "05c9vdcb5ym3z0n5ll3v39mw4yl9jcjnlydmn0yl89ai9pv71zb6"))))
7209 (build-system go-build-system)
7210 (arguments
7211 '(#:import-path "github.com/umayr/badass"))
7212 (synopsis "Hacking contribution graphs in git")
7213 (description
7214 "Badass generates false commits for a range of dates, essentially
7215 hacking the gamification of contribution graphs on platforms such as
7216 Github or Gitlab.")
7217 (home-page "https://github.com/umayr/badass")
7218 (license license:expat))))
7219
7220 (define-public colobot
7221 (package
7222 (name "colobot")
7223 (version "0.2.0-alpha")
7224 (source
7225 (origin
7226 (method git-fetch)
7227 (uri (git-reference
7228 (url "https://github.com/colobot/colobot")
7229 (commit (string-append "colobot-gold-" version))
7230 (recursive? #t))) ;for "data/" subdir
7231 (file-name (git-file-name name version))
7232 (sha256
7233 (base32 "02z21pw47j2afjsikn5b162gacwgiahdrlhmfxhq4xqlzsvz58z6"))))
7234 (build-system cmake-build-system)
7235 (arguments
7236 `(#:tests? #f ;no test
7237 #:phases
7238 (modify-phases %standard-phases
7239 (add-after 'unpack 'make-git-checkout-writable
7240 (lambda _
7241 (for-each make-file-writable (find-files "."))
7242 #t))
7243 (add-after 'unpack 'fix-directories
7244 (lambda _
7245 (substitute* "CMakeLists.txt"
7246 (("(\\$\\{CMAKE_INSTALL_PREFIX\\})/games" _ prefix)
7247 (string-append prefix "/bin"))
7248 (("(\\$\\{CMAKE_INSTALL_PREFIX\\}/share)/games/colobot" _ prefix)
7249 (string-append prefix "/colobot")))
7250 #t))
7251 (add-after 'fix-directories 'install-music
7252 ;; Retrieve and install music files.
7253 (lambda* (#:key inputs #:allow-other-keys)
7254 ;; Installation process tries to download music files using
7255 ;; "wget" if not already present. Since we are going another
7256 ;; route, skip "wget" command check.
7257 (substitute* "data/music/CMakeLists.txt"
7258 (("find_program\\(WGET wget\\)") ""))
7259 ;; Populate "music/" directory.
7260 (let ((data (assoc-ref inputs "colobot-music")))
7261 (invoke "tar" "-xvf" data "-Cdata/music"))
7262 #t)))))
7263 (native-inputs
7264 `(("colobot-music"
7265 ,(origin
7266 (method url-fetch)
7267 (uri (string-append "https://colobot.info/files/music/"
7268 "colobot-music_ogg_" version ".tar.gz"))
7269 (sha256
7270 (base32
7271 "1s86cd36rwkff329mb1ay1wi5qqyi35564ppgr3f4qqz9wj9vs2m"))))
7272 ("gettext" ,gettext-minimal)
7273 ("librsvg" ,librsvg)
7274 ("po4a" ,po4a)
7275 ("python" ,python-wrapper)))
7276 (inputs
7277 `(("boost" ,boost)
7278 ("glew" ,glew)
7279 ("libogg" ,libogg)
7280 ("libpng" ,libpng)
7281 ("libsndfile" ,libsndfile)
7282 ("libvorbis" ,libvorbis)
7283 ("openal" ,openal)
7284 ("physfs" ,physfs)
7285 ("sdl" ,(sdl-union (list sdl2 sdl2-image sdl2-ttf)))))
7286 (synopsis "Educational programming strategy game")
7287 (description "Colobot: Gold Edition is a real-time strategy game, where
7288 you can program your units (bots) in a language called CBOT, which is similar
7289 to C++ and Java. Your mission is to find a new planet to live and survive.
7290 You can save humanity and get programming skills!")
7291 (home-page "https://colobot.info")
7292 (license license:gpl3+)))
7293
7294 (define-public gzdoom
7295 (package
7296 (name "gzdoom")
7297 (version "4.3.2")
7298 (source
7299 (origin
7300 (method git-fetch)
7301 (uri (git-reference
7302 (url "https://github.com/coelckers/gzdoom")
7303 (commit (string-append "g" version))))
7304 (file-name (git-file-name name version))
7305 (sha256
7306 (base32 "0i4hyg72z84fc6ca2ic9q82q5cbgrbd7bynl3kpkypxvyasq08wz"))
7307 (patches (search-patches "gzdoom-search-in-installed-share.patch"
7308 "gzdoom-find-system-libgme.patch"))
7309 (modules '((guix build utils)))
7310 (snippet
7311 '(begin
7312 ;; Remove some bundled libraries. XXX There are more, but removing
7313 ;; them would require, at least, patching the build system.
7314 (with-directory-excursion "libraries"
7315 (delete-file-recursively "bzip2")
7316 (delete-file-recursively "game-music-emu")
7317 (delete-file-recursively "jpeg")
7318 (delete-file-recursively "zlib"))
7319 #t))))
7320 (arguments
7321 '(#:tests? #f
7322 #:configure-flags
7323 (let ((out (assoc-ref %outputs "out")))
7324 (list
7325 (string-append
7326 "-DCMAKE_CXX_FLAGS:="
7327 "-DSHARE_DIR=\\\"" out "/share/\\\" "
7328 "-DGUIX_OUT_PK3=\\\"" out "/share/games/doom\\\"")
7329
7330 ;; The build requires some extra convincing not to use the bundled
7331 ;; libgme previously deleted in the soure snippet.
7332 "-DFORCE_INTERNAL_GME=OFF"
7333
7334 ;; Link libraries at build time instead of loading them at run time.
7335 "-DDYN_OPENAL=OFF"
7336 "-DDYN_FLUIDSYNTH=OFF"
7337 "-DDYN_GTK=OFF"
7338 "-DDYN_MPG123=OFF"
7339 "-DDYN_SNDFILE=OFF"))
7340 #:phases
7341 (modify-phases %standard-phases
7342 (add-before 'configure 'fix-referenced-paths
7343 (lambda* (#:key inputs outputs #:allow-other-keys)
7344 (let ((fluid-3 (assoc-ref inputs "fluid-3"))
7345 (timidity++ (assoc-ref inputs "timidity++"))
7346 (out (assoc-ref outputs "out")))
7347
7348 (substitute*
7349 "src/CMakeLists.txt"
7350 (("COMMAND /bin/sh")
7351 (string-append "COMMAND " (which "sh"))))
7352
7353 (substitute*
7354 "libraries/zmusic/mididevices/music_fluidsynth_mididevice.cpp"
7355 (("/usr/share/sounds/sf2/FluidR3_GM.sf2")
7356 (string-append fluid-3 "/share/soundfonts/FluidR3Mono_GM.sf3")))
7357
7358 (substitute*
7359 "libraries/zmusic/mididevices/music_timiditypp_mididevice.cpp"
7360 (("exename = \"timidity\"")
7361 (string-append "exename = \"" timidity++ "/bin/timidity\"")))
7362 #t))))))
7363 (build-system cmake-build-system)
7364 (inputs `(("bzip2" ,bzip2)
7365 ("fluid-3" ,fluid-3)
7366 ("fluidsynth" ,fluidsynth)
7367 ("gtk+3" ,gtk+)
7368 ("libgme" ,libgme)
7369 ("libjpeg" ,libjpeg-turbo)
7370 ("libsndfile" ,libsndfile)
7371 ("mesa" ,mesa)
7372 ("mpg123" ,mpg123)
7373 ("openal" ,openal)
7374 ("sdl2" ,sdl2)
7375 ("timidity++" ,timidity++)
7376 ("zlib" ,zlib)))
7377 (native-inputs (list pkg-config unzip))
7378 (synopsis "Modern Doom 2 source port")
7379 (description "GZdoom is a port of the Doom 2 game engine, with a modern
7380 renderer. It improves modding support with ZDoom's advanced mapping features
7381 and the new ZScript language. In addition to Doom, it supports Heretic, Hexen,
7382 Strife, Chex Quest, and fan-created games like Harmony, Hacx and Freedoom.")
7383 (home-page "https://zdoom.org/index")
7384 ;; The source uses x86 assembly
7385 (supported-systems '("x86_64-linux" "i686-linux"))
7386 (license (list license:gpl3+ ; gzdoom game
7387 license:lgpl3+ ; gzdoom renderer
7388 license:expat ; gdtoa
7389 (license:non-copyleft ; modified dumb
7390 "file://dumb/licence.txt"
7391 "Dumb license, explicitly GPL compatible.")))))
7392
7393 (define-public odamex
7394 (package
7395 (name "odamex")
7396 (version "0.9.5")
7397 (source
7398 (origin
7399 (method url-fetch)
7400 (uri (string-append
7401 "mirror://sourceforge/odamex/Odamex/" version "/"
7402 "odamex-src-" version ".tar.bz2"))
7403 (sha256
7404 (base32 "1x0c9vnwn336inkfamh4na8xjyfjmzfxfn49j4snqymkypjqw6jq"))))
7405 (build-system cmake-build-system)
7406 (arguments `(#:tests? #f)) ; no tests
7407 (native-inputs
7408 (list deutex))
7409 (inputs
7410 `(("sdl" ,sdl2)
7411 ("sdl-mixer" ,sdl2-mixer)
7412 ("zlib" ,zlib)
7413 ("libpng" ,libpng)
7414 ("curl" ,curl-minimal)
7415 ("alsa-lib" ,alsa-lib)))
7416 (home-page "https://odamex.net/")
7417 (synopsis "Multiplayer Doom port")
7418 (description "Odamex is a modification of the Doom engine that
7419 allows players to easily join servers dedicated to playing Doom
7420 online.")
7421 (license license:gpl2+)))
7422
7423 (define-public chocolate-doom
7424 (package
7425 (name "chocolate-doom")
7426 (version "3.0.1")
7427 (source (origin
7428 (method url-fetch)
7429 (uri (string-append "https://www.chocolate-doom.org/downloads/"
7430 version
7431 "/chocolate-doom-"
7432 version
7433 ".tar.gz"))
7434 (sha256
7435 (base32
7436 "1iy8rx7kjvi1zjiw4zh77szzmd1sgpqajvbhprh1sj93fhbxcdfl"))))
7437 (build-system gnu-build-system)
7438 (arguments
7439 `(#:configure-flags (list "CFLAGS=-fcommon")))
7440 (inputs (list sdl2-net sdl2-mixer sdl2))
7441 (native-inputs
7442 (list pkg-config))
7443 (synopsis "Doom source port preserving the look, feel, and bugs of vanilla
7444 Doom")
7445 (description
7446 "Chocolate Doom takes a different approach to other source ports. Its
7447 aim is to accurately reproduce the experience of playing Vanilla Doom. It is
7448 a conservative, historically accurate Doom source port, which is compatible
7449 with the thousands of mods and levels that were made before the Doom source
7450 code was released. Rather than flashy new graphics, Chocolate Doom's main
7451 features are its accurate reproduction of the game as it was played in the
7452 1990s. The project is developed around a carefully-considered philosophy that
7453 intentionally restricts which features may be added (and rejects any that
7454 affect gameplay).")
7455 (home-page "https://www.chocolate-doom.org/wiki/index.php/Chocolate_Doom")
7456 (license license:gpl2)))
7457
7458 (define-public crispy-doom
7459 (package
7460 (inherit chocolate-doom)
7461 (name "crispy-doom")
7462 (version "5.8.0")
7463 (source (origin
7464 (method git-fetch)
7465 (uri (git-reference
7466 (url "https://github.com/fabiangreffrath/crispy-doom")
7467 (commit (string-append "crispy-doom-" version))))
7468 (file-name (git-file-name name version))
7469 (sha256
7470 (base32 "1b6gn0dysv631jynh769whww9xcss1gms78sz3nrn855q1dsvcb4"))))
7471 (native-inputs
7472 (append
7473 (package-native-inputs chocolate-doom)
7474 `(("automake" ,automake)
7475 ("autoreconf" ,autoconf))))
7476 (arguments
7477 `(#:configure-flags '("CFLAGS=-fcommon")
7478 #:phases
7479 (modify-phases %standard-phases
7480 (replace 'bootstrap
7481 ;; The bundled autogen.sh script unconditionally runs ./configure.
7482 (lambda _ (invoke "autoreconf" "-vif"))))))
7483 (synopsis "Limit-removing enhanced-resolution Doom source port based on
7484 Chocolate Doom")
7485 (description
7486 "Crispy Doom is a friendly fork of Chocolate Doom that provides a higher
7487 display resolution, removes the static limits of the Doom engine and offers
7488 further optional visual, tactical and physical enhancements while remaining
7489 entirely config file, savegame, netplay and demo compatible with the
7490 original.")
7491 (home-page "https://www.chocolate-doom.org/wiki/index.php/Crispy_Doom")))
7492
7493 (define shlomif-cmake-modules
7494 (origin
7495 (method url-fetch)
7496 (uri (string-append "https://bitbucket.org/shlomif/shlomif-cmake-modules/"
7497 "raw/c505713d7a7cda608f97f01577e5868a711b883e/"
7498 "shlomif-cmake-modules/Shlomif_Common.cmake"))
7499 (sha256
7500 (base32 "0kx9s1qqhhzprp1w3b67xmsns0n0v506bg5hgrshxaxpy6lqiwb2"))))
7501
7502 (define-public rinutils
7503 (package
7504 (name "rinutils")
7505 (version "0.2.0")
7506 (source (origin
7507 (method git-fetch)
7508 (uri (git-reference
7509 (url "https://github.com/shlomif/rinutils")
7510 (commit version)))
7511 (file-name (git-file-name name version))
7512 (sha256
7513 (base32
7514 "1fpxyg86ggv0h7j8aarjjxrvwlj7jycd3bw066c0dwkq2fszxsf2"))))
7515 (native-inputs
7516 `(("perl" ,perl)
7517 ;; The following is only needed for tests.
7518 ("perl-file-find-object" ,perl-file-find-object)
7519 ("perl-test-differences" ,perl-test-differences)
7520 ("perl-class-xsaccessor" ,perl-class-xsaccessor)
7521 ("perl-io-all" ,perl-io-all)
7522 ("perl-test-runvalgrind" ,perl-test-runvalgrind)
7523 ("cmake-rules" ,shlomif-cmake-modules)
7524 ("pkg-config" ,pkg-config)))
7525 (inputs
7526 (list cmocka
7527 perl-env-path
7528 perl-inline
7529 perl-inline-c
7530 perl-string-shellquote
7531 perl-test-trailingspace
7532 perl-file-find-object-rule
7533 perl-text-glob
7534 perl-number-compare
7535 perl-moo))
7536 (arguments
7537 `(#:phases
7538 (modify-phases %standard-phases
7539 (add-after 'unpack 'fix-build-env
7540 (lambda* (#:key inputs #:allow-other-keys)
7541 (use-modules (guix build utils))
7542 (let* ((cmake-rules (assoc-ref inputs "cmake-rules")))
7543 (copy-file cmake-rules
7544 (string-append "cmake/"
7545 (strip-store-file-name cmake-rules)))
7546 #t)))
7547 (replace 'check
7548 (lambda _
7549 (with-directory-excursion "../source"
7550 (setenv "FCS_TEST_BUILD" "1")
7551 (setenv "RINUTILS_TEST_BUILD" "1")
7552 ;; TODO: Run tests after setting RINUTILS_TEST_TIDY to `1',
7553 ;; which requires tidy-all.
7554 ;; (setenv "RINUTILS_TEST_TIDY" "1")
7555 (invoke "perl" "CI-testing/continuous-integration-testing.pl")))))))
7556 (build-system cmake-build-system)
7557 (home-page "https://www.shlomifish.org/open-source/projects/")
7558 (synopsis "C11 / gnu11 utilities C library")
7559 (description "This package provides C11 / gnu11 utilities C library")
7560 (license license:expat)))
7561
7562 (define-public fortune-mod
7563 (package
7564 (name "fortune-mod")
7565 (version "2.28.0")
7566 (source
7567 (origin
7568 (method git-fetch)
7569 (uri (git-reference
7570 (url "https://github.com/shlomif/fortune-mod")
7571 (commit (string-append "fortune-mod-" version))))
7572 (file-name (git-file-name name version))
7573 (sha256
7574 (base32 "1ppzgnffgdcmq6fq4gmdq2ig10ip2bnfgklkb3i8nc6bdxm7pb89"))))
7575 (build-system cmake-build-system)
7576 (arguments
7577 `(#:test-target "check"
7578 #:phases
7579 (modify-phases %standard-phases
7580 (add-after 'unpack 'fix-build-env
7581 (lambda* (#:key inputs #:allow-other-keys)
7582 (use-modules (guix build utils))
7583 (let* ((cmake-rules (assoc-ref inputs "cmake-rules")))
7584 (copy-file cmake-rules
7585 (string-append "fortune-mod/cmake/"
7586 (strip-store-file-name cmake-rules)))
7587 (chdir "fortune-mod")
7588 ;; TODO: Valgrind tests fail for some reason.
7589 ;; Similar issue: https://github.com/shlomif/fortune-mod/issues/21 (?)
7590 (delete-file "tests/t/valgrind.t")
7591 #t)))
7592 (add-after 'install 'fix-install-directory
7593 (lambda* (#:key outputs #:allow-other-keys)
7594 ;; Move binary from "games/" to "bin/" and remove the latter. This
7595 ;; is easier than patching CMakeLists.txt since the tests hard-code
7596 ;; the location as well.
7597 (let* ((out (assoc-ref outputs "out"))
7598 (bin (string-append out "/bin"))
7599 (games (string-append out "/games")))
7600 (rename-file (string-append games "/fortune")
7601 (string-append bin "/fortune"))
7602 (rmdir games)
7603 #t))))))
7604 (inputs (list recode))
7605 (native-inputs
7606 `(("perl" ,perl)
7607 ;; The following is only needed for tests.
7608 ("perl-file-find-object" ,perl-file-find-object)
7609 ("perl-test-differences" ,perl-test-differences)
7610 ("perl-class-xsaccessor" ,perl-class-xsaccessor)
7611 ("perl-io-all" ,perl-io-all)
7612 ("perl-test-runvalgrind" ,perl-test-runvalgrind)
7613 ("cmake-rules" ,shlomif-cmake-modules)
7614 ("rinutils" ,rinutils)))
7615 (home-page "https://www.shlomifish.org/open-source/projects/fortune-mod/")
7616 (synopsis "The Fortune Cookie program from BSD games")
7617 (description "Fortune is a command-line utility which displays a random
7618 quotation from a collection of quotes.")
7619 (license license:bsd-4)))
7620
7621 (define xonotic-data
7622 (package
7623 (name "xonotic-data")
7624 (version "0.8.2")
7625 (source
7626 (origin
7627 (method url-fetch)
7628 (uri (string-append "http://dl.xonotic.org/xonotic-"
7629 version ".zip"))
7630 (file-name (string-append name "-" version ".zip"))
7631 (sha256
7632 (base32
7633 "1mcs6l4clvn7ibfq3q69k2p0z6ww75rxvnngamdq5ic6yhq74bx2"))))
7634 (build-system trivial-build-system)
7635 (native-inputs
7636 `(("unzip" ,unzip)))
7637 (arguments
7638 `(#:modules ((guix build utils))
7639 #:builder
7640 (begin
7641 (use-modules (guix build utils))
7642 (let* ((out (assoc-ref %outputs "out"))
7643 (xonotic (string-append out "/share/xonotic"))
7644 (source (assoc-ref %build-inputs "source"))
7645 (unzip (search-input-file %build-inputs "/bin/unzip")))
7646 (copy-file source (string-append ,name "-" ,version ".zip"))
7647 (invoke unzip (string-append ,name "-" ,version ".zip"))
7648 (mkdir-p out)
7649 (mkdir-p xonotic)
7650 (chdir "Xonotic")
7651 (copy-recursively "data"
7652 (string-append xonotic "/data"))
7653 (copy-recursively "server"
7654 (string-append xonotic "/server"))
7655 (install-file "key_0.d0pk" xonotic)))))
7656 (home-page "http://xonotic.org")
7657 (synopsis "Data files for Xonotic")
7658 (description
7659 "Xonotic-data provides the data files required by the game Xonotic.")
7660 (license (list license:gpl2+
7661 (license:x11-style "file://server/rcon.pl")))))
7662
7663 (define-public xonotic
7664 (package
7665 (name "xonotic")
7666 (version "0.8.2")
7667 (source
7668 (origin
7669 (method url-fetch)
7670 (uri (string-append "http://dl.xonotic.org/xonotic-"
7671 version "-source.zip"))
7672 (file-name (string-append name "-" version ".zip"))
7673 (sha256
7674 (base32
7675 "0axxw04fyz6jlfqd0kp7hdrqa0li31sx1pbipf2j5qp9wvqicsay"))))
7676 (build-system gnu-build-system)
7677 (arguments
7678 `(#:configure-flags (list (string-append "--prefix="
7679 (assoc-ref %outputs "out"))
7680 "--disable-rijndael")
7681 #:phases
7682 (modify-phases %standard-phases
7683 (add-before 'configure 'make-darkplaces
7684 (lambda* (#:key outputs #:allow-other-keys)
7685 (let* ((out (assoc-ref outputs "out"))
7686 (sharedir (string-append out "/share/xonotic/")))
7687 (invoke "make" "-C" "source/darkplaces"
7688 (string-append "DP_FS_BASEDIR="
7689 sharedir)
7690 "DP_LINK_TO_LIBJPEG=1"
7691 "DP_SOUND_API=ALSA"
7692 "CC=gcc"
7693 "-f" "makefile"
7694 "cl-release")
7695 (invoke "make" "-C" "source/darkplaces"
7696 (string-append "DP_FS_BASEDIR="
7697 sharedir)
7698 "DP_LINK_TO_LIBJPEG=1"
7699 "DP_SOUND_API=ALSA"
7700 "CC=gcc"
7701 "-f" "makefile"
7702 "sdl-release")
7703 (invoke "make" "-C" "source/darkplaces"
7704 (string-append "DP_FS_BASEDIR="
7705 sharedir)
7706 "DP_LINK_TO_LIBJPEG=1"
7707 "DP_SOUND_API=ALSA"
7708 "CC=gcc"
7709 "-f" "makefile"
7710 "sv-release"))))
7711 (add-before 'configure 'bootstrap
7712 (lambda _
7713 (chdir "source/d0_blind_id")
7714 (invoke "sh" "autogen.sh")))
7715 (add-after 'build 'install-desktop-entry
7716 (lambda* (#:key outputs #:allow-other-keys)
7717 ;; Add .desktop files for the 2 variants and the symlink
7718 (let* ((output (assoc-ref outputs "out"))
7719 (apps (string-append output "/share/applications")))
7720 (mkdir-p apps)
7721 (with-output-to-file
7722 (string-append apps "/xonotic-glx.desktop")
7723 (lambda _
7724 (format #t
7725 "[Desktop Entry]~@
7726 Name=xonotic-glx~@
7727 Comment=Xonotic glx~@
7728 Exec=~a/bin/xonotic-glx~@
7729 TryExec=~@*~a/bin/xonotic-glx~@
7730 Icon=xonotic~@
7731 Categories=Game~@
7732 Type=Application~%"
7733 output)))
7734 (with-output-to-file
7735 (string-append apps "/xonotic-sdl.desktop")
7736 (lambda _
7737 (format #t
7738 "[Desktop Entry]~@
7739 Name=xonotic-sdl~@
7740 Comment=Xonotic sdl~@
7741 Exec=~a/bin/xonotic-sdl~@
7742 TryExec=~@*~a/bin/xonotic-sdl~@
7743 Icon=xonotic~@
7744 Categories=Game~@
7745 Type=Application~%"
7746 output)))
7747 (with-output-to-file
7748 (string-append apps "/xonotic.desktop")
7749 (lambda _
7750 (format #t
7751 "[Desktop Entry]~@
7752 Name=xonotic~@
7753 Comment=Xonotic~@
7754 Exec=~a/bin/xonotic-glx~@
7755 TryExec=~@*~a/bin/xonotic~@
7756 Icon=xonotic~@
7757 Categories=Game~@
7758 Type=Application~%"
7759 output)))
7760 #t)))
7761 (add-after 'install-desktop-entry 'install-icons
7762 (lambda* (#:key outputs #:allow-other-keys)
7763 (let ((out (assoc-ref outputs "out")))
7764 (with-directory-excursion "../../misc/logos/icons_png/"
7765 (for-each
7766 (lambda (file)
7767 (let* ((size (string-filter char-numeric? file))
7768 (icons (string-append out "/share/icons/hicolor/"
7769 size "x" size "/apps")))
7770 (mkdir-p icons)
7771 (copy-file file (string-append icons "/xonotic.png"))))
7772 '("xonotic_16.png" "xonotic_22.png" "xonotic_24.png"
7773 "xonotic_32.png" "xonotic_48.png" "xonotic_64.png"
7774 "xonotic_128.png" "xonotic_256.png" "xonotic_512.png"))))))
7775 (add-after 'install-icons 'install-binaries
7776 (lambda* (#:key outputs #:allow-other-keys)
7777 (let ((out (assoc-ref outputs "out")))
7778 (define (install src dst)
7779 (let ((dst (string-append out dst)))
7780 (mkdir-p (dirname dst))
7781 (copy-file src dst)))
7782 (mkdir-p (string-append out "/bin"))
7783 (install "../darkplaces/darkplaces-dedicated"
7784 "/bin/xonotic-dedicated")
7785 (install "../darkplaces/darkplaces-glx"
7786 "/bin/xonotic-glx")
7787 (install "../darkplaces/darkplaces-sdl"
7788 "/bin/xonotic-sdl")
7789 ;; Provide a default xonotic executable, defaulting to SDL.
7790 (symlink (string-append out "/bin/xonotic-sdl")
7791 (string-append out "/bin/xonotic"))
7792 #t)))
7793 (add-after 'install-binaries 'install-data
7794 (lambda* (#:key outputs inputs #:allow-other-keys)
7795 (let* ((out (assoc-ref outputs "out"))
7796 (data (assoc-ref inputs "xonotic-data")))
7797 (symlink (string-append data "/share/xonotic")
7798 (string-append out "/share/xonotic"))
7799 #t)))
7800 (add-after 'install-binaries 'wrap-binaries
7801 (lambda* (#:key outputs inputs #:allow-other-keys)
7802 ;; Curl and libvorbis need to be wrapped so that we get
7803 ;; sound and networking.
7804 (let* ((out (assoc-ref outputs "out"))
7805 (bin (string-append out "/bin/xonotic"))
7806 (bin-sdl (string-append out "/bin/xonotic-sdl"))
7807 (bin-glx (string-append out "/bin/xonotic-glx"))
7808 (bin-dedicated (string-append out "/bin/xonotic-dedicated"))
7809 (curl (assoc-ref inputs "curl"))
7810 (vorbis (assoc-ref inputs "libvorbis")))
7811 (wrap-program bin
7812 `("LD_LIBRARY_PATH" ":" prefix
7813 (,(string-append curl "/lib:" vorbis "/lib"))))
7814 (wrap-program bin-sdl
7815 `("LD_LIBRARY_PATH" ":" prefix
7816 (,(string-append curl "/lib:" vorbis "/lib"))))
7817 (wrap-program bin-glx
7818 `("LD_LIBRARY_PATH" ":" prefix
7819 (,(string-append curl "/lib:" vorbis "/lib"))))
7820 (wrap-program bin-dedicated
7821 `("LD_LIBRARY_PATH" ":" prefix
7822 (,(string-append curl "/lib:" vorbis "/lib"))))
7823 #t))))))
7824 (inputs
7825 `(("xonotic-data" ,xonotic-data)
7826 ("alsa-lib" ,alsa-lib)
7827 ("curl" ,curl)
7828 ("libjpeg" ,libjpeg-turbo)
7829 ("libmodplug" ,libmodplug)
7830 ("libvorbis" ,libvorbis)
7831 ("libogg" ,libogg)
7832 ("libxpm" ,libxpm)
7833 ("libxxf86dga" ,libxxf86dga)
7834 ("libxxf86vm" ,libxxf86vm)
7835 ("libx11" ,libx11)
7836 ("libxext" ,libxext)
7837 ("libxau" ,libxau)
7838 ("libxdmcp" ,libxdmcp)
7839 ("mesa" ,mesa)
7840 ("glu" ,glu)
7841 ("freetype" ,freetype)
7842 ("sdl2" ,sdl2)
7843 ("libpng" ,libpng)
7844 ("hicolor-icon-theme" ,hicolor-icon-theme)))
7845 (native-inputs
7846 (list unzip
7847 autoconf
7848 automake
7849 pkg-config
7850 libtool
7851 gmp))
7852 (home-page "https://xonotic.org")
7853 (synopsis "Fast-paced first-person shooter game")
7854 (description
7855 "Xonotic is a free, fast-paced first-person shooter.
7856 The project is geared towards providing addictive arena shooter
7857 gameplay which is all spawned and driven by the community itself.
7858 Xonotic is a direct successor of the Nexuiz project with years of
7859 development between them, and it aims to become the best possible
7860 open-source FPS of its kind.")
7861 (license (list license:gpl2+
7862 license:bsd-3 ; /source/d0_blind_id folder and others
7863 (license:x11-style "" "See file rcon.pl.")))))
7864
7865 (define-public frotz
7866 (package
7867 (name "frotz")
7868 (version "2.44")
7869 (source (origin
7870 (method url-fetch)
7871 (uri (list (string-append
7872 "http://www.ifarchive.org/if-archive/infocom/interpreters/"
7873 "frotz/frotz-" version ".tar.gz")
7874 (string-append
7875 "ftp://ftp.ifarchive.org/if-archive/infocom/interpreters/"
7876 "frotz/frotz-" version ".tar.gz")))
7877 (sha256
7878 (base32
7879 "1v735xr3blznac8fnwa27s1vhllx4jpz7kw7qdw1bsfj6kq21v3k"))))
7880 (build-system gnu-build-system)
7881 (arguments
7882 `(#:tests? #f ; there are no tests
7883 #:phases
7884 (modify-phases %standard-phases
7885 (delete 'configure)
7886 (add-before 'build 'curses
7887 (lambda _
7888 (substitute* "Makefile"
7889 (("lcurses") "lncurses"))
7890 #t))
7891 (replace 'install
7892 (lambda* (#:key outputs #:allow-other-keys)
7893 (let* ((out (assoc-ref outputs "out"))
7894 (bin (string-append out "/bin"))
7895 (man (string-append out "/share/man/man6")))
7896 (install-file "frotz" bin)
7897 (mkdir-p man)
7898 (install-file "doc/frotz.6" man)
7899 #t))))))
7900 (inputs (list libmodplug libsamplerate libsndfile libvorbis ncurses))
7901 (synopsis "Portable Z-machine interpreter (ncurses version) for text adventure games")
7902 (description "Frotz is an interpreter for Infocom games and other Z-machine
7903 games in the text adventure/interactive fiction genre. This version of Frotz
7904 complies with standard 1.0 of Graham Nelson's specification. It plays all
7905 Z-code games V1-V8, including V6, with sound support through libao, and uses
7906 ncurses for text display.")
7907 (home-page "http://frotz.sourceforge.net")
7908 (license license:gpl2+)))
7909
7910 (define-public naev
7911 (package
7912 (name "naev")
7913 (version "0.8.2")
7914 (source
7915 (origin
7916 (method git-fetch)
7917 (uri (git-reference
7918 (url "https://github.com/naev/naev")
7919 (commit (string-append "v" version))))
7920 (file-name (git-file-name name version))
7921 (sha256
7922 (base32 "02rk2fv2nhx5xsi0cariisamab3dpncwps4q3i3ki0y27xpwxzfx"))))
7923 (build-system meson-build-system)
7924 (arguments
7925 ;; XXX: Do not add debugging symbols, which cause the build to fail.
7926 `(#:configure-flags (list "--buildtype=release")
7927 #:tests? #f)) ;sole test fails with a missing "/dev/dri" error
7928 (native-inputs
7929 `(("gettext" ,gettext-minimal)
7930 ("pkg-config" ,pkg-config)))
7931 (inputs
7932 `(("freetype" ,freetype)
7933 ("glpk" ,glpk)
7934 ("libpng" ,libpng)
7935 ("libvorbis" ,libvorbis)
7936 ("libwebp" ,libwebp)
7937 ("libxml2" ,libxml2)
7938 ("luajit" ,luajit)
7939 ("openal" ,openal)
7940 ("openblas" ,openblas)
7941 ("physfs" ,physfs)
7942 ("sdl" ,(sdl-union (list sdl2 sdl2-image sdl2-mixer)))
7943 ("suitesparse" ,suitesparse)))
7944 (home-page "https://naev.org/")
7945 (synopsis "Game about space exploration, trade and combat")
7946 (description
7947 "Naev is a 2d action/rpg space game that combines elements from
7948 the action, RPG and simulation genres. You pilot a spaceship from
7949 a top-down perspective, and are more or less free to do what you want.
7950 As the genre name implies, you’re able to trade and engage in combat
7951 at will. Beyond that, there’s an ever-growing number of story-line
7952 missions, equipment, and ships; even the galaxy itself grows larger
7953 with each release. For the literacy-inclined, there are large amounts
7954 of lore accompanying everything from planets to equipment.")
7955 (license (list license:gpl3
7956 license:public-domain
7957 license:expat ;edtaa3func.c
7958 license:bsd-2 ;distance_field.c
7959 license:bsd-3 ;perlin.c
7960 ;; Assets.
7961 license:silofl1.1
7962 license:gpl2+
7963 license:cc0
7964 license:cc-by3.0
7965 license:cc-by-sa3.0
7966 license:cc-by4.0
7967 license:cc-by-sa4.0))))
7968
7969 (define-public frotz-dumb-terminal
7970 (package
7971 (name "frotz-dumb-terminal")
7972 (version "2.44")
7973 (source (origin
7974 (method url-fetch)
7975 (uri (list (string-append
7976 "http://www.ifarchive.org/if-archive/infocom/interpreters/"
7977 "frotz/frotz-" version ".tar.gz")
7978 (string-append
7979 "ftp://ftp.ifarchive.org/if-archive/infocom/interpreters/"
7980 "frotz/frotz-" version ".tar.gz")))
7981 (sha256
7982 (base32
7983 "1v735xr3blznac8fnwa27s1vhllx4jpz7kw7qdw1bsfj6kq21v3k"))))
7984 (build-system gnu-build-system)
7985 (arguments
7986 `(#:tests? #f ; there are no tests
7987 #:phases
7988 (modify-phases %standard-phases
7989 (delete 'configure)
7990 (replace 'build
7991 (lambda _
7992 (invoke "make" "dumb")))
7993 (replace 'install
7994 (lambda* (#:key outputs #:allow-other-keys)
7995 (let* ((out (assoc-ref outputs "out"))
7996 (bin (string-append out "/bin"))
7997 (man (string-append out "/share/man/man6")))
7998 (install-file "dfrotz" bin)
7999 (mkdir-p man)
8000 (install-file "doc/dfrotz.6" man)
8001 #t))))))
8002 (synopsis "Portable Z-machine dumb interpreter for text adventure games")
8003 (description "Frotz is an interpreter for Infocom games and
8004 other Z-machine games in the text adventure/interactive fiction genre.
8005 dfrotz is the dumb interface version. You get no screen control; everything
8006 is just printed to the terminal line by line. The terminal handles all the
8007 scrolling. Maybe you'd like to experience what it's like to play Adventure on
8008 a teletype. A much cooler use for compiling Frotz with the dumb interface is
8009 that it can be wrapped in CGI scripting, PHP, and the like to allow people
8010 to play games on webpages. It can also be made into a chat bot.")
8011 (home-page "http://frotz.sourceforge.net")
8012 (license license:gpl2+)))
8013
8014 (define-public frotz-sdl
8015 (let* ((commit "4de8c34f2116fff554af6216c30ec9d41bf50b24"))
8016 (package
8017 (name "frotz-sdl")
8018 (version "2.45pre")
8019 (source (origin
8020 (method git-fetch)
8021 (uri (git-reference
8022 (url "https://gitlab.com/DavidGriffith/frotz")
8023 (commit commit)))
8024 (sha256
8025 (base32
8026 "18ms21pcrl7ipcnyqnf8janamkryzx78frsgd9kfk67jvbj0z2k8"))
8027 (file-name (git-file-name name version))))
8028 (build-system gnu-build-system)
8029 (arguments
8030 `(#:tests? #f ; there are no tests
8031 #:phases
8032 (modify-phases %standard-phases
8033 (delete 'configure)
8034 (add-before 'build 'patch-makefile
8035 (lambda _
8036 (substitute* "Makefile"
8037 (("lcurses") "lncurses")
8038 (("^BUILD_DATE_TIME =.*$")
8039 "BUILD_DATE_TIME = \"2.45pre-20180907.00000\"\n"))
8040 #t))
8041 (replace 'build
8042 (lambda _
8043 (invoke "make" "sdl")))
8044 (replace 'install
8045 (lambda* (#:key outputs #:allow-other-keys)
8046 (let* ((out (assoc-ref outputs "out"))
8047 (bin (string-append out "/bin"))
8048 (man (string-append out "/share/man/man6")))
8049 (install-file "sfrotz" bin)
8050 (mkdir-p man)
8051 (install-file "doc/sfrotz.6" man)
8052 #t))))))
8053 (native-inputs
8054 (list pkg-config which perl))
8055 (inputs (list sdl2
8056 sdl2-mixer
8057 libmodplug
8058 libsamplerate
8059 libsndfile
8060 libvorbis
8061 ncurses
8062 freetype
8063 libjpeg-turbo))
8064 (synopsis "Portable Z-machine interpreter (SDL port) for text adventure games")
8065 (description "Frotz is an interpreter for Infocom games and other Z-machine
8066 games in the text adventure/interactive fiction genre. This version of Frotz
8067 using SDL fully supports all these versions of the Z-Machine including the
8068 graphical version 6. Graphics and sound are created through the use of the SDL
8069 libraries. AIFF sound effects and music in MOD and OGG formats are supported
8070 when packaged in Blorb container files or optionally from individual files.")
8071 (home-page "http://frotz.sourceforge.net")
8072 (license license:gpl2+))))
8073
8074 (define-public frozen-bubble
8075 ;; Last official release is very outdated (2010). Use latest commit (2017).
8076 (let ((commit "d6a029110ad6ab9e4960052e175addc98807fb7e")
8077 (revision "1"))
8078 (package
8079 (name "frozen-bubble")
8080 (version (git-version "2.2.1" revision commit))
8081 (source
8082 (origin
8083 (method git-fetch)
8084 (uri (git-reference
8085 (url "https://github.com/kthakore/frozen-bubble")
8086 (commit commit)))
8087 (file-name (git-file-name name version))
8088 (sha256
8089 (base32 "1rfrcym5lf4qac2qdklikb1ywijyxypq298azzxahy461dadl6cx"))))
8090 (build-system perl-build-system)
8091 (arguments
8092 `(#:phases
8093 (modify-phases %standard-phases
8094 ;; Build process needs to create files in the "server"
8095 ;; directory.
8096 (add-after 'unpack 'fix-permissions
8097 (lambda _
8098 (for-each make-file-writable
8099 (find-files "server" "." #:directories? #t))))
8100 ;; By default, build stops at warnings.
8101 (add-after 'unpack 'prevent-build-error
8102 (lambda _
8103 (substitute* "inc/My/Builder.pm"
8104 (("-Werror") ""))
8105 #t))
8106 (add-after 'install 'install-desktop-file-and-icons
8107 (lambda* (#:key outputs #:allow-other-keys)
8108 (let* ((share (string-append (assoc-ref outputs "out") "/share"))
8109 (hicolor (string-append share "/icons/hicolor")))
8110 ;; Create desktop entry.
8111 (make-desktop-entry-file
8112 (string-append share "/applications/" ,name ".desktop")
8113 #:name "Frozen Bubble"
8114 #:comment "Frozen Bubble arcade game"
8115 #:exec ,name
8116 #:icon ,name
8117 #:categories '("Game" "ArcadeGame"))
8118 ;; Add icons.
8119 (with-directory-excursion "share/icons"
8120 (for-each
8121 (lambda (size)
8122 (let* ((dim (string-append size "x" size))
8123 (dir (string-append hicolor "/" dim "/apps")))
8124 (mkdir-p dir)
8125 (copy-file
8126 (string-append "frozen-bubble-icon-" dim ".png")
8127 (string-append dir "/frozen-bubble.png"))))
8128 '("16" "32" "48" "64"))))
8129 #t))
8130 (add-after 'install 'wrap-perl-libs
8131 (lambda* (#:key outputs #:allow-other-keys)
8132 (let ((out (assoc-ref outputs "out"))
8133 (perl5lib (getenv "PERL5LIB")))
8134 (for-each (lambda (prog)
8135 (wrap-program (string-append out "/" prog)
8136 `("PERL5LIB" ":" prefix
8137 (,(string-append perl5lib ":" out
8138 "/lib/perl5/site_perl")))))
8139 (find-files "bin" ".")))
8140 #t)))))
8141 (native-inputs
8142 (list perl-alien-sdl perl-capture-tiny perl-locale-maketext-lexicon
8143 perl-module-build pkg-config))
8144 (inputs
8145 `(("glib" ,glib)
8146 ("perl-compress-bzip2" ,perl-compress-bzip2)
8147 ("perl-file-sharedir" ,perl-file-sharedir)
8148 ("perl-file-slurp" ,perl-file-slurp)
8149 ("perl-file-which" ,perl-file-which)
8150 ("perl-ipc-system-simple" ,perl-ipc-system-simple)
8151 ("perl-sdl" ,perl-sdl)
8152 ("sdl" ,(sdl-union (list sdl sdl-image sdl-mixer sdl-pango sdl-ttf)))))
8153 (home-page "http://frozen-bubble.org/")
8154 (synopsis "Puzzle with bubbles")
8155 (description
8156 "Frozen-Bubble is a clone of the popular Puzzle Bobble game, in which
8157 you attempt to shoot bubbles into groups of the same color to cause them to
8158 pop.
8159
8160 Players compete as penguins and must use the arrow keys to aim a colored
8161 bubble at groups of bubbles. The objective is to clear all the bubbles off
8162 the screen before a bubble passes below a line at the bottom.
8163
8164 It features 100 single-player levels, a two-player mode, music and striking
8165 graphics. A level editor is also included to allow players to create and play
8166 their own levels.")
8167 (license license:gpl2))))
8168
8169 (define-public libmanette
8170 (package
8171 (name "libmanette")
8172 (version "0.2.6")
8173 (source (origin
8174 (method url-fetch)
8175 (uri (string-append "mirror://gnome/sources/libmanette/"
8176 (version-major+minor version) "/"
8177 "libmanette-" version ".tar.xz"))
8178 (sha256
8179 (base32
8180 "1b3bcdkk5xd5asq797cch9id8692grsjxrc1ss87vv11m1ck4rb3"))))
8181 (build-system meson-build-system)
8182 (native-inputs
8183 (list `(,glib "bin") ; for glib-compile-resources
8184 gobject-introspection pkg-config vala))
8185 (inputs
8186 (list libevdev libgudev))
8187 (home-page "https://wiki.gnome.org/Apps/Games")
8188 (synopsis "Game controller library")
8189 (description "Libmanette is a small GObject library giving you simple
8190 access to game controllers. It supports the de-facto standard gamepads as
8191 defined by the W3C standard Gamepad specification or as implemented by the SDL
8192 GameController.")
8193 (license license:lgpl2.1+)))
8194
8195 (define-public quadrapassel
8196 (package
8197 (name "quadrapassel")
8198 (version "3.36.05")
8199 (source (origin
8200 (method url-fetch)
8201 (uri (string-append "mirror://gnome/sources/quadrapassel/"
8202 (version-major+minor version) "/"
8203 "quadrapassel-" version ".tar.xz"))
8204 (sha256
8205 (base32
8206 "04abxmimh5npw8rhz1sfi6wxilgc6i1wka9mlnfwp8v1p1cb00cv"))))
8207 (build-system meson-build-system)
8208 (arguments
8209 '(#:glib-or-gtk? #t
8210 #:phases
8211 (modify-phases %standard-phases
8212 (add-after 'unpack 'skip-gtk-update-icon-cache
8213 ;; Don't create 'icon-theme.cache'.
8214 (lambda _
8215 (substitute* "build-aux/meson_post_install.py"
8216 (("gtk-update-icon-cache") (which "true")))
8217 #t)))))
8218 (native-inputs
8219 `(("desktop-file-utils" ,desktop-file-utils) ;for desktop-file-validate
8220 ("gettext" ,gettext-minimal)
8221 ("glib" ,glib "bin") ;for glib-compile-resources
8222 ("itstool" ,itstool)
8223 ("libxml2" ,libxml2) ;for xmllint
8224 ("pkg-config" ,pkg-config)
8225 ("vala" ,vala)))
8226 (inputs
8227 (list clutter
8228 clutter-gtk
8229 gsound
8230 gtk+
8231 libcanberra
8232 libmanette
8233 librsvg))
8234 (home-page "https://wiki.gnome.org/Apps/Quadrapassel")
8235 (synopsis "GNOME version of Tetris")
8236 (description "Quadrapassel comes from the classic falling-block game,
8237 Tetris. The goal of the game is to create complete horizontal lines of
8238 blocks, which will disappear. The blocks come in seven different shapes made
8239 from four blocks each: one straight, two L-shaped, one square, and two
8240 S-shaped. The blocks fall from the top center of the screen in a random
8241 order. You rotate the blocks and move them across the screen to drop them in
8242 complete lines. You score by dropping blocks fast and completing lines. As
8243 your score gets higher, you level up and the blocks fall faster.")
8244 (license license:gpl2+)))
8245
8246 (define-public endless-sky
8247 (package
8248 (name "endless-sky")
8249 (version "0.9.14")
8250 (source
8251 (origin
8252 (method git-fetch)
8253 (uri (git-reference
8254 (url "https://github.com/endless-sky/endless-sky")
8255 (commit (string-append "v" version))))
8256 (file-name (git-file-name name version))
8257 (sha256
8258 (base32 "12iganf8dxiyrjznnabsarxjsr0h717j3k4mz15p0k67wxyahhmf"))))
8259 (build-system scons-build-system)
8260 (arguments
8261 `(#:scons ,scons-python2
8262 #:scons-flags (list (string-append "PREFIX=" (assoc-ref %outputs "out")))
8263 #:phases
8264 (modify-phases %standard-phases
8265 (add-after 'unpack 'fix-paths
8266 (lambda* (#:key outputs #:allow-other-keys)
8267 ;; Look for resources in the store directory.
8268 (substitute* "source/Files.cpp"
8269 (("/usr/local") (assoc-ref outputs "out")))
8270 ;; Install game binary into %out/bin.
8271 (substitute* "SConstruct"
8272 (("games\"") "bin\""))))
8273 (add-before 'build 'use-gcc-ar
8274 ;; Use gcc-ar to support LTO.
8275 (lambda _ (setenv "AR" "gcc-ar"))))))
8276 (inputs
8277 `(("glew" ,glew)
8278 ("libjpeg" ,libjpeg-turbo)
8279 ("libmad" ,libmad)
8280 ("libpng" ,libpng)
8281 ("openal" ,openal)
8282 ("sdl2" ,sdl2)))
8283 (home-page "https://endless-sky.github.io/")
8284 (synopsis "2D space trading and combat game")
8285 (description "Endless Sky is a 2D space trading and combat game. Explore
8286 other star systems. Earn money by trading, carrying passengers, or completing
8287 missions. Use your earnings to buy a better ship or to upgrade the weapons and
8288 engines on your current one. Blow up pirates. Take sides in a civil war. Or
8289 leave human space behind and hope to find friendly aliens whose culture is more
8290 civilized than your own.")
8291 (license (list license:gpl3+
8292 license:cc-by-sa3.0
8293 license:cc-by-sa4.0
8294 license:public-domain))))
8295
8296 (define-public stepmania
8297 (package
8298 (name "stepmania")
8299 (version "5.1.0-b2")
8300 (source
8301 (origin
8302 (method git-fetch)
8303 (uri (git-reference
8304 (url "https://github.com/stepmania/stepmania")
8305 (commit (string-append "v" version))))
8306 (file-name (git-file-name name version))
8307 (sha256
8308 (base32
8309 "0a7y9l7xm510vgnpmj1is7p9m6d6yd0fcaxrjcickz295k5w3rdn"))
8310 (modules '((guix build utils)))
8311 (snippet
8312 '(begin
8313 ;; Remove song files, which are licensed under a non-commercial
8314 ;; clause, and a course pointing to them.
8315 (for-each delete-file-recursively
8316 '("Songs/StepMania 5/Goin' Under"
8317 "Songs/StepMania 5/MechaTribe Assault"
8318 "Songs/StepMania 5/Springtime"))
8319 (for-each delete-file '("Courses/Default/Jupiter.crs"
8320 "Courses/Default/Jupiter.png"))
8321 ;; Unbundle libpng.
8322 (substitute* "extern/CMakeLists.txt"
8323 (("include\\(CMakeProject-png.cmake\\)") ""))
8324 (delete-file-recursively "extern/libpng")
8325 #t))))
8326 (build-system cmake-build-system)
8327 (arguments
8328 `(#:tests? #f ;FIXME: couldn't find how to run tests
8329 #:build-type "Release"
8330 #:out-of-source? #f ;for the 'install-desktop' phase
8331 #:configure-flags
8332 (list "-DWITH_SYSTEM_FFMPEG=1"
8333 ;; SSE instructions are available on Intel systems only.
8334 ,@(if (any (cute string-prefix? <> (or (%current-target-system)
8335 (%current-system)))
8336 '("x86_64" "i686"))
8337 '()
8338 '("-DWITH_SSE2=NO"))
8339 ;; Configuration cannot find GTK2 without the two following
8340 ;; flags.
8341 (string-append "-DGTK2_GDKCONFIG_INCLUDE_DIR="
8342 (assoc-ref %build-inputs "gtk+")
8343 "/lib/gtk-2.0/include")
8344 (string-append "-DGTK2_GLIBCONFIG_INCLUDE_DIR="
8345 (assoc-ref %build-inputs "glib")
8346 "/lib/glib-2.0/include"))
8347 #:phases
8348 (modify-phases %standard-phases
8349 (add-after 'unpack 'ensure-application-files-can-be-found
8350 (lambda* (#:key outputs #:allow-other-keys)
8351 (let ((out (assoc-ref outputs "out")))
8352 (substitute* "src/arch/LoadingWindow/LoadingWindow_Gtk.cpp"
8353 (("RageFileManagerUtil::sDirOfExecutable \\+ \"/\" \\+ \"GtkModule.so\"")
8354 (string-append "\"" out
8355 "/share/stepmania/GtkModule.so\"")))
8356 (substitute* "src/arch/ArchHooks/ArchHooks_Unix.cpp"
8357 (("Root = sDirOfExecutable")
8358 (string-append "Root = \"" out "/share/stepmania/\""))
8359 (("sDirOfExecutable \\+ \"/(Packages|Songs)\"" _ dir)
8360 (string-append "\"" out "/share/stepmania/" dir "\"")))
8361 (substitute* "src/RageFileManager.cpp"
8362 (("RageFileManagerUtil::sDirOfExecutable \\+ \"/\"")
8363 (string-append "\"" out "/share/stepmania/\""))))
8364 #t))
8365 (add-after 'unpack 'fix-install-subdir
8366 ;; Installation would be done in "%out/stepmania-X.Y", but we
8367 ;; prefer the more common layout "%out/share/stepmania".
8368 (lambda _
8369 (substitute* "src/CMakeLists.txt"
8370 (("\"stepmania-.*?\"") "\"share/stepmania\""))
8371 #t))
8372 (add-after 'unpack 'unbundle-libpng
8373 (lambda* (#:key inputs #:allow-other-keys)
8374 (substitute* "src/CMakeLists.txt"
8375 (("\\$\\{SM_EXTERN_DIR\\}/libpng/include")
8376 (string-append (assoc-ref inputs "libpng") "/include")))
8377 #t))
8378 (add-after 'install 'install-executable
8379 (lambda* (#:key outputs #:allow-other-keys)
8380 (let* ((out (assoc-ref outputs "out"))
8381 (bin (string-append out "/bin"))
8382 (exe (string-append out "/share/stepmania/stepmania")))
8383 (mkdir-p bin)
8384 (symlink exe (string-append bin "/stepmania"))
8385 #t)))
8386 (add-after 'install-executable 'install-desktop
8387 (lambda* (#:key outputs #:allow-other-keys)
8388 (let* ((out (assoc-ref outputs "out"))
8389 (share (string-append out "/share"))
8390 (applications (string-append share "/applications"))
8391 (icons (string-append share "/icons")))
8392 (install-file "stepmania.desktop" applications)
8393 (mkdir-p icons)
8394 (copy-recursively "icons" icons)
8395 #t)))
8396 ;; Move documentation in a more usual place, i.e.,
8397 ;; "%out/share/doc/stepmania/".
8398 (add-after 'install-desktop 'install-doc
8399 (lambda* (#:key outputs #:allow-other-keys)
8400 (let* ((out (assoc-ref outputs "out"))
8401 (share (string-append out "/share")))
8402 (with-directory-excursion share
8403 (mkdir-p "doc")
8404 (symlink "../stepmania/Docs" "doc/stepmania"))
8405 #t))))))
8406 (native-inputs
8407 (list pkg-config yasm))
8408 (inputs
8409 `(("alsa-lib" ,alsa-lib)
8410 ;; Per upstream, StepMania is only guaranteed to work with a very
8411 ;; specific FFmpeg version, which is included in the repository as
8412 ;; a Git submodule. This particular version requirement usually
8413 ;; changes every few years.
8414 ("ffmpeg" ,ffmpeg-for-stepmania)
8415 ("glib" ,glib)
8416 ("glew" ,glew)
8417 ("gtk+" ,gtk+-2)
8418 ("jsoncpp" ,jsoncpp)
8419 ("libpng" ,libpng)
8420 ("libjpeg" ,libjpeg-turbo)
8421 ("libmad" ,libmad)
8422 ("libogg" ,libogg)
8423 ("libva" ,libva)
8424 ("libvorbis" ,libvorbis)
8425 ("libxinerama" ,libxinerama)
8426 ("libxrandr" ,libxrandr)
8427 ("mesa" ,mesa)
8428 ("pcre" ,pcre)
8429 ("pulseaudio" ,pulseaudio)
8430 ("sdl" ,sdl2)
8431 ("udev" ,eudev)
8432 ("zlib" ,zlib)))
8433 (synopsis "Advanced rhythm game designed for both home and arcade use")
8434 (description "StepMania is a dance and rhythm game. It features 3D
8435 graphics, keyboard and dance pad support, and an editor for creating your own
8436 steps.
8437
8438 This package provides the core application, but no song is shipped. You need
8439 to download and install them in @file{$HOME/.stepmania-X.Y/Songs} directory.")
8440 (home-page "https://www.stepmania.com")
8441 (license license:expat)))
8442
8443 (define-public oshu
8444 (package
8445 (name "oshu")
8446 (version "2.0.1")
8447 (source
8448 (origin
8449 (method git-fetch)
8450 (uri (git-reference
8451 (url "https://github.com/fmang/oshu")
8452 (commit version)))
8453 (file-name (git-file-name name version))
8454 (sha256
8455 (base32
8456 "1g598incc6zlls876slgwqblwiwiszkmqa4xpzw0z7mbjmmzsizz"))))
8457 (build-system cmake-build-system)
8458 (arguments
8459 `(#:phases
8460 (modify-phases %standard-phases
8461 (add-before 'check 'pre-check
8462 ;; `make test' doesn't actually build the test executable
8463 (lambda _ (invoke "make" "zerotokei"))))))
8464 (native-inputs
8465 (list pkg-config))
8466 (inputs
8467 (list cairo ffmpeg pango sdl2 sdl2-image))
8468 (home-page "https://github.com/fmang/oshu/")
8469 (synopsis "Rhythm game in which you click on circles")
8470 (description "@i{oshu!} is a minimalist variant of the @i{osu!} rhythm game,
8471 which is played by pressing buttons and following along sliders as they appear
8472 on screen. Its aim is to be able to play any beatmap even on low-end hardware.
8473
8474 This package provides the core application, but no beatmaps. You need to
8475 download and unpack them separately.")
8476 (license license:gpl3+)))
8477
8478 (define-public btanks
8479 (package
8480 (name "btanks")
8481 (version "0.9.8083")
8482 (source
8483 (origin
8484 (method url-fetch)
8485 (uri (string-append "mirror://sourceforge/btanks/btanks-source/"
8486 "btanks-" version ".tar.bz2"))
8487 (sha256
8488 (base32
8489 "0ha35kxc8xlbg74wsrbapfgxvcrwy6psjkqi7c6adxs55dmcxliz"))))
8490 (build-system scons-build-system)
8491 (arguments
8492 `(#:tests? #f ; there are none
8493 #:scons ,scons-python2
8494 #:scons-flags (list (string-append "prefix=" (assoc-ref %outputs "out")))
8495 #:phases
8496 (modify-phases %standard-phases
8497 (add-after 'unpack 'replace-removed-scons-syntax
8498 (lambda _
8499 (substitute* "SConstruct"
8500 (("Options") "Variables")
8501 (("opts.Add\\(BoolOption.*") "opts.Add('gcc_visibility', 'gcc visibility', 'true')")
8502 (("opts.Add\\(EnumOption.*") "opts.Add('mode', 'build mode', 'release')"))
8503 #t))
8504 (add-after 'set-paths 'set-sdl-paths
8505 (lambda* (#:key inputs #:allow-other-keys)
8506 (setenv "CPATH"
8507 (string-append
8508 (search-input-directory inputs "/include/SDL")
8509 ":" (or (getenv "CPATH") "")))))
8510 (add-after 'unpack 'fix-compilation-errors
8511 (lambda _
8512 (substitute* "mrt/base_file.h"
8513 (("#include <string>" m)
8514 (string-append m "\n#include <sys/types.h>")))
8515 (substitute* '("engine/sl08/sl08.h"
8516 "engine/sl08/sl08.py")
8517 (("signal = NULL") "signal = 0")
8518 (("object\\(NULL\\)") "object(0)")
8519 (("func\\(NULL\\)") "func(0)")
8520 ((" connect\\(signal_ref\\)")
8521 " this->connect(signal_ref)"))
8522 (substitute* "math/range_list.h"
8523 ((" lower_bound\\(value\\)")
8524 " this->lower_bound(value)")
8525 ((" erase\\(i\\)")
8526 " this->erase(i)"))
8527 (substitute* "clunk/source.cpp"
8528 (("using namespace clunk" m)
8529 (string-append "# define pow10f(x) exp10f(x)\n" m)))
8530 #t))
8531 (add-after 'unpack 'find-lua
8532 (lambda _
8533 (substitute* "engine/SConscript"
8534 (("lua5.1") "lua-5.1")
8535 (("bt_libs.append\\(lua\\)")
8536 "bt_libs.append(\"lua\")"))
8537 #t)))))
8538 (inputs
8539 `(("expat" ,expat)
8540 ("glu" ,glu)
8541 ("libsmpeg" ,libsmpeg-with-sdl1)
8542 ("libvorbis" ,libvorbis)
8543 ("lua51" ,lua-5.1)
8544 ("sdl" ,(sdl-union (list sdl
8545 sdl-mixer
8546 sdl-image
8547 sdl-ttf)))
8548 ("zlib" ,zlib)))
8549 (native-inputs
8550 (list pkg-config zip))
8551 (home-page "http://btanks.sourceforge.net")
8552 (synopsis "Multiplayer tank battle game")
8553 (description "Battle Tanks (also known as \"btanks\") is a funny battle
8554 game, where you can choose one of three vehicles and eliminate your enemy
8555 using the whole arsenal of weapons. It has original cartoon-like graphics and
8556 cool music, it’s fun and dynamic, it has several network modes for deathmatch
8557 and cooperative.")
8558 ;; Some parts (e.g. mrt/b64.cpp) are LGPLv2.1+, but the whole package is
8559 ;; released under GPLv2 or later. It comes with extra exceptions for the
8560 ;; developers.
8561 (license (list license:gpl2+ license:lgpl2.1+))))
8562
8563 (define-public slimevolley
8564 (package
8565 (name "slimevolley")
8566 (version "2.4.2")
8567 (source
8568 (origin
8569 (method url-fetch)
8570 (uri (string-append "https://download.tuxfamily.org/slime/"
8571 "slimevolley_" version ".tar.gz"))
8572 (sha256
8573 (base32 "1pi60zjpx95mfdkrbwf4cbzy5lv4v5qrljvgck46qca78i9g9g46"))))
8574 (build-system cmake-build-system)
8575 (arguments
8576 `(#:tests? #f ;no test
8577 ;; Work around build failure: "error adding symbols: DSO
8578 ;; missing from command line".
8579 #:configure-flags (list "-DCMAKE_EXE_LINKER_FLAGS=-lm")))
8580 (native-inputs
8581 `(("gettext" ,gettext-minimal)))
8582 (inputs
8583 `(("sdl" ,(sdl-union (list sdl sdl-image sdl-net sdl-ttf)))))
8584 (home-page "https://slime.tuxfamily.org/")
8585 (synopsis "Unrealistic 2D volleyball simulation")
8586 (description
8587 "Slime Volley is a 2D arcade-oriented volleyball simulation, in
8588 the spirit of some Java games of the same name.
8589
8590 Two teams, 1-3 players each, try to be the first to get 10 points.
8591 This happens when the one ball touches the floor on the other side of
8592 the net. There can be 1 to 8 balls in game. Once one ball touches
8593 the ground, the set ends and all balls are served again.")
8594 (license license:gpl3+)))
8595
8596 (define-public slingshot
8597 (package
8598 (name "slingshot")
8599 (version "0.9")
8600 (source
8601 (origin
8602 (method git-fetch)
8603 (uri (git-reference
8604 (url "https://github.com/ryanakca/slingshot")
8605 (commit version)))
8606 (file-name (git-file-name name version))
8607 (sha256
8608 (base32
8609 "19m8b6nsi786bc6gmkp185mwri3r5y249gjmqd5qsc23nnfhgrs1"))))
8610 (build-system python-build-system)
8611 (arguments
8612 `(#:python ,python-2))
8613 (inputs
8614 (list python2-pygame))
8615 (home-page "https://github.com/ryanakca/slingshot")
8616 (synopsis "Simple 2D shooting strategy game set in space")
8617 (description "Slingshot is a two-dimensional strategy game where two
8618 players attempt to shoot one another through a section of space populated by
8619 planets. The main feature of the game is that the shots, once fired, are
8620 affected by the gravity of the planets.")
8621 (license license:gpl2+)))
8622
8623 (define-public 4dtris
8624 (package
8625 (name "4dtris")
8626 (version "0.4.3")
8627 (source
8628 (origin
8629 (method url-fetch)
8630 (uri (string-append "https://launchpad.net/4dtris/"
8631 (version-major+minor version)
8632 "/" version "/+download/4dtris_"
8633 version ".orig.tar.gz"))
8634 (sha256
8635 (base32
8636 "1nfkhcm0l89jyw8yr65na97g4l385zhjf7whkyg47c3v5sdqq2g7"))))
8637 (build-system gnu-build-system)
8638 (arguments
8639 `(#:configure-flags '("CFLAGS=-fcommon")
8640 #:phases
8641 (modify-phases %standard-phases
8642 (add-after 'unpack 'fix-install-directories
8643 (lambda* (#:key outputs #:allow-other-keys)
8644 (let ((out (assoc-ref outputs "out")))
8645 (substitute* "Makefile.in"
8646 (("bindir = /usr/games")
8647 (string-append "bindir = " out "/bin"))
8648 (("/usr/share/applications")
8649 (string-append out "/share/applications"))
8650 (("/usr/share/games/4dtris")
8651 (string-append out "/share/4dtris"))))
8652 #t))
8653 (add-after 'set-paths 'set-sdl-paths
8654 (lambda* (#:key inputs #:allow-other-keys)
8655 (setenv "CPATH"
8656 (string-append
8657 (search-input-directory inputs "/include/SDL")
8658 ":" (or (getenv "CPATH") ""))))))))
8659 (inputs
8660 `(("fontconfig" ,fontconfig)
8661 ("freeglut" ,freeglut)
8662 ("sdl" ,(sdl-union (list sdl sdl-ttf)))))
8663 (home-page "https://launchpad.net/4dtris/")
8664 (synopsis "4D Tetris")
8665 (description "4D-TRIS is an alteration of the well-known Tetris game. The
8666 game field is extended to 4D space, which has to filled up by the gamer with
8667 4D hyper cubes.")
8668 (license license:gpl3)))
8669
8670 (define-public arx-libertatis
8671 (package
8672 (name "arx-libertatis")
8673 (version "1.2")
8674 (source
8675 (origin
8676 (method url-fetch)
8677 (uri (string-append "http://arx-libertatis.org/files/arx-libertatis-"
8678 version ".tar.xz"))
8679 (sha256
8680 (base32
8681 "035dflxffa98bxmxkrqfizmhvnr09wyhhmzaqxk92772qil7gkxs"))))
8682 (build-system cmake-build-system)
8683 (outputs '("out" "installer"))
8684 (arguments
8685 '(#:tests? #f ; No tests.
8686 #:phases
8687 (modify-phases %standard-phases
8688 (add-after 'unpack 'fix-install-helper-paths
8689 (lambda* (#:key inputs #:allow-other-keys)
8690 (let ((p7zip (assoc-ref inputs "p7zip"))
8691 (innoextract (assoc-ref inputs "innoextract"))
8692 (wget (assoc-ref inputs "wget"))
8693 (zenity (assoc-ref inputs "zenity")))
8694 (substitute* "scripts/arx-install-data"
8695 (("have innoextract")
8696 (string-append "have " innoextract "/bin/innoextract"))
8697 (("then innoextract")
8698 (string-append "then " innoextract "/bin/innoextract"))
8699 (("else innoextract")
8700 (string-append "else " innoextract "/bin/innoextract"))
8701 (("for _extract_zip_sz in 7za 7z")
8702 (string-append "for _extract_zip_sz in " p7zip "/bin/7za"))
8703 (("else if have 7z")
8704 (string-append "else if have " p7zip "/bin/7za"))
8705 (("7z x -tiso")
8706 (string-append p7zip "/bin/7z x -tiso"))
8707 (("if have wget")
8708 (string-append "if have " wget "/bin/wget"))
8709 (("wget -O")
8710 (string-append wget "/bin/wget -O"))
8711 (("for backend in \\$preferred zenity")
8712 (string-append "for backend in $preferred " zenity "/bin/zenity"))
8713 (("zenity +--title")
8714 (string-append zenity "/bin/zenity --title"))
8715 (("^zenity\\)")
8716 (string-append zenity "/bin/zenity)"))))
8717 #t))
8718 (add-after 'install 'move-installer
8719 (lambda* (#:key outputs #:allow-other-keys)
8720 (let ((out (assoc-ref outputs "out"))
8721 (installer (assoc-ref outputs "installer")))
8722 (mkdir-p (string-append installer "/bin"))
8723 (rename-file (string-append out "/bin/arx-install-data")
8724 (string-append installer "/bin/arx-install-data"))))))))
8725 (inputs
8726 (list sdl2
8727 libepoxy
8728 glew
8729 openal
8730 zlib
8731 boost
8732 glm
8733 freetype
8734 ;; The following are only needed by the arx-install-data script.
8735 p7zip ; Install-helper uses it to extract ISO and .cab archives.
8736 zenity ; GUI for install-helper.
8737 wget ; Used by the install-helper to download the patch.
8738 ;; The install-helper needs it to extract the patch.
8739 innoextract))
8740 (home-page "https://arx-libertatis.org/")
8741 (synopsis "Port of Arx Fatalis, a first-person role-playing game")
8742 (description "Arx Libertatis is a cross-platform port of Arx Fatalis, a 2002
8743 first-person role-playing game / dungeon crawler developed by Arkane Studios.
8744 This port however does not include the game data, so you need to obtain a copy
8745 of the original Arx Fatalis or its demo to play Arx Libertatis. Arx Fatalis
8746 features crafting, melee and ranged combat, as well as a unique casting system
8747 where the player draws runes in real time to effect the desired spell.")
8748 (license license:gpl3+)))
8749
8750 (define-public edgar
8751 (package
8752 (name "edgar")
8753 (version "1.34")
8754 (source
8755 (origin
8756 (method url-fetch)
8757 (uri
8758 (string-append "https://github.com/riksweeney/edgar/releases/download/"
8759 version "/edgar-" version "-1.tar.gz"))
8760 (sha256
8761 (base32 "1121rq5wk3g8rs413av84s2kcy6qj6maspgy2vsxs36c2jd3yygl"))))
8762 (build-system gnu-build-system)
8763 (arguments '(#:tests? #f ; there are no tests
8764 #:make-flags
8765 (list "CC=gcc"
8766 (string-append "PREFIX=" (assoc-ref %outputs "out"))
8767 (string-append "BIN_DIR=" (assoc-ref %outputs "out") "/bin/"))
8768 #:phases
8769 (modify-phases %standard-phases
8770 (delete 'configure)
8771 (add-before 'build 'fix-env
8772 (lambda* (#:key inputs #:allow-other-keys)
8773 (setenv "CPATH"
8774 (string-append
8775 (search-input-directory inputs "/include/SDL2")
8776 ":" (or (getenv "CPATH") ""))))))))
8777 (inputs
8778 `(("sdl2-union" ,(sdl-union (list sdl2 sdl2-image sdl2-mixer sdl2-ttf)))
8779 ("zlib" ,zlib)))
8780 (native-inputs
8781 `(("pkg-config" ,pkg-config)
8782 ("autoconf" ,autoconf)
8783 ("automake" ,automake)
8784 ("gnu-gettext" ,gettext-minimal)
8785 ("libtool" ,libtool)
8786 ("which" ,which)))
8787 (synopsis "2d action platformer game")
8788 (description "The Legend of Edgar is a 2D platform game with a persistent world.
8789 When Edgar's father fails to return home after venturing out one dark and stormy night,
8790 Edgar fears the worst: he has been captured by the evil sorcerer who lives in
8791 a fortress beyond the forbidden swamp.")
8792 (home-page "https://www.parallelrealities.co.uk/games/edgar/")
8793 (license license:gpl2+)))
8794
8795 (define-public openclonk
8796 (package
8797 (name "openclonk")
8798 (version "8.1")
8799 (source (origin
8800 (method url-fetch)
8801 (uri (string-append
8802 "https://www.openclonk.org/builds/release/" version "/"
8803 "openclonk-" version "-src.tar.bz2"))
8804 (sha256
8805 (base32
8806 "0imkqjp8lww5p0cnqf4k4mb2v682mnsas63qmiz17rspakr7fxik"))))
8807 (build-system cmake-build-system)
8808 (arguments
8809 `(#:configure-flags '("-DAudio_TK=OpenAL")
8810 #:test-target "tests"
8811 #:phases
8812 (modify-phases %standard-phases
8813 (add-after 'unpack 'prepare-gmock
8814 (lambda* (#:key inputs #:allow-other-keys)
8815 (mkdir "gmock")
8816 (copy-recursively (assoc-ref inputs "googlemock") "gmock")
8817 (substitute* "tests/CMakeLists.txt"
8818 (("/usr/src/gmock")
8819 (string-append (getcwd) "/gmock/googlemock"))
8820 (("/usr/src/gtest")
8821 (string-append (getcwd) "/gmock/googletest"))
8822 (("PATH_SUFFIXES \"src\" \"gtest\"")
8823 "PATH_SUFFIXES \"src\""))
8824 #t))
8825 (add-after 'unpack 'adjust-backward-cpp-includes
8826 (lambda _
8827 ;; XXX: The bundled backward-cpp exports a CMake "interface"
8828 ;; that includes external libraries such as libdl from glibc.
8829 ;; By default, CMake interface includes are treated as "system
8830 ;; headers", and GCC behaves poorly when glibc is passed as a
8831 ;; system header (causing #include_next failures).
8832
8833 ;; Here we prevent targets that consume the Backward::Backward
8834 ;; interface from treating it as "system includes".
8835 (substitute* "CMakeLists.txt"
8836 (("target_link_libraries\\((.+) Backward::Backward\\)" all target)
8837 (string-append "set_property(TARGET " target " PROPERTY "
8838 "NO_SYSTEM_FROM_IMPORTED true)\n"
8839 all)))
8840 #t))
8841 (add-after 'unpack 'add-libiberty
8842 ;; Build fails upon linking executables without this.
8843 (lambda _
8844 (substitute* "thirdparty/backward-cpp/BackwardConfig.cmake"
8845 (("set\\(LIBBFD_LIBRARIES (.*?)\\)" _ libraries)
8846 (string-append "set(LIBBFD_LIBRARIES " libraries " iberty)")))
8847 #t))
8848 (add-after 'add-libiberty 'lax-freealut-requirement
8849 ;; TODO: We provide freealut 1.1.0, but pkg-config somehow detects
8850 ;; it as 1.0.1. Force minimal version.
8851 (lambda _
8852 (substitute* "cmake/FindAudio.cmake"
8853 (("freealut>=1.1.0") "freealut>=1.0.1"))
8854 #t))
8855 (add-after 'lax-freealut-requirement 'fix-directories
8856 ;; Prefer "$out/share/openclonk" over
8857 ;; "$out/share/games/openclonk". Also install "openclonk"
8858 ;; binary in "bin/", not "games/".
8859 (lambda _
8860 (substitute* "CMakeLists.txt"
8861 (("share/games/openclonk") "share/openclonk")
8862 (("TARGETS openclonk DESTINATION games")
8863 "TARGETS openclonk DESTINATION bin"))
8864 #t)))))
8865 (native-inputs
8866 `(("googlemock" ,(package-source googletest))
8867 ("googletest" ,googletest)
8868 ("pkg-config" ,pkg-config)))
8869 (inputs
8870 `(("freealut" ,freealut)
8871 ("freetype" ,freetype)
8872 ("glew" ,glew)
8873 ("libiberty" ,libiberty)
8874 ("libjpeg" ,libjpeg-turbo)
8875 ("libogg" ,libogg)
8876 ("libpng" ,libpng)
8877 ("libvorbis" ,libvorbis)
8878 ("libxrandr" ,libxrandr)
8879 ("mesa" ,mesa)
8880 ("miniupnpc" ,miniupnpc)
8881 ("openal" ,openal)
8882 ("qtbase" ,qtbase-5)
8883 ("readline" ,readline)
8884 ("sdl" ,sdl2)
8885 ("tinyxml" ,tinyxml)
8886 ("zlib" ,zlib)))
8887 (home-page "https://www.openclonk.org/")
8888 (synopsis
8889 "Multiplayer action game where you control small and nimble humanoids")
8890 (description "OpenClonk is a multiplayer action/tactics/skill game. It is
8891 often referred to as a mixture of The Settlers and Worms. In a simple 2D
8892 antfarm-style landscape, the player controls a crew of Clonks, small but
8893 robust humanoid beings. The game encourages free play but the normal goal is
8894 to either exploit valuable resources from the earth by building a mine or
8895 fight each other on an arena-like map.")
8896 ;; Software as a whole is licensed under ISC, artwork under CC-BY.
8897 (license (list license:isc license:cc-by3.0))))
8898
8899 (define-public flare-engine
8900 (package
8901 (name "flare-engine")
8902 (version "1.12")
8903 (source (origin
8904 (method git-fetch)
8905 (uri (git-reference
8906 (url "https://github.com/flareteam/flare-engine")
8907 (commit (string-append "v" version))))
8908 (file-name (git-file-name name version))
8909 (sha256
8910 (base32
8911 "0h4xxj6r194pw68m3ngrnzkh6xgiblyrsc54z8abwba8m0mqbvmk"))))
8912 (build-system cmake-build-system)
8913 (arguments
8914 `(#:tests? #f ;no test
8915 #:configure-flags '("-DBINDIR=bin" "-DDATADIR=share/flare")))
8916 (inputs
8917 `(("hicolor-icon-theme" ,hicolor-icon-theme)
8918 ("python" ,python-wrapper)
8919 ("sdl" ,(sdl-union (list sdl2 sdl2-image sdl2-mixer sdl2-ttf)))))
8920 (home-page "http://www.flarerpg.org/")
8921 (synopsis "Action Roleplaying Engine")
8922 (description "Flare (Free Libre Action Roleplaying Engine) is a simple
8923 game engine built to handle a very specific kind of game: single-player 2D
8924 action RPGs.")
8925 (license license:gpl3+)))
8926
8927 (define-public flare-game
8928 (package
8929 (name "flare-game")
8930 (version "1.12")
8931 (source (origin
8932 (method git-fetch)
8933 (uri (git-reference
8934 (url "https://github.com/flareteam/flare-game")
8935 (commit (string-append "v" version))))
8936 (file-name (git-file-name name version))
8937 (sha256
8938 (base32
8939 "0h9i128kq6disppbrplkf13zdmsg4cq23nim53mgwpawc4mqz7ga"))))
8940 (build-system cmake-build-system)
8941 (arguments
8942 `(#:tests? #f ;no test
8943 #:configure-flags '("-DDATADIR=share/flare")
8944 #:phases
8945 (modify-phases %standard-phases
8946 ;; Flare expects the mods to be located in the same folder.
8947 ;; Yet, "default" mod is in the engine, whereas the others
8948 ;; are in the current package. Merge everything here with
8949 ;; a symlink.
8950 (add-after 'install 'add-default-mod
8951 (lambda* (#:key inputs outputs #:allow-other-keys)
8952 (let* ((out (assoc-ref outputs "out"))
8953 (mods (string-append out "/share/flare/mods")))
8954 (with-directory-excursion mods
8955 (symlink (string-append (assoc-ref inputs "flare-engine")
8956 "/share/flare/mods/default")
8957 "default")))
8958 #t))
8959 (add-after 'install 'install-executable
8960 ;; The package only provides assets for the game, the
8961 ;; executable coming from "flare-engine". Since more than
8962 ;; one game may use the engine, we create a new executable,
8963 ;; "flare-game", which launches the engine with appropriate
8964 ;; parameters.
8965 (lambda* (#:key inputs outputs #:allow-other-keys)
8966 (let* ((out (assoc-ref outputs "out"))
8967 (bash (search-input-file inputs "/bin/bash"))
8968 (flare (search-input-file inputs "/bin/flare"))
8969 (script (string-append out "/bin/flare-game")))
8970 (mkdir-p (dirname script))
8971 (call-with-output-file script
8972 (lambda (port)
8973 (format port
8974 "#!~a
8975 exec ~a --data-path=~a/share/flare --mods=empyrean_campaign~%"
8976 bash
8977 flare
8978 out)))
8979 (chmod script #o755))
8980 #t)))))
8981 (inputs
8982 (list flare-engine))
8983 (home-page "http://www.flarerpg.org/")
8984 (synopsis "Fantasy action RPG using the FLARE engine")
8985 (description "Flare is a single-player 2D action RPG with
8986 fast-paced action and a dark fantasy style.")
8987 (license license:cc-by-sa3.0)))
8988
8989 (define-public meritous
8990 (package
8991 (name "meritous")
8992 (version "1.5")
8993 (source (origin
8994 (method git-fetch)
8995 (uri (git-reference
8996 (url "https://gitlab.com/meritous/meritous.git")
8997 (commit (string-append "v" version))))
8998 (file-name (git-file-name name version))
8999 (sha256
9000 (base32
9001 "0n5jm4g0arjllgqmd2crv8h02i6hs3hlh1zyc7ng7yfpg1mbd8p8"))))
9002 (build-system gnu-build-system)
9003 (arguments
9004 `(#:tests? #f ;no test
9005 #:make-flags
9006 (list "CC=gcc"
9007 (string-append "prefix=" (assoc-ref %outputs "out")))
9008 #:phases
9009 (modify-phases %standard-phases
9010 (delete 'configure)
9011 (add-after 'unpack 'fix-sdl-path
9012 ;; XXX: For some reason, `sdl-config' reports stand-alone SDL
9013 ;; directory, not SDL-union provided as an input to the package.
9014 ;; We force the latter with "--prefix=" option.
9015 (lambda* (#:key inputs #:allow-other-keys)
9016 (substitute* "Makefile"
9017 (("sdl-config" command)
9018 (string-append command " --prefix=" (assoc-ref inputs "sdl"))))
9019 #t))
9020 (add-after 'unpack 'fix-crash
9021 ;; XXX: Songs are not present in the repository, due to licensing
9022 ;; issues. Yet, the game tries to load them, and, since it cannot
9023 ;; find them, crashes. Users cannot add them back, the store being
9024 ;; read-only, so we turn off background music altogether.
9025 (lambda _
9026 (substitute* "src/audio.c"
9027 (("PlayBackgroundMusic\\(new_track\\);" all)
9028 (string-append "// " all)))
9029 #t)))))
9030 (native-inputs
9031 (list intltool))
9032 (inputs
9033 `(("sdl" ,(sdl-union (list sdl sdl-image sdl-mixer)))
9034 ("zlib" ,zlib)))
9035 (home-page "https://gitlab.com/meritous/meritous")
9036 (synopsis "Action-adventure dungeon crawl game")
9037 (description "Far below the surface of the planet is a place of limitless
9038 power. Those that seek to control such a utopia will soon bring an end to
9039 themselves. Seeking an end to the troubles that plague him, PSI user Merit
9040 journeys into the hallowed Orcus Dome in search of answers.
9041
9042 Meritous is a action-adventure game with simple controls but a challenge to
9043 find a balance of power versus recovery time during real-time battles. Set in
9044 a procedurally generated world, the player can explore thousands of rooms in
9045 search of powerful artifacts, tools to help them, and to eventually free the
9046 Orcus Dome from evil.")
9047 (license license:gpl3+)))
9048
9049 (define-public marble-marcher
9050 (let ((commit "e580460a0c3826f9b28ab404607942a8ecb625d7")
9051 (revision "1"))
9052 (package
9053 (name "marble-marcher")
9054 (version (git-version "0" revision commit))
9055 (source (origin
9056 (method git-fetch)
9057 (uri (git-reference
9058 (url "https://github.com/HackerPoet/MarbleMarcher")
9059 (commit commit)))
9060 (file-name (git-file-name name version))
9061 (sha256
9062 (base32
9063 "0jjv832hl1v170n6gryp2sr3lgqndi9ab841qvgqk68bks8701mx"))))
9064 (build-system cmake-build-system)
9065 (arguments
9066 `(#:tests? #f ; there are none
9067 #:phases
9068 (modify-phases %standard-phases
9069 (add-after 'unpack 'embed-asset-directory
9070 (lambda* (#:key outputs #:allow-other-keys)
9071 (let ((assets (string-append (assoc-ref outputs "out")
9072 "/share/marble-marcher/assets/")))
9073 ;; Some of the files we're patching are
9074 ;; ISO-8859-1-encoded, so choose it as the default
9075 ;; encoding so the byte encoding is preserved.
9076 (with-fluids ((%default-port-encoding #f))
9077 (substitute* "src/Resource.rc"
9078 (("../assets/icon.ico")
9079 (string-append assets "icon.ico")))
9080 (substitute* "src/Res.h"
9081 (("assets/") assets))))
9082 #t))
9083 (replace 'install
9084 (lambda* (#:key outputs #:allow-other-keys)
9085 (let* ((out (assoc-ref outputs "out"))
9086 (assets (string-append out "/share/marble-marcher/assets"))
9087 (bin (string-append out "/bin/")))
9088 (mkdir-p bin)
9089 (mkdir-p assets)
9090 (copy-recursively "../source/assets" assets)
9091 (install-file "MarbleMarcher" bin))
9092 #t)))))
9093 (inputs
9094 (list eigen mesa sfml))
9095 (native-inputs
9096 (list pkg-config))
9097 (home-page "https://codeparade.itch.io/marblemarcher")
9098 (synopsis "Guide a marble across fractal landscapes")
9099 (description "Marble Marcher is a video game that uses a fractal physics
9100 engine and fully procedural rendering to produce beautiful and unique
9101 gameplay. The game is played on the surface of evolving fractals. The goal
9102 of the game is to get your marble to the flag as quickly as possible. But be
9103 careful not to fall off the level or get crushed by the fractal! There are 24
9104 levels to unlock.")
9105 ;; Code is under GPLv2+, assets are under CC-BY-SA 3.0 and OFL 1.1.
9106 (license (list license:gpl2+
9107 license:silofl1.1
9108 license:cc-by-sa3.0)))))
9109
9110 ;; This must be updated together with flightgear.
9111 (define simgear
9112 (package
9113 (name "simgear")
9114 (version "2020.3.11")
9115 (source
9116 (origin
9117 (method url-fetch)
9118 (uri (string-append "mirror://sourceforge/flightgear/release-"
9119 (version-major+minor version) "/"
9120 "simgear-" version ".tar.bz2"))
9121 (sha256
9122 (base32 "0g2g3n3sb6kdimvcrn9kvlhyyrp5c6lx20fgzz8l609v5aygr3dv"))
9123 (modules '((guix build utils)))
9124 (snippet
9125 '(begin
9126 ;; There are some bundled libraries.
9127 (for-each delete-file-recursively
9128 '("3rdparty/expat/"))
9129 #t))))
9130 (build-system cmake-build-system)
9131 (arguments
9132 `(#:configure-flags (list "-DSYSTEM_EXPAT=ON")
9133 #:phases
9134 (modify-phases %standard-phases
9135 (replace 'check
9136 (lambda* (#:key tests? #:allow-other-keys)
9137 (when tests?
9138 ;; Skip tests that require internet access.
9139 (invoke "ctest" "-E" "(http|dns)")))))))
9140 (inputs
9141 `(("boost" ,boost)
9142 ("curl" ,curl)
9143 ("expat" ,expat)
9144 ("mesa" ,mesa)
9145 ("openal" ,openal)
9146 ("openscenegraph" ,openscenegraph)
9147 ("zlib" ,zlib)))
9148 (home-page "https://home.flightgear.org/")
9149 (synopsis "Libraries for 3D simulations and games")
9150 (description "SimGear is a set of libraries designed to be used as
9151 building blocks for quickly assembling 3D simulations, games, and
9152 visualization applications. SimGear is developed by the FlightGear project
9153 and also provides the base for the FlightGear Flight Simulator.")
9154 (license license:lgpl2.0+)))
9155
9156 (define-public flightgear
9157 (package
9158 (name "flightgear")
9159 (version (package-version simgear))
9160 (source
9161 (origin
9162 (method url-fetch)
9163 (uri (string-append "mirror://sourceforge/flightgear/release-"
9164 (version-major+minor version) "/"
9165 "flightgear-" version ".tar.bz2"))
9166 (sha256
9167 (base32 "15sar94x13j2y1m6adgmz2q1m1i9bzj3sxqla6y3m9vyf33hc9zy"))
9168 (modules '((guix build utils)))
9169 (snippet
9170 '(begin
9171 ;; There are some bundled libraries.
9172 (for-each delete-file-recursively
9173 '("3rdparty/sqlite3/"
9174 "3rdparty/cppunit/"))
9175 #t))))
9176 (build-system qt-build-system)
9177 (arguments
9178 `(#:configure-flags
9179 (list "-DSYSTEM_SQLITE=ON"
9180 "-DSYSTEM_CPPUNIT=ON"
9181 (string-append "-DFG_DATA_DIR="
9182 (assoc-ref %outputs "out")
9183 "/share/flightgear"))
9184 ;; TODO: test suite segfaults.
9185 #:tests? #f
9186 #:phases
9187 (modify-phases %standard-phases
9188 (add-after 'unpack 'skip-some-tests
9189 (lambda _
9190 (substitute* "test_suite/unit_tests/Instrumentation/test_gps.hxx"
9191 (("CPPUNIT_TEST\\(testLongLegWestbound\\);" all)
9192 (string-append "// " all))
9193 (("CPPUNIT_TEST\\(testFinalLegCourse\\);" all)
9194 (string-append "// " all)))))
9195 (add-after 'build 'build-test-suite
9196 (lambda* args
9197 ((assoc-ref %standard-phases 'build)
9198 #:make-flags (list "fgfs_test_suite"))))
9199 ;; Test suite needs access to FGData so run it after 'install.
9200 (delete 'check)
9201 (add-after 'install-data 'check
9202 (assoc-ref %standard-phases 'check))
9203 (add-after 'install 'install-data
9204 (lambda* (#:key inputs outputs #:allow-other-keys)
9205 (let ((share (string-append (assoc-ref outputs "out") "/share/flightgear")))
9206 (mkdir-p share)
9207 (with-directory-excursion share
9208 (invoke "tar" "xf" (assoc-ref inputs "flightgear-data")
9209 "--strip-components=1")))
9210 #t)))))
9211 (inputs
9212 (list boost
9213 dbus
9214 eudev
9215 freeglut
9216 freetype
9217 glew
9218 libpng
9219 openal
9220 openscenegraph
9221 plib
9222 qtbase-5
9223 qtdeclarative
9224 qtsvg
9225 simgear
9226 speexdsp
9227 sqlite
9228 zlib))
9229 (native-inputs
9230 `(("cppunit" ,cppunit)
9231 ("pkg-config" ,pkg-config)
9232 ("qttools" ,qttools)
9233 ("flightgear-data"
9234 ,(origin
9235 (method url-fetch)
9236 (uri (string-append "mirror://sourceforge/flightgear/release-"
9237 (version-major+minor version) "/"
9238 "FlightGear-" version "-data.txz"))
9239 (sha256
9240 (base32
9241 "0n5mw9vw1snab16c1y3i9ylkiv54az57bs2mvpq20hhg5hdiagqj"))))))
9242 (home-page "https://www.flightgear.org/")
9243 (synopsis "Flight simulator")
9244 (description "The goal of the FlightGear project is to create a
9245 sophisticated flight simulator framework for use in research or academic
9246 environments, pilot training, as an industry engineering tool, for DIY-ers to
9247 pursue their favorite interesting flight simulation idea, and last but
9248 certainly not least as a fun, realistic, and challenging desktop flight
9249 simulator.")
9250 (license license:gpl2+)))
9251
9252 (define-public jumpnbump
9253 (package
9254 (name "jumpnbump")
9255 (version "1.61")
9256 (source (origin
9257 (method git-fetch)
9258 (uri (git-reference
9259 (url "https://gitlab.com/LibreGames/jumpnbump.git")
9260 (commit version)))
9261 (file-name (git-file-name name version))
9262 (sha256
9263 (base32
9264 "12lwl5sl5n009nb83r8l4lakb9286csqdf1ynpmwwydy17giqsdp"))))
9265 (build-system gnu-build-system)
9266 (arguments
9267 `(#:make-flags
9268 (list "CC=gcc"
9269 (string-append "PREFIX=" (assoc-ref %outputs "out")))
9270 #:tests? #f ;no test
9271 #:phases
9272 (modify-phases %standard-phases
9273 ;; There is no configure script
9274 (replace 'configure
9275 (lambda _
9276 (substitute* "Makefile"
9277 (("-funroll-loops")
9278 "-funroll-loops -fcommon")
9279 (("SDL_CFLAGS =")
9280 "SDL_CFLAGS = -fcommon"))))
9281 (add-after 'unpack 'fix-sdl-path
9282 ;; XXX: For some reason, `sdl2-config' reports stand-alone SDL
9283 ;; directory, not SDL-union provided as an input to the package.
9284 ;; We force the latter with "--prefix=" option.
9285 (lambda* (#:key inputs #:allow-other-keys)
9286 (substitute* "Makefile"
9287 (("sdl2-config" command)
9288 (string-append command " --prefix=" (assoc-ref inputs "sdl")))))))))
9289 (inputs
9290 `(("bzip2" ,bzip2)
9291 ("sdl" ,(sdl-union (list sdl2 sdl2-mixer sdl2-net)))
9292 ("zlib" ,zlib)))
9293 (native-inputs
9294 `(("gettext" ,gettext-minimal))) ;for msgfmt
9295 (home-page "https://gitlab.com/LibreGames/jumpnbump")
9296 (synopsis "Multiplayer platform game with bunnies")
9297 (description "You, as a bunny, have to jump on your opponents to make them
9298 explode. It is a true multiplayer game; you cannot play this alone. You can
9299 play with up to four players simultaneously. It has network support.")
9300 (license license:gpl2+)))
9301
9302 (define-public hedgewars
9303 (package
9304 (name "hedgewars")
9305 (version "1.0.0")
9306 (source (origin
9307 (method url-fetch)
9308 (uri (string-append "https://www.hedgewars.org/download/releases/"
9309 "hedgewars-src-" version ".tar.bz2"))
9310 (patches (search-patches "hedgewars-network-bsd.patch"))
9311 (sha256
9312 (base32
9313 "0nqm9w02m0xkndlsj6ys3wr0ik8zc14zgilq7k6fwjrf3zk385i1"))))
9314 (build-system cmake-build-system)
9315 (arguments
9316 ;; XXX: Engine is built as Pascal source code, requiring Free Pascal
9317 ;; Compiler, which we haven't packaged yet. With the flag below, we use
9318 ;; a Pascal to C translator and Clang instead.
9319 `(#:configure-flags (list "-DBUILD_ENGINE_C=ON"
9320 "-Dhaskell_flags=-dynamic;-fPIC")
9321 #:phases
9322 (modify-phases %standard-phases
9323 (add-before 'configure 'fix-sources
9324 (lambda _
9325 ;; Fix a missing 'include'.
9326 (substitute* "QTfrontend/ui/page/pagegamestats.cpp"
9327 (("#include <QSizePolicy>")
9328 "#include <QSizePolicy>\n#include <QPainterPath>"))))
9329 (replace 'check
9330 (lambda _ (invoke "ctest")))
9331 (add-after 'install 'install-icon
9332 (lambda _
9333 ;; Install icon for the desktop file.
9334 (let* ((out (assoc-ref %outputs "out"))
9335 (icons (string-append out "/share/icons/hicolor/512x512/apps")))
9336 (with-directory-excursion (string-append "../hedgewars-src-" ,version)
9337 (install-file "misc/hedgewars.png" icons)))
9338 #t)))))
9339 (inputs
9340 `(("ffmpeg" ,ffmpeg)
9341 ("freeglut" ,freeglut)
9342 ("ghc-entropy" ,ghc-entropy)
9343 ("ghc-hslogger" ,ghc-hslogger)
9344 ("ghc-network" ,ghc-network)
9345 ("ghc-random" ,ghc-random)
9346 ("ghc-regex-tdfa" ,ghc-regex-tdfa)
9347 ("ghc-sandi" ,ghc-sandi)
9348 ("ghc-sha" ,ghc-sha)
9349 ("ghc-utf8-string" ,ghc-utf8-string)
9350 ("ghc-vector" ,ghc-vector)
9351 ("ghc-zlib" ,ghc-zlib)
9352 ("glew" ,glew)
9353 ("libpng" ,libpng)
9354 ("lua" ,lua-5.1)
9355 ("physfs" ,physfs)
9356 ("qtbase" ,qtbase-5)
9357 ("sdl" ,(sdl-union
9358 (list sdl2 sdl2-mixer sdl2-net sdl2-ttf sdl2-image)))))
9359 (native-inputs
9360 (list clang ghc pkg-config qttools))
9361 (home-page "https://hedgewars.org/")
9362 (synopsis "Turn-based artillery game featuring fighting hedgehogs")
9363 (description
9364 "Hedgewars is a turn based strategy, artillery, action and comedy game,
9365 featuring the antics of pink hedgehogs with attitude as they battle from the
9366 depths of hell to the depths of space.
9367
9368 As commander, it's your job to assemble your crack team of hedgehog soldiers
9369 and bring the war to your enemy.")
9370 ;; Software as a whole is licensed under GPL-2 terms. Artwork and
9371 ;; scripts are distributed under various terms.
9372 (license (list license:gpl2
9373 license:bsd-2 license:bsd-3 license:cc-by3.0 license:cc0
9374 license:expat license:fdl1.3+ license:public-domain
9375 license:zlib))))
9376
9377 (define-public go-github-com-anaseto-gruid
9378 (package
9379 (name "go-github-com-anaseto-gruid")
9380 (version "0.21.1")
9381 (source
9382 (origin
9383 (method git-fetch)
9384 (uri (git-reference
9385 (url "https://github.com/anaseto/gruid")
9386 (commit (string-append "v" version))))
9387 (file-name (git-file-name name version))
9388 (sha256
9389 (base32
9390 "0rvsavkvg2hziwdh8sjk3n5v92m5mfjb8v9m7ch22maxfwq5kv6y"))))
9391 (build-system go-build-system)
9392 (arguments
9393 '(#:import-path "github.com/anaseto/gruid"))
9394 (propagated-inputs
9395 (list go-golang-org-x-image))
9396 (home-page "https://github.com/anaseto/gruid")
9397 (synopsis "Cross-platform grid-based UI and game framework")
9398 (description "The gruid module provides packages for easily building
9399 grid-based applications in Go. The library abstracts rendering and input for
9400 different platforms. There are drivers available for terminal apps, native
9401 graphical apps and browser apps. The original application for the library was
9402 creating grid-based games, but it's also well suited for any grid-based
9403 application.")
9404 (license license:isc)))
9405
9406 (define-public go-github-com-anaseto-gruid-tcell
9407 (package
9408 (name "go-github-com-anaseto-gruid-tcell")
9409 (version "0.1.1")
9410 (source
9411 (origin
9412 (method git-fetch)
9413 (uri (git-reference
9414 (url "https://github.com/anaseto/gruid-tcell")
9415 (commit (string-append "v" version))))
9416 (file-name (git-file-name name version))
9417 (sha256
9418 (base32
9419 "09ajr9mbldjfc44qprplbf8dr8yhlbn2nfnas2z62m9wmklc0qiv"))))
9420 (build-system go-build-system)
9421 (arguments
9422 '(#:import-path "github.com/anaseto/gruid-tcell"))
9423 (propagated-inputs
9424 `(("go-github-com-gdamore-tcell-v2" ,go-github-com-gdamore-tcell-v2)
9425 ("go-github-com-anaseto-gruid" ,go-github-com-anaseto-gruid)))
9426 (home-page "https://github.com/anaseto/gruid-tcell")
9427 (synopsis "Gruid driver using the tcell library")
9428 (description "The gruid-tcell module provides a Gruid driver for building
9429 terminal full-window applications.")
9430 (license license:isc)))
9431
9432 (define-public harmonist
9433 (package
9434 (name "harmonist")
9435 (version "0.4.1")
9436 (source (origin
9437 (method git-fetch)
9438 (uri (git-reference
9439 (url "https://git.tuxfamily.org/harmonist/harmonist.git")
9440 (commit (string-append "v" version))))
9441 (file-name (git-file-name name version))
9442 (sha256
9443 (base32
9444 "17ai39pw9xq4asfvhs0whx07hljlivygazbwrxjrnxwrn06483hr"))))
9445 (build-system go-build-system)
9446 (arguments
9447 '(#:import-path "git.tuxfamily.org/harmonist/harmonist"))
9448 (inputs
9449 `(("go-github-com-gdamore-tcell-v2" ,go-github-com-gdamore-tcell-v2)
9450 ("go-github.com-nsf-termbox-go" ,go-github.com-nsf-termbox-go)
9451 ("go-github-com-anaseto-gruid" ,go-github-com-anaseto-gruid)
9452 ("go-github-com-anaseto-gruid-tcell" ,go-github-com-anaseto-gruid-tcell)))
9453 (home-page "https://harmonist.tuxfamily.org/")
9454 (synopsis "Stealth coffee-break roguelike game")
9455 (description "Harmonist: Dayoriah Clan Infiltration is a stealth
9456 coffee-break roguelike game. The game has a heavy focus on tactical
9457 positioning, light and noise mechanisms, making use of various terrain types
9458 and cones of view for monsters. Aiming for a replayable streamlined experience,
9459 the game avoids complex inventory management and character building, relying
9460 on items and player adaptability for character progression.")
9461 (license license:isc)))
9462
9463 (define-public drascula
9464 (package
9465 (name "drascula")
9466 (version "1.0")
9467 (source (origin
9468 (method url-fetch)
9469 (uri (string-append "mirror://sourceforge/scummvm/extras/"
9470 "Drascula_%20The%20Vampire%20Strikes%20Back/"
9471 "drascula-" version ".zip"))
9472 (sha256
9473 (base32
9474 "1pj29rpb754sn6a56f8brfv6f2m1p5qgaqik7d68pfi2bb5zccdp"))))
9475 (build-system trivial-build-system)
9476 (arguments
9477 `(#:modules ((guix build utils))
9478 #:builder
9479 (begin
9480 (use-modules (guix build utils)
9481 (ice-9 match))
9482 (let* ((out (assoc-ref %outputs "out"))
9483 (share (string-append out "/share/drascula"))
9484 (scummvm (assoc-ref %build-inputs "scummvm")))
9485 ;; Install data.
9486 (let ((unzip (search-input-file %build-inputs "/bin/unzip"))
9487 (doc (string-append out "/share/doc/" ,name "-" ,version)))
9488 (for-each
9489 (lambda (input)
9490 (invoke unzip
9491 "-j"
9492 (assoc-ref %build-inputs input)
9493 "-x" "__MACOSX")
9494 ;; Every input provides "readme.txt", and we want to
9495 ;; preserve them all. Therefore we rename them first.
9496 (match input
9497 ("drascula-int"
9498 (rename-file "readme.txt" "readme-international.txt"))
9499 ("drascula-audio"
9500 (rename-file "readme.txt" "readme-audio.txt"))
9501 (_ #f))
9502 ;; Install documentation.
9503 (for-each (lambda (f) (install-file f doc))
9504 (find-files "." "\\.(txt|doc)$"))
9505 ;; Install data.
9506 (for-each (lambda (f) (install-file f share))
9507 (find-files "." "\\.(ogg|00[0-9])$")))
9508 '("drascula-audio" "drascula-int" "source")))
9509 ;; Create standalone executable.
9510 (let* ((bin (string-append out "/bin"))
9511 (executable (string-append bin "/drascula"))
9512 (bash (search-input-file %build-inputs "/bin/bash")))
9513 (mkdir-p bin)
9514 (with-output-to-file executable
9515 (lambda ()
9516 (format #t "#!~a~%" bash)
9517 (format #t
9518 "exec ~a/bin/scummvm --path=~a drascula~%"
9519 scummvm share)))
9520 (chmod executable #o755))
9521 ;; Create desktop file. There is no dedicated icon for the
9522 ;; game, so we borrow SCUMMVM's.
9523 (let ((apps (string-append out "/share/applications")))
9524 (mkdir-p apps)
9525 (make-desktop-entry-file
9526 (string-append apps "/drascula.desktop")
9527 #:name "Drascula: The Vampire Strikes Back"
9528 #:generic-name "Drascula"
9529 #:exec (string-append out "/bin/drascula")
9530 #:icon (string-append scummvm "/share/icons/hicolor/scalable/apps/scummvm.svg")
9531 #:categories '("AdventureGame" "Game" "RolePlaying")
9532 #:keywords '("game" "adventure" "roleplaying" "2D" "fantasy")
9533 #:comment '((#f "Classic 2D point and click adventure game")
9534 ("de" "Klassisches 2D-Abenteuerspiel in Zeigen-und-Klicken-Manier")
9535 ("fr" "Jeu classique d'aventure pointer-et-cliquer en 2D")
9536 ("it" "Gioco classico di avventura punta e clicca 2D"))))
9537 #t))))
9538 (native-inputs
9539 (list bash unzip))
9540 (inputs
9541 `(("scummvm" ,scummvm)
9542 ("drascula-int"
9543 ,(let ((version "1.1"))
9544 (origin
9545 (method url-fetch)
9546 (uri (string-append "mirror://sourceforge/scummvm/extras/"
9547 "Drascula_%20The%20Vampire%20Strikes%20Back/"
9548 "drascula-int-" version ".zip"))
9549 (sha256
9550 (base32
9551 "12236i7blamal92p1i8dgp3nhp2yicics4whsl63v682bj999n14")))))
9552 ("drascula-audio"
9553 ,(let ((version "2.0"))
9554 (origin
9555 (method url-fetch)
9556 (uri (string-append "mirror://sourceforge/scummvm/extras/"
9557 "Drascula_%20The%20Vampire%20Strikes%20Back/"
9558 "drascula-audio-" version ".zip"))
9559 (sha256
9560 (base32
9561 "00g4izmsqzxb8ry1vhfx6jrygl58lvlij09nw01ds4zddsiznsky")))))))
9562 (home-page "https://www.scummvm.org")
9563 (synopsis "Classic 2D point and click adventure game")
9564 (description "Drascula: The Vampire Strikes Back is a classic humorous 2D
9565 point and click adventure game.
9566
9567 In Drascula you play the role of John Hacker, a British estate agent, that
9568 gets to meet a gorgeous blond girl who is kidnapped by the notorious vampire
9569 Count Drascula and embark on a fun yet dangerous quest to rescue her.
9570 Unfortunately, Hacker is not aware of Drascula's real ambitions: DOMINATING
9571 the World and demonstrating that he is even more evil than his brother Vlad.")
9572 ;; Drascula uses a BSD-like license.
9573 (license (license:non-copyleft "file:///readme.txt"))))
9574
9575 (define (make-lure-package name language hash)
9576 (package
9577 (name name)
9578 (version "1.1")
9579 (source
9580 (origin
9581 (method url-fetch)
9582 (uri (string-append
9583 "mirror://sourceforge/scummvm/extras/"
9584 "Lure%20of%20the%20Temptress/"
9585 name "-" version ".zip"))
9586 (sha256
9587 (base32 hash))))
9588 (build-system trivial-build-system)
9589 (arguments
9590 `(#:modules ((guix build utils))
9591 #:builder
9592 (begin
9593 (use-modules (guix build utils))
9594 (let* ((out (assoc-ref %outputs "out"))
9595 (share (string-append out "/share"))
9596 (data (string-append share "/" ,name "/" ,language))
9597 (apps (string-append share "/applications"))
9598 (bin (string-append out "/bin"))
9599 (executable (string-append bin "/" ,name))
9600 (scummvm (assoc-ref %build-inputs "scummvm")))
9601 (let ((unzip (search-input-file %build-inputs "/bin/unzip")))
9602 (invoke unzip "-j" (assoc-ref %build-inputs "source")))
9603 (let ((doc (string-append share "/doc/" ,name "-" ,version)))
9604 (for-each (lambda (f) (install-file f doc))
9605 (find-files "." "\\.(txt|PDF|pdf)$")))
9606 (for-each (lambda (f) (install-file f data))
9607 (find-files "." "\\.(vga|VGA)$"))
9608 ;; Build the executable.
9609 (mkdir-p bin)
9610 (let ((bash (assoc-ref %build-inputs "bash")))
9611 (with-output-to-file executable
9612 (lambda ()
9613 (format #t "#!~a/bin/bash~%" bash)
9614 (format #t "exec ~a/bin/scummvm -q ~a -p ~a lure~%"
9615 scummvm ,language data))))
9616 (chmod executable #o755)
9617 ;; Create desktop file. There is no dedicated
9618 ;; icon for the game, so we borrow SCUMMVM's.
9619 (mkdir-p apps)
9620 (with-output-to-file (string-append apps "/" ,name ".desktop")
9621 (lambda _
9622 (format #t
9623 "[Desktop Entry]~@
9624 Name=Lure of the Temptress~@
9625 GenericName=Lure~@
9626 Exec=~a~@
9627 Icon=~a/share/icons/hicolor/scalable/apps/scummvm.svg~@
9628 Categories=AdventureGame;Game;RolePlaying;~@
9629 Keywords=game;adventure;roleplaying;2D,fantasy;~@
9630 Comment=Classic 2D point and click adventure game~@
9631 Comment[de]=klassisches 2D-Abenteuerspiel in Zeigen-und-Klicken-Manier~@
9632 Comment[fr]=Jeu classique d'aventure pointer-et-cliquer en 2D~@
9633 Comment[it]=Gioco classico di avventura punta e clicca 2D~@
9634 Type=Application~%"
9635 executable scummvm)))
9636 #t))))
9637 (native-inputs
9638 (list unzip))
9639 (inputs
9640 (list bash scummvm))
9641 (home-page "https://www.scummvm.org")
9642 (synopsis "2D point and click fantasy adventure game")
9643 (description
9644 "Lure of the Temptress is a classic 2D point and click adventure game.
9645
9646 You are Diermot, an unwilling hero who'd prefer a quiet life, and are, to all
9647 intents and purposes, a good man. After decades of unrest the King has united
9648 the warring factions in his kingdom and all his lands are at peace, except
9649 a remote region around a town called Turnvale. A revolt has recently taken
9650 place in Turnvale, a revolt orchestrated by an apprentice sorceress called
9651 Selena, the titular temptress. The king calls together his finest horsemen
9652 and heads off (with you in tow) to Turnvale just to witness how hellish
9653 mercenary monsters called Skorl are invading the town.
9654
9655 The king's men are defeated, the king is killed and you fall of your horse and
9656 bang your head heavily on the ground. You have been *unconscious for a while
9657 when you realize that you are in a dingy cell guarded by a not so friendly
9658 Skorl. Maybe it would be an idea to try and escape...")
9659 (license (license:non-copyleft "file:///README"))))
9660
9661 (define-public lure
9662 (make-lure-package
9663 "lure" "en" "0201i70qcs1m797kvxjx3ygkhg6kcl5yf49sihba2ga8l52q45zk"))
9664
9665 (define-public lure-de
9666 (make-lure-package
9667 "lure-de" "de" "0sqq7h5llml6rv85x0bfv4bgzwhs4c82p4w4zmfcaab6cjlad0sy"))
9668
9669 (define-public lure-es
9670 (make-lure-package
9671 "lure-es" "es" "1dvv5znvlsakw6w5r16calv9jkgw27aymgybsf4q22lcmpxbj1lk"))
9672
9673 (define-public lure-fr
9674 (make-lure-package
9675 "lure-fr" "fr" "1y51jjb7f8023832g44vd1jsb6ni85586pi2n5hjg9qjk6gi90r9"))
9676
9677 (define-public lure-it
9678 (make-lure-package
9679 "lure-it" "it" "1ks6n39r1cllisrrh6pcr39swsdv7ng3gx5c47vaw71zzfr70hjj"))
9680
9681 (define (make-queen-package name file-prefix release language hash)
9682 (package
9683 (name name)
9684 (version release)
9685 (source
9686 (origin
9687 (method url-fetch)
9688 (uri (string-append "mirror://sourceforge/scummvm/extras/"
9689 "Flight%20of%20the%20Amazon%20Queen/"
9690 file-prefix release ".zip"))
9691 (sha256
9692 (base32 hash))))
9693 (build-system trivial-build-system)
9694 (arguments
9695 `(#:modules ((guix build utils))
9696 #:builder
9697 (begin
9698 (use-modules (guix build utils))
9699 (let* ((out (assoc-ref %outputs "out"))
9700 (share (string-append out "/share"))
9701 (data (string-append share "/" ,name))
9702 (apps (string-append share "/applications"))
9703 (bin (string-append out "/bin"))
9704 (executable (string-append bin "/" ,name))
9705 (scummvm (assoc-ref %build-inputs "scummvm")))
9706 (let ((unzip (search-input-file %build-inputs "/bin/unzip")))
9707 (invoke unzip "-j" (assoc-ref %build-inputs "source")))
9708 (let ((doc (string-append share "/doc/" ,name "-" ,version)))
9709 (install-file "readme.txt" doc))
9710 (install-file "queen.1c" data)
9711 (mkdir-p bin)
9712 (let ((bash (assoc-ref %build-inputs "bash")))
9713 (with-output-to-file executable
9714 (lambda ()
9715 (format #t "#!~a/bin/bash~%" bash)
9716 (format #t "exec ~a/bin/scummvm -q fr -p ~a queen~%"
9717 scummvm data))))
9718 (chmod executable #o755)
9719 ;; Create desktop file. There is no dedicated
9720 ;; icon for the game, so we borrow SCUMMVM's.
9721 (mkdir-p apps)
9722 (with-output-to-file (string-append apps "/" ,name ".desktop")
9723 (lambda _
9724 (format #t
9725 "[Desktop Entry]~@
9726 Name=Flight of the Amazon Queen~@
9727 GenericName=Queen~@
9728 Comment=Embark on a quest to rescue a kidnapped princess and in the process, discover the true sinister intentions of a suspiciously located Lederhosen company~@
9729 Comment[de]=Begib dich auf ein Abenteuer, um eine entführte Prinzessin zu retten und entdecke die wahren, finsteren Absichten eines verdächtig erscheinenden Lederhosen-Unternehmens~@
9730 Type=Application~@
9731 Exec=~a~@
9732 Icon=~a/share/icons/hicolor/scalable/apps/scummvm.svg~@
9733 Categories=AdventureGame;Game;RolePlaying;~@
9734 Keywords=adventure;game;roleplaying;fantasy;~%"
9735 executable scummvm))))
9736 #t)))
9737 (native-inputs
9738 (list unzip))
9739 (inputs
9740 (list bash scummvm))
9741 (home-page "https://www.scummvm.org/")
9742 (synopsis "Classic 2D point and click adventure game")
9743 (description "Flight of the Amazon Queen is a 2D point-and-click
9744 adventure game set in the 1940s.
9745
9746 You assume the role of Joe King, a pilot for hire who is given the job
9747 of flying Faye Russell (a famous movie star) into the Amazon jungle
9748 for a photo shoot. Of course, things never go according to plans.
9749 After an unfortunate turn of events they find themselves stranded in
9750 the heart of the Amazon jungle, where Joe will embark on a quest to
9751 rescue a kidnapped princess and in the process, discover the true
9752 sinister intentions of a suspiciously located Lederhosen company. In
9753 a rich 2D environment, Joe will cross paths with a variety of unlikely
9754 jungle inhabitants including, but not limited to, a tribe of Amazon
9755 women and 6-foot-tall pygmies.")
9756 (license (license:non-copyleft "file:///readme.txt"))))
9757
9758 (define-public queen
9759 (make-queen-package
9760 "queen" "FOTAQ_Talkie-" "1.1" "en"
9761 "1a6q71q1dl9vvw2qqsxk5h1sv0gaqy6236zr5905w2is01gdsp52"))
9762
9763 (define-public queen-de
9764 (make-queen-package
9765 "queen-de" "FOTAQ_Ger_talkie-" "1.0" "de"
9766 "13vn43x7214vyprlpqabvv71k890nff3d6fjscflr1ll7acjca3f"))
9767
9768 (define-public queen-fr
9769 (make-queen-package
9770 "queen-fr" "FOTAQ_Fr_Talkie_" "1.0" "fr"
9771 "0hq5g4qrkcwm2kn5i4kv4hijs9hi7bw9xl1vrwd1l69qqn30crwy"))
9772
9773 (define-public queen-it
9774 (make-queen-package
9775 "queen-it" "FOTAQ_It_Talkie_" "1.0" "it"
9776 "1h76y70lrpzfjkm53n4nr364nhyka54vbz9r7sadzyzl7c7ilv4d"))
9777
9778 (define-public sky
9779 (package
9780 (name "sky")
9781 (version "1.2") ;1.3 is floppy version
9782 (source
9783 (origin
9784 (method url-fetch)
9785 (uri (string-append "mirror://sourceforge/scummvm/extras/"
9786 "Beneath%20a%20Steel%20Sky/"
9787 "bass-cd-" version ".zip"))
9788 (sha256
9789 (base32 "14s5jz67kavm8l15gfm5xb7pbpn8azrv460mlxzzvdpa02a9n82k"))))
9790 (build-system trivial-build-system)
9791 (arguments
9792 `(#:modules ((guix build utils))
9793 #:builder
9794 (begin
9795 (use-modules (guix build utils))
9796 (let* ((out (assoc-ref %outputs "out"))
9797 (share (string-append out "/share"))
9798 (data (string-append share "/" ,name))
9799 (apps (string-append share "/applications"))
9800 (bin (string-append out "/bin"))
9801 (executable (string-append bin "/" ,name))
9802 (scummvm (assoc-ref %build-inputs "scummvm")))
9803 (let ((unzip (search-input-file %build-inputs "/bin/unzip")))
9804 (invoke unzip "-j" (assoc-ref %build-inputs "source")))
9805 (let ((doc (string-append share "/doc/bass-" ,version)))
9806 (install-file "readme.txt" doc))
9807 (for-each (lambda (f) (install-file f data))
9808 (find-files "." "^sky\\."))
9809 ;; Build the executable.
9810 (mkdir-p bin)
9811 (let ((bash (assoc-ref %build-inputs "bash")))
9812 (with-output-to-file executable
9813 (lambda ()
9814 (format #t "#!~a/bin/bash~%" bash)
9815 (format #t "exec ~a/bin/scummvm -p ~a sky~%" scummvm data))))
9816 (chmod executable #o755)
9817 ;; Create desktop file. There is no dedicated
9818 ;; icon for the game, so we borrow SCUMMVM's.
9819 (mkdir-p apps)
9820 (with-output-to-file (string-append apps "/" ,name ".desktop")
9821 (lambda _
9822 (format #t
9823 "[Desktop Entry]~@
9824 Name=Beneath a Steel Sky~@
9825 GenericName=Bass~@
9826 Exec=~a~@
9827 Icon=~a/share/icons/hicolor/scalable/apps/scummvm.svg~@
9828 Categories=AdventureGame;Game;RolePlaying;~@
9829 Keywords=adventure;game;roleplaying;cyberpunk;~@
9830 Comment=A science-fiction adventure game set in a bleak post-apocalyptic vision of the future~@
9831 Comment[de]=Ein Science-Fiction-Abenteuerspiel \
9832 angesiedelt in einer düsteren, postapokalyptischen Vision der Zukunft~@
9833 Type=Application~%"
9834 executable scummvm)))
9835 #t))))
9836 (native-inputs
9837 (list unzip))
9838 (inputs
9839 (list bash scummvm))
9840 (home-page "https://www.scummvm.org/")
9841 (synopsis "Classic 2D point and click science-fiction adventure game")
9842 (description
9843 "Beneath a Steel Sky is a science-fiction thriller set in a bleak
9844 post-apocalyptic vision of the future. It revolves around Union City,
9845 where selfishness, rivalry, and corruption by its citizens seems to be
9846 all too common, those who can afford it live underground, away from
9847 the pollution and social problems which are plaguing the city.
9848
9849 You take on the role of Robert Foster, an outcast of sorts from the
9850 city since a boy who was raised in a remote environment outside of
9851 Union City simply termed ``the gap''. Robert's mother took him away
9852 from Union City as a child on their way to ``Hobart'' but the
9853 helicopter crashed on its way. Unfortunately, Robert's mother died,
9854 but he survived and was left to be raised by a local tribe from the
9855 gap.
9856
9857 Years later, Union City security drops by and abducts Robert, killing
9858 his tribe in the process; upon reaching the city the helicopter taking
9859 him there crashes with him escaping, high upon a tower block in the
9860 middle of the city. He sets out to discover the truth about his past,
9861 and to seek vengeance for the killing of his tribe.")
9862 (license (license:non-copyleft "file:///readme.txt"))))
9863
9864 (define-public gnurobots
9865 (package
9866 (name "gnurobots")
9867 (version "1.2.0")
9868 (source
9869 (origin
9870 (method url-fetch)
9871 (uri (string-append "mirror://gnu/gnurobots/gnurobots-"
9872 version ".tar.gz"))
9873 (sha256
9874 (base32
9875 "07gi3lsmbzzsjambgixj6xy79lh22km84z7bnzgwzxdy806lyvwb"))))
9876 (build-system gnu-build-system)
9877 (inputs
9878 (list glib gtk+-2 vte/gtk+-2 readline guile-1.8))
9879 (native-inputs
9880 (list pkg-config))
9881 (arguments
9882 `(#:make-flags
9883 (list
9884 ;; Do not abort build on "deprecated-declarations" warnings.
9885 "CFLAGS=-Wno-error=deprecated-declarations"
9886 ;; Find readline headers in sub-directory.
9887 (string-append "READLINE_CFLAGS=-I"
9888 (assoc-ref %build-inputs "readline")
9889 "/include/readline/"))
9890 #:phases
9891 (modify-phases %standard-phases
9892 (add-after 'install 'install-doc
9893 (lambda* (#:key outputs #:allow-other-keys)
9894 (install-file "doc/Robots-HOWTO"
9895 (string-append (assoc-ref outputs "out")
9896 "/share/doc/gnurobots-"
9897 ,version))
9898 #t)))))
9899 (home-page "https://www.gnu.org/software/gnurobots/")
9900 (synopsis "Program a little robot and watch it explore a world")
9901 (description
9902 "GNU Robots is a game in which you program a robot to explore a world
9903 full of enemies that can hurt it, obstacles and food to be eaten. The goal of
9904 the game is to stay alive and collect prizes. The robot program conveniently
9905 may be written in a plain text file in the Scheme programming language.")
9906 (license license:gpl3+)))
9907
9908 (define-public ri-li
9909 (package
9910 (name "ri-li")
9911 (version "2.0.1")
9912 (source (origin
9913 (method url-fetch)
9914 (uri (string-append "mirror://sourceforge/ri-li/"
9915 "Ri-li%20Linux_Unix/Ri-li%20V" version "/"
9916 "Ri-li-" version ".tar.bz2"))
9917 (sha256
9918 (base32
9919 "1gcdsgnnbbn1mb1hkpwniv3fhkaj1nn8gq33v5c16q3wqchcq77p"))
9920 ;; Taken from
9921 ;; <https://github.com/NixOS/nixpkgs/blob/master/pkgs/games/rili/moderinze_cpp.patch>.
9922 ;; It doesn't build otherwise.
9923 (patches (search-patches "ri-li-modernize_cpp.patch"))))
9924 (build-system gnu-build-system)
9925 (arguments
9926 `(#:phases
9927 (modify-phases %standard-phases
9928 ;; Remove "gentoo" subdirectory from Makefile, as it is
9929 ;; missing a make file and generates a build failure.
9930 (add-after 'configure 'fix-build
9931 (lambda _
9932 (substitute* "Makefile"
9933 ((" gentoo") ""))
9934 #t))
9935 (add-after 'install 'install-desktop-file
9936 (lambda* (#:key outputs #:allow-other-keys)
9937 (let* ((out (assoc-ref outputs "out"))
9938 (apps (string-append out "/share/applications"))
9939 (pixmaps (string-append out "/share/pixmaps")))
9940 (for-each (lambda (f) (install-file f pixmaps))
9941 (find-files "data" "\\.(png|ico)$"))
9942 (mkdir-p apps)
9943 (with-output-to-file (string-append apps "/ri-li.desktop")
9944 (lambda _
9945 (format #t
9946 "[Desktop Entry]~@
9947 Name=Ri-li~@
9948 Exec=~a/bin/Ri_li~@
9949 Icon=~a/Ri-li-icon-32x32.png~@
9950 Categories=Game;ArcadeGame;~@
9951 Keywords=toy;train;wooden;snake-like;engine;~@
9952 Comment=a toy simulator game~@
9953 Comment[de]=Ein Spiel mit einem kleinen Zug~@
9954 Comment[fr]=un jeu de petit train~@
9955 Comment[ro_RO]=un joc cu un tren de jucărie~@
9956 Terminal=false~@
9957 Type=Application~%"
9958 out pixmaps))))
9959 #t))
9960 (add-after 'install-desktop-file 'remove-spurious-files
9961 ;; Delete redundant files already installed somewhere else.
9962 (lambda* (#:key outputs #:allow-other-keys)
9963 (let ((out (assoc-ref outputs "out")))
9964 (for-each delete-file
9965 (find-files (string-append out "/share/Ri-li")
9966 "\\.(png|ico)|COPYING"))
9967 #t))))))
9968 (inputs
9969 `(("sdl" ,(sdl-union (list sdl sdl-mixer)))))
9970 (home-page "http://www.ri-li.org")
9971 (synopsis "Toy train simulation game")
9972 (description "Ri-li is a game in which you drive a wooden toy
9973 steam locomotive across many levels and collect all the coaches to
9974 win.")
9975 ;; The project is dual-licensed GPL2+ and GPL3+.
9976 (license (list license:gpl2+ license:gpl3+))))
9977
9978 (define-public freeorion
9979 (package
9980 (name "freeorion")
9981 (version "0.4.10.2")
9982 (source
9983 (origin
9984 (method git-fetch)
9985 (uri (git-reference
9986 (url "https://github.com/freeorion/freeorion")
9987 (commit (string-append "v" version))))
9988 (sha256
9989 (base32 "12fhwa3cs6lvdbdhina310qk2g7zcphldsh7ibsbxn8d1m731xlk"))
9990 (file-name (git-file-name name version))
9991 (modules '((guix build utils)))
9992 (snippet
9993 '(begin
9994 ;; There are some bundled fonts.
9995 (for-each delete-file-recursively '("default/data/fonts"))))))
9996 (build-system cmake-build-system)
9997 (arguments
9998 '(#:tests? #f ;no test
9999 #:phases
10000 (modify-phases %standard-phases
10001 (add-after 'unpack 'unbundle-fonts
10002 (lambda* (#:key inputs #:allow-other-keys)
10003 (let ((roboto-dir (string-append (assoc-ref inputs "font-roboto")
10004 "/share/fonts/truetype/")))
10005 (substitute* "UI/ClientUI.cpp"
10006 (("\\(GetRootDataDir.*?Roboto-(Bold|Regular)\\.ttf\"\\)\\.string\\(\\)\\);"
10007 all type)
10008 (string-append "\"" roboto-dir "Roboto-" type ".ttf\");")))
10009 #t))))))
10010 (inputs
10011 `(("boost" ,boost)
10012 ("boost_signals" ,boost-signals2)
10013 ("font-dejavu" ,font-dejavu)
10014 ("font-roboto" ,font-google-roboto)
10015 ("freetype2" ,freetype)
10016 ("glew" ,glew)
10017 ("glu" ,glu)
10018 ("libogg" ,libogg)
10019 ("libpng" ,libpng)
10020 ("libvorbis" ,libvorbis)
10021 ("openal" ,openal)
10022 ("python" ,python)
10023 ("sdl2" ,sdl2)
10024 ("zlib" ,zlib)))
10025 (home-page "https://www.freeorion.org/index.php/Main_Page")
10026 (synopsis "Turn-based space empire and galactic conquest computer game")
10027 (description
10028 "FreeOrion is a turn-based space empire and galactic conquest (4X)
10029 computer game being designed and built by the FreeOrion project. Control an
10030 empire with the goal of exploring the galaxy, expanding your territory,
10031 exploiting the resources, and exterminating rival alien empires. FreeOrion is
10032 inspired by the tradition of the Master of Orion games, but is not a clone or
10033 remake of that series or any other game.")
10034 ;; Source code is released under gpl2. Artwork, music and sounds, and
10035 ;; in-game text are released under cc-by-sa3.0. Game content scripts are
10036 ;; released under both gpl2 and cc-by-sa3.0. Bundled Gigi library is
10037 ;; released under lgpl2.1+.
10038 (license (list license:gpl2 license:cc-by-sa3.0 license:lgpl2.1+))))
10039
10040 (define-public leela-zero
10041 (package
10042 (name "leela-zero")
10043 (version "0.17")
10044 (source
10045 (origin
10046 (method git-fetch)
10047 (uri (git-reference
10048 (url "https://github.com/leela-zero/leela-zero")
10049 (commit (string-append "v" version))))
10050 (file-name (git-file-name name version))
10051 (sha256
10052 (base32
10053 "17px5iny8mql5c01bymcli7zfssswkzvb2i8gnsmjcck6i2n8srl"))
10054 (patches (search-patches "leela-zero-gtest.patch"))))
10055 (build-system cmake-build-system)
10056 (native-inputs
10057 (list googletest))
10058 (inputs
10059 (list boost
10060 opencl-icd-loader
10061 openblas
10062 opencl-headers
10063 qtbase-5
10064 zlib))
10065 (arguments
10066 '(#:configure-flags '("-DUSE_BLAS=YES")
10067 #:phases (modify-phases %standard-phases
10068 (add-before 'configure 'fix-tests
10069 (lambda* (#:key outputs #:allow-other-keys)
10070 (let ((home (getcwd)))
10071 (setenv "HOME" home)
10072 (substitute* "src/tests/gtests.cpp"
10073 (("\\.\\./src/tests/0k\\.txt")
10074 (string-append home "/src/tests/0k.txt"))
10075 (("cfg_gtp_mode = true;")
10076 "cfg_gtp_mode = true; cfg_cpu_only = true;")))
10077 #t))
10078 (replace 'check
10079 (lambda _
10080 (invoke "./tests"))))))
10081 (home-page "https://github.com/leela-zero/leela-zero")
10082 (synopsis "Program playing the game of Go")
10083 (description
10084 "Leela-zero is a Go engine with no human-provided knowledge, modeled after
10085 the AlphaGo Zero paper. The current best network weights file for the engine
10086 can be downloaded from @url{https://zero.sjeng.org/best-network}.")
10087 (license license:gpl3+)))
10088
10089 (define-public q5go
10090 (package
10091 (name "q5go")
10092 (version "1.0")
10093 (source (origin
10094 (method git-fetch)
10095 (uri (git-reference
10096 (url "https://github.com/bernds/q5Go")
10097 (commit (string-append "q5go-" version))))
10098 (file-name (git-file-name name version))
10099 (sha256
10100 (base32
10101 "1gdlfqcqkqv7vph3qwq78d0qz6dhmdsranxq9bmixiisbzkqby31"))))
10102 (build-system gnu-build-system)
10103 (native-inputs
10104 (list pkg-config))
10105 (inputs
10106 (list qtbase-5 qtmultimedia qtsvg))
10107 (arguments
10108 '(#:phases
10109 (modify-phases %standard-phases
10110 (add-after 'unpack 'fix-configure-script
10111 (lambda _
10112 ;; Bypass the unavailable qtchooser program.
10113 (substitute* "configure"
10114 (("test -z \"QTCHOOSER\"")
10115 "false")
10116 (("qtchooser -run-tool=(.*) -qt=qt5" _ command)
10117 command))
10118 #t))
10119 (add-after 'unpack 'fix-header
10120 (lambda _
10121 (substitute* "src/bitarray.h"
10122 (("#include <cstring>" all)
10123 (string-append all "\n#include <stdexcept>")))))
10124 (add-after 'unpack 'fix-paths
10125 (lambda _
10126 (substitute* '("src/pics/Makefile.in"
10127 "src/translations/Makefile.in")
10128 (("\\$\\(datadir\\)/qGo/")
10129 "$(datadir)/q5go/"))
10130 #t))
10131 (add-after 'install 'install-desktop-file
10132 (lambda* (#:key outputs #:allow-other-keys)
10133 (let* ((out (assoc-ref outputs "out"))
10134 (apps (string-append out "/share/applications"))
10135 (pics (string-append out "/share/q5go/pics")))
10136 (delete-file-recursively (string-append out "/share/applnk"))
10137 (delete-file-recursively (string-append out "/share/mimelnk"))
10138 (install-file "../source/src/pics/Bowl.ico" pics)
10139 (mkdir-p apps)
10140 (with-output-to-file (string-append apps "/q5go.desktop")
10141 (lambda _
10142 (format #t
10143 "[Desktop Entry]~@
10144 Name=q5go~@
10145 Exec=~a/bin/q5go~@
10146 Icon=~a/Bowl.ico~@
10147 Categories=Game;~@
10148 Comment=Game of Go~@
10149 Comment[de]=Spiel des Go~@
10150 Comment[eo]=Goo~@
10151 Comment[es]=Juego de Go~@
10152 Comment[fr]=Jeu de Go~@
10153 Comment[ja]=囲碁~@
10154 Comment[ko]=바둑~@
10155 Comment[zh]=围棋~@
10156 Terminal=false~@
10157 Type=Application~%"
10158 out pics))))
10159 #t)))))
10160 (synopsis "Qt GUI to play the game of Go")
10161 (description
10162 "This a tool for Go players which performs the following functions:
10163 @itemize
10164 @item SGF editor,
10165 @item Analysis frontend for Leela Zero (or compatible engines),
10166 @item GTP interface (to play against an engine),
10167 @item IGS client (to play on the internet),
10168 @item Export games to a variety of formats.
10169 @end itemize")
10170 (home-page "https://github.com/bernds/q5Go")
10171 (license license:gpl2+)))
10172
10173 (define-public ktuberling
10174 (package
10175 (name "ktuberling")
10176 (version "20.12.0")
10177 (source
10178 (origin
10179 (method url-fetch)
10180 (uri (string-append "mirror://kde/stable/release-service/" version
10181 "/src/ktuberling-" version ".tar.xz"))
10182 (sha256
10183 (base32 "0mlv9qllg70p26dbrcsr820c70d3ib88hapc1z6wgjhdpmc12ni1"))))
10184 (build-system qt-build-system)
10185 (native-inputs
10186 (list extra-cmake-modules kdoctools perl))
10187 (inputs
10188 (list kcompletion
10189 kconfigwidgets
10190 kcoreaddons
10191 kcrash
10192 kdbusaddons
10193 ki18n
10194 kio
10195 kwidgetsaddons
10196 kxmlgui
10197 libkdegames
10198 python-wrapper
10199 qtbase-5
10200 qtmultimedia
10201 qtdeclarative
10202 qtsvg))
10203 (home-page "https://games.kde.org/")
10204 (synopsis "Stamp drawing toy")
10205 (description "KTuberling is a drawing toy intended for small children and
10206 adults who remain young at heart. The game has no winner; the only purpose is
10207 to make the funniest faces you can. Several activities are possible, e.g.:
10208
10209 @itemize
10210 @item Give the potato a funny face, clothes, and other goodies
10211 @item Build a small town, complete with school, zoo, and fire department
10212 @item Create a fantastic moonscape with spaceships and aliens
10213 @item Top a pizza
10214 @end itemize
10215
10216 KTuberling can speak the name of each the object in several languages,
10217 to assist in learning basic vocabulary.
10218
10219 This package is part of the KDE games module.")
10220 (license (list license:gpl2+ license:fdl1.2+))))
10221
10222 (define-public picmi
10223 (package
10224 (name "picmi")
10225 (version "20.12.0")
10226 (source
10227 (origin
10228 (method url-fetch)
10229 (uri (string-append "mirror://kde/stable/release-service/" version
10230 "/src/picmi-" version ".tar.xz"))
10231 (sha256
10232 (base32 "1dfq9m4njh0czz8zws46rkz6xq2n6xra5w223m3s2f5civiw5msz"))))
10233 (build-system qt-build-system)
10234 (native-inputs
10235 (list extra-cmake-modules kdoctools))
10236 (inputs
10237 (list kcoreaddons
10238 kcrash
10239 kdbusaddons
10240 kdeclarative
10241 ki18n
10242 kio
10243 knewstuff
10244 kxmlgui
10245 libkdegames
10246 qtbase-5
10247 qtdeclarative
10248 qtsvg))
10249 (home-page "https://games.kde.org/")
10250 (synopsis "Number logic game")
10251 (description "Picmi is a number logic game in which cells in a grid have
10252 to be colored or left blank according to numbers given at the side of the
10253 grid. The aim is to reveal a hidden picture.
10254
10255 This package is part of the KDE games module.")
10256 (license (list license:gpl2+ license:fdl1.2+))))
10257
10258 (define-public kolf
10259 (package
10260 (name "kolf")
10261 (version "20.12.0")
10262 (source
10263 (origin
10264 (method url-fetch)
10265 (uri (string-append "mirror://kde/stable/release-service/" version
10266 "/src/kolf-" version ".tar.xz"))
10267 (sha256
10268 (base32 "1lpp6pzr5dgd4si4a8c7hcvgxgqy0bgyhkx9m6jqb0zhll6dxj10"))))
10269 (build-system qt-build-system)
10270 (native-inputs
10271 (list extra-cmake-modules kdoctools))
10272 (inputs
10273 (list kcompletion
10274 kconfigwidgets
10275 kcoreaddons
10276 kcrash
10277 kdbusaddons
10278 ki18n
10279 kio
10280 kwidgetsaddons
10281 kxmlgui
10282 ktextwidgets
10283 libkdegames
10284 qtbase-5
10285 qtdeclarative))
10286 (home-page "https://games.kde.org/")
10287 (synopsis "Miniature golf game")
10288 (description "Kolf is a miniature golf game for one to ten players. The
10289 game is played from an overhead view, with a short bar representing the golf
10290 club. Kolf features many different types of objects, such as water hazards,
10291 slopes, sand traps, and black holes (warps), among others.
10292
10293 Features are:
10294 @itemize
10295 @item Single and Multi-player (up to ten players) modes
10296 @item High scores table
10297 @item Dynamic courses
10298 @item Third-party courses
10299 @item Course editor
10300 @end itemize
10301
10302 This package is part of the KDE games module.")
10303 (license (list license:gpl2+ license:lgpl2.0+ license:fdl1.2+))))
10304
10305 (define-public libkmahjongg
10306 (package
10307 (name "libkmahjongg")
10308 (version "20.12.0")
10309 (source
10310 (origin
10311 (method url-fetch)
10312 (uri (string-append "mirror://kde/stable/release-service/"
10313 version "/src/libkmahjongg-" version ".tar.xz"))
10314 (sha256
10315 (base32 "10ljzbf7qki5flydankrbksaihhkqpfyljb8c71fbwqwmkr7rgfq"))))
10316 (build-system qt-build-system)
10317 (native-inputs
10318 (list extra-cmake-modules))
10319 (inputs
10320 (list kauth
10321 kcompletion
10322 ;("kconfig" ,kconfig)
10323 kcodecs
10324 kconfigwidgets
10325 kcoreaddons
10326 ki18n
10327 kwidgetsaddons
10328 qtbase-5
10329 qtsvg))
10330 (home-page "https://games.kde.org/")
10331 (synopsis "Shared library for kmahjongg and kshisen")
10332 (description "Shared library and common files for kmahjongg, kshisen and
10333 other Mah Jongg like games.")
10334 (license (list license:gpl2+ license:lgpl2.0+ license:fdl1.2+))))
10335
10336 (define-public kmahjongg
10337 (package
10338 (name "kmahjongg")
10339 (version "20.12.0")
10340 (source
10341 (origin
10342 (method url-fetch)
10343 (uri (string-append "mirror://kde/stable/release-service/"
10344 version "/src/kmahjongg-" version ".tar.xz"))
10345 (sha256
10346 (base32 "1fcj4jb2zzbaxp7cp04w36y0c7lh77yzin66fmvrcxkl11xi2wwd"))))
10347 (build-system qt-build-system)
10348 (native-inputs
10349 (list extra-cmake-modules kdoctools))
10350 (inputs
10351 (list kcompletion
10352 kcrash
10353 kdbusaddons
10354 kdeclarative
10355 ki18n
10356 knewstuff
10357 kxmlgui
10358 libkdegames
10359 libkmahjongg
10360 qtbase-5
10361 qtdeclarative
10362 qtsvg))
10363 (home-page "https://games.kde.org/")
10364 (synopsis "Tile laying patience")
10365 (description "In KMahjongg the tiles are scrambled and staked on top of
10366 each other to resemble a certain shape. The player is then expected to remove
10367 all the tiles off the game board by locating each tile's matching pair.
10368
10369 A variety of tile layouts are included, as well as an editor to create new
10370 layouts.
10371
10372 This package is part of the KDE games module.")
10373 (license (list license:gpl2+ license:lgpl2.0+ license:fdl1.2+))))
10374
10375 (define-public kshisen
10376 (package
10377 (name "kshisen")
10378 (version "20.12.0")
10379 (source
10380 (origin
10381 (method url-fetch)
10382 (uri (string-append "mirror://kde/stable/release-service/"
10383 version "/src/kshisen-" version ".tar.xz"))
10384 (sha256
10385 (base32 "1hrwr0f1kidivsp8lnwdbqz3xxagjvjwh72r3gma8smfilybygfb"))))
10386 (build-system qt-build-system)
10387 (native-inputs
10388 (list extra-cmake-modules
10389 ;("perl" ,perl)
10390 ;("pkg-config" ,pkg-config)
10391 kdoctools))
10392 (inputs
10393 (list kauth
10394 kcompletion
10395 kconfigwidgets
10396 kcoreaddons
10397 kcrash
10398 kdbusaddons
10399 ki18n
10400 kxmlgui
10401 libkdegames
10402 libkmahjongg
10403 qtbase-5
10404 qtdeclarative))
10405 (home-page "https://games.kde.org/")
10406 (synopsis "Shisen-Sho solitaire game")
10407 (description "KShisen is a solitaire-like game played using the standard
10408 set of Mahjong tiles. Unlike Mahjong however, KShisen has only one layer of
10409 scrambled tiles
10410
10411 This package is part of the KDE games module.")
10412 (license license:gpl2+)))
10413
10414 (define-public kajongg
10415 (package
10416 (name "kajongg")
10417 (version "20.12.0")
10418 (source
10419 (origin
10420 (method url-fetch)
10421 (uri (string-append "mirror://kde/stable/release-service/"
10422 version "/src/kajongg-" version ".tar.xz"))
10423 (sha256
10424 (base32 "03fdbnx7zx7vgcxvwd1h1098ks9gq162bwz35fhpyzpynr667m5r"))))
10425 (build-system qt-build-system)
10426 (arguments
10427 `(#:phases
10428 (modify-phases %standard-phases
10429 (add-after 'unpack 'fix-paths
10430 (lambda* (#:key inputs #:allow-other-keys)
10431 (substitute* "src/mjresource.py"
10432 (("'share', 'kmahjongglib'" all)
10433 (string-append "'" (assoc-ref inputs "libkmahjongg")
10434 "/share', 'kmahjongglib'")))))
10435 (add-after 'qt-wrap 'wrap
10436 (lambda* (#:key outputs #:allow-other-keys)
10437 (let ((out (assoc-ref outputs "out")))
10438 (for-each (lambda (program)
10439 (wrap-program program
10440 `("GUIX_PYTHONPATH" ":" prefix
10441 (,(getenv "GUIX_PYTHONPATH")))))
10442 (list (string-append out "/bin/kajongg")
10443 (string-append out "/bin/kajonggserver")))))))))
10444 (native-inputs
10445 (list extra-cmake-modules
10446 ;("perl" ,perl)
10447 kdoctools))
10448 (inputs
10449 (list kconfig
10450 kconfigwidgets
10451 kcoreaddons
10452 ki18n
10453 libkmahjongg
10454 python
10455 python-twisted
10456 python-pyqt
10457 python-zope-interface
10458 qtbase-5
10459 qtsvg))
10460 (home-page "https://games.kde.org/")
10461 (synopsis "Classical Mah Jongg game for 4 players")
10462 (description "Kajongg is the ancient Chinese board game for 4 players.
10463
10464 If you are looking for the Mah Jongg solitaire please use the application
10465 kmahjongg.
10466
10467 Kajongg can be used in two different ways: Scoring a manual game where you
10468 play as always and use Kajongg for the computation of scores and for
10469 bookkeeping. Or you can use Kajongg to play against any combination of other
10470 human players or computer players.
10471
10472 This package is part of the KDE games module.")
10473 (license (list license:gpl2+ license:fdl1.2+))))
10474
10475 (define-public kbreakout
10476 (package
10477 (name "kbreakout")
10478 (version "20.12.0")
10479 (source
10480 (origin
10481 (method url-fetch)
10482 (uri (string-append "mirror://kde/stable/release-service/" version
10483 "/src/kbreakout-" version ".tar.xz"))
10484 (sha256
10485 (base32 "0kqj2cx0ny3qq65c6w5fpnzmrwl9irg8slzvpd3anck5cnvma3j4"))))
10486 (build-system qt-build-system)
10487 (native-inputs
10488 (list extra-cmake-modules kdoctools))
10489 (inputs
10490 (list kcompletion
10491 kconfig
10492 kconfigwidgets
10493 kcoreaddons
10494 kcrash
10495 kdbusaddons
10496 ki18n
10497 kwidgetsaddons
10498 kxmlgui
10499 libkdegames
10500 qtbase-5
10501 qtdeclarative))
10502 (home-page "https://games.kde.org/")
10503 (synopsis "Breakout like game")
10504 (description "KBreakout is similar to the classics breakout and xboing,
10505 featuring a number of added graphical enhancements and effects. You control a
10506 paddle at the bottom of the playing-field, and must destroy bricks at the top
10507 by bouncing balls against them.
10508
10509 This package is part of the KDE games module.")
10510 (license (list license:gpl2+ license:fdl1.2+))))
10511
10512 (define-public kmines
10513 (package
10514 (name "kmines")
10515 (version "20.12.0")
10516 (source
10517 (origin
10518 (method url-fetch)
10519 (uri (string-append "mirror://kde/stable/release-service/" version
10520 "/src/kmines-" version ".tar.xz"))
10521 (sha256
10522 (base32 "0hqjwh3jq2npqwkvh67fyn2xnq8swiasdw5jz8f0ikl0k28id775"))))
10523 (build-system qt-build-system)
10524 (native-inputs
10525 (list extra-cmake-modules kdoctools))
10526 (inputs
10527 (list kcompletion
10528 kconfig
10529 kconfigwidgets
10530 kcoreaddons
10531 kcrash
10532 kdbusaddons
10533 ki18n
10534 ktextwidgets
10535 kwidgetsaddons
10536 kxmlgui
10537 libkdegames
10538 qtbase-5
10539 qtdeclarative))
10540 (home-page "https://games.kde.org/")
10541 (synopsis "Classical mine sweeper game")
10542 (description "KMines is a classic Minesweeper game. The idea is to
10543 uncover all the squares without blowing up any mines. When a mine is blown
10544 up, the game is over.
10545
10546 This package is part of the KDE games module.")
10547 (license (list license:gpl2+ license:fdl1.2+))))
10548
10549 (define-public konquest
10550 (package
10551 (name "konquest")
10552 (version "20.12.0")
10553 (source
10554 (origin
10555 (method url-fetch)
10556 (uri (string-append "mirror://kde/stable/release-service/"
10557 version "/src/konquest-" version ".tar.xz"))
10558 (sha256
10559 (base32 "0lnwj06vv4qx05hr8pzysnvrxh8y04asajrph0rsj37v8hs9g5lh"))))
10560 (build-system qt-build-system)
10561 (native-inputs
10562 (list extra-cmake-modules kdoctools))
10563 (inputs
10564 (list kcompletion
10565 kconfig
10566 kcoreaddons
10567 kcrash
10568 kdbusaddons
10569 kguiaddons
10570 ki18n
10571 kwidgetsaddons
10572 kxmlgui
10573 libkdegames
10574 qtbase-5
10575 qtdeclarative
10576 qtsvg))
10577 (home-page "https://games.kde.org/")
10578 (synopsis "Simple turn-based strategy game")
10579 (description "Konquest is the KDE version of Gnu-Lactic Konquest. Players
10580 conquer other planets by sending ships to them. The goal is to build an
10581 interstellar empire and ultimately conquer all other player's planets. The
10582 game can be played with up to nine empires, commanded either by the computer
10583 or by puny earthlings.
10584
10585 This package is part of the KDE games module.")
10586 (license (list license:gpl2+ license:fdl1.2+))))
10587
10588 (define-public kbounce
10589 (package
10590 (name "kbounce")
10591 (version "20.12.0")
10592 (source
10593 (origin
10594 (method url-fetch)
10595 (uri (string-append "mirror://kde/stable/release-service/"
10596 version "/src/kbounce-" version ".tar.xz"))
10597 (sha256
10598 (base32 "0ymy0z1qlw3n653xs3dsa1xm78q4xaj09dnnci4km77rzis26vb6"))))
10599 (build-system qt-build-system)
10600 (native-inputs
10601 (list extra-cmake-modules kdoctools))
10602 (inputs
10603 (list kcompletion
10604 kconfigwidgets
10605 kcoreaddons
10606 kcrash
10607 kdbusaddons
10608 ki18n
10609 kio
10610 kwidgetsaddons
10611 kxmlgui
10612 libkdegames
10613 qtbase-5
10614 qtdeclarative
10615 qtsvg))
10616 (home-page "https://games.kde.org/")
10617 (synopsis "Jezzball arcade game")
10618 (description "KBounce is a single player arcade game with the elements of
10619 puzzle. It is played on a field, surrounded by wall, with two or more balls
10620 bouncing around within the walls. The object of the game is to build new
10621 walls to decrease the size of the active field.
10622
10623 This package is part of the KDE games module.")
10624 (license (list license:gpl2+ license:lgpl2.0+ license:fdl1.2+))))
10625
10626 (define-public kblocks
10627 (package
10628 (name "kblocks")
10629 (version "20.12.0")
10630 (source
10631 (origin
10632 (method url-fetch)
10633 (uri (string-append "mirror://kde/stable/release-service/"
10634 version "/src/kblocks-" version ".tar.xz"))
10635 (sha256
10636 (base32 "09yfm9mzbamp294cvc5finq6ilxvxr68i0dnb0m72pa4sfzmij32"))))
10637 (build-system qt-build-system)
10638 (native-inputs
10639 (list extra-cmake-modules kdoctools))
10640 (inputs
10641 (list kcompletion
10642 kconfig
10643 kconfigwidgets
10644 kcoreaddons
10645 kcrash
10646 kdbusaddons
10647 ki18n
10648 kwidgetsaddons
10649 kxmlgui
10650 libkdegames
10651 qtbase-5
10652 qtdeclarative
10653 qtsvg))
10654 (home-page "https://games.kde.org/")
10655 (synopsis "Single player falling blocks puzzle game")
10656 (description "KBlocks is the classic Tetris-like falling blocks game.
10657
10658 The idea is to stack the falling blocks to create horizontal lines without any
10659 gaps. When a line is completed it is removed, and more space is available in
10660 the play area. When there is not enough space for blocks to fall, the game is
10661 over.
10662
10663 This package is part of the KDE games module.")
10664 (license (list license:gpl2+ license:fdl1.2+))))
10665
10666 (define-public ksudoku
10667 (package
10668 (name "ksudoku")
10669 (version "20.12.0")
10670 (source
10671 (origin
10672 (method url-fetch)
10673 (uri (string-append "mirror://kde/stable/release-service/"
10674 version "/src/ksudoku-" version ".tar.xz"))
10675 (sha256
10676 (base32 "0pj6ry7ak1rnpb93mqypaxrcbmrhwg9ir6zhb3ybzfkfcrh67g12"))))
10677 (build-system qt-build-system)
10678 (native-inputs
10679 (list extra-cmake-modules kdoctools))
10680 (inputs
10681 (list karchive
10682 kconfig
10683 kconfigwidgets
10684 kcoreaddons
10685 kcrash
10686 kguiaddons
10687 ki18n
10688 kiconthemes
10689 kio
10690 kwidgetsaddons
10691 kxmlgui
10692 libkdegames
10693 glu
10694 qtbase-5
10695 qtdeclarative
10696 qtsvg))
10697 (home-page "https://games.kde.org/")
10698 (synopsis "Sudoku puzzle game and solver")
10699 (description "KSudoku is a Sudoku game and solver, supporting a range of
10700 2D and 3D Sudoku variants. In addition to playing Sudoku, it can print Sudoku
10701 puzzle sheets and find the solution to any Sudoku puzzle.
10702
10703 The word Sudoku means \"single number in an allotted place\" in Japanese.
10704 These are the basic rules: Every Sudoku is a square divided into 3x3
10705 subsquares with 3x3 cells each.
10706
10707 Some cells are filled with a number at the beginning. The remaining ones are
10708 to be filled by the player using numbers from 1 to 9, without repeating a
10709 number twice on each column, row or subsquare (each of them must contain only
10710 one 1, one 2, one 3, and so on). The game requires logic and patience.
10711 Solving takes usually 10 to 30 minutes, depending on puzzle level, your skill
10712 and experience.
10713
10714 The numerals in Sudoku puzzles are used for convenience (for example in 16x16
10715 board we use letters): arithmetic relationships between numbers are
10716 irrelevant.
10717
10718 This program supports also 16x16 games with numbers from 1 to 16 and 256
10719 cells with 16 cols, rows and subsquares!
10720
10721 More information at http://en.wikipedia.org/wiki/Sudoku
10722
10723 This package is part of the KDE games module.")
10724 (license (list license:gpl2+ license:fdl1.2+))))
10725
10726 (define-public klines
10727 (package
10728 (name "klines")
10729 (version "20.12.0")
10730 (source
10731 (origin
10732 (method url-fetch)
10733 (uri (string-append "mirror://kde/stable/release-service/" version
10734 "/src/klines-" version ".tar.xz"))
10735 (sha256
10736 (base32 "0y8lnwawrkl4ixn7v4dg48k2zpr083krv7dv4d94b2dpkh7xfvih"))))
10737 (build-system qt-build-system)
10738 (native-inputs
10739 (list extra-cmake-modules kdoctools))
10740 (inputs
10741 (list kcompletion
10742 kconfigwidgets
10743 kcoreaddons
10744 kcrash
10745 kdbusaddons
10746 ki18n
10747 kwidgetsaddons
10748 kxmlgui
10749 libkdegames
10750 qtbase-5
10751 qtdeclarative))
10752 (home-page "https://games.kde.org/")
10753 (synopsis "Place 5 equal pieces together, but wait, there are 3 new ones")
10754 (description "KLines is a simple but highly addictive one player game.
10755
10756 The player has to move the colored balls around the game board, gathering them
10757 into the lines of the same color by five. Once the line is complete it is
10758 removed from the board, therefore freeing precious space. In the same time
10759 the new balls keep arriving by three after each move, filling up the game
10760 board.
10761
10762 KLines is a single-player game where the player removes colored balls from the
10763 board by arranging them into lines of five or more. However, every time the
10764 player moves a ball, three more balls are added to the board.
10765
10766 This package is part of the KDE games module.")
10767 (license (list license:gpl2+ license:fdl1.2+))))
10768
10769 (define-public kgoldrunner
10770 (package
10771 (name "kgoldrunner")
10772 (version "20.12.0")
10773 (source
10774 (origin
10775 (method url-fetch)
10776 (uri (string-append "mirror://kde/stable/release-service/" version
10777 "/src/kgoldrunner-" version ".tar.xz"))
10778 (sha256
10779 (base32 "17ra5d3r9ajy2inj17gwd5xphzhvbzx5kpvdwyj6msx4dd9wxgfi"))))
10780 (build-system qt-build-system)
10781 (native-inputs
10782 (list extra-cmake-modules kdoctools))
10783 (inputs
10784 (list kcompletion
10785 kcoreaddons
10786 kcrash
10787 kdbusaddons
10788 ki18n
10789 kio
10790 kwidgetsaddons
10791 kxmlgui
10792 libkdegames
10793 qtbase-5
10794 qtdeclarative))
10795 (home-page "https://games.kde.org/")
10796 (synopsis "Action and puzzle solving game")
10797 (description "KGoldrunner is an action game where the hero runs through a
10798 maze, climbs stairs, dig holes and dodges enemies in order to collect all the
10799 gold nuggets and escape to the next level. Your enemies are also after the
10800 gold. Worse still, they are after you!.
10801
10802 KGoldrunner is a fast-paced platform game where the player must navigate a
10803 maze while collecting gold nuggets and avoiding enemies. A variety of level
10804 packs are included, as well as an editor to create new levels.
10805
10806 This package is part of the KDE games module.")
10807 (license (list license:gpl2+ license:fdl1.2+))))
10808
10809 (define-public kdiamond
10810 (package
10811 (name "kdiamond")
10812 (version "20.12.0")
10813 (source
10814 (origin
10815 (method url-fetch)
10816 (uri (string-append "mirror://kde/stable/release-service/" version
10817 "/src/kdiamond-" version ".tar.xz"))
10818 (sha256
10819 (base32 "1iyxrx3422asa58kh0siwvi1svds5kccrym6gdfpdhlmhmciqlzi"))))
10820 (build-system qt-build-system)
10821 (native-inputs
10822 (list extra-cmake-modules kdoctools))
10823 (inputs
10824 (list kcompletion
10825 kconfig
10826 kconfigwidgets
10827 kcoreaddons
10828 kcrash
10829 kdbusaddons
10830 ki18n
10831 knotifications
10832 knotifyconfig
10833 kwidgetsaddons
10834 kxmlgui
10835 libkdegames
10836 qtbase-5
10837 qtdeclarative))
10838 (home-page "https://games.kde.org/")
10839 (synopsis "Three-in-a-row game")
10840 (description "KDiamond is a three-in-a-row game like Bejeweled. It
10841 features unlimited fun with randomly generated games and five difficulty
10842 levels with varying number of diamond colors and board sizes.
10843
10844 This package is part of the KDE games module.")
10845 (license (list license:gpl2+ license:fdl1.2+))))
10846
10847 (define-public kfourinline
10848 (package
10849 (name "kfourinline")
10850 (version "20.12.0")
10851 (source
10852 (origin
10853 (method url-fetch)
10854 (uri (string-append "mirror://kde/stable/release-service/" version
10855 "/src/kfourinline-" version ".tar.xz"))
10856 (sha256
10857 (base32 "0plx3lv35fc8q9svbyl71mms3ji6zn58j306bvm1f8kkgg0x395b"))))
10858 (build-system qt-build-system)
10859 (native-inputs
10860 (list extra-cmake-modules kdoctools))
10861 (inputs
10862 (list kcompletion
10863 kconfig
10864 kconfigwidgets
10865 kcoreaddons
10866 kcrash
10867 kdnssd
10868 ki18n
10869 kxmlgui
10870 libkdegames
10871 qtbase-5
10872 qtdeclarative
10873 qtsvg))
10874 (home-page "https://games.kde.org/")
10875 (synopsis "Place 4 pieces in a row")
10876 (description "KFourInLine is a board game for two players based on the
10877 Connect-Four game.
10878
10879 KFourInLine is a game where two players take turns dropping pieces into a
10880 grid, the winner being the first to place four pieces in a line.
10881
10882 This package is part of the KDE games module.")
10883 (license (list license:gpl2+ license:lgpl2.0+ license:fdl1.2+))))
10884
10885 (define-public kblackbox
10886 (package
10887 (name "kblackbox")
10888 (version "20.12.0")
10889 (source
10890 (origin
10891 (method url-fetch)
10892 (uri (string-append "mirror://kde/stable/release-service/" version
10893 "/src/kblackbox-" version ".tar.xz"))
10894 (sha256
10895 (base32 "0la5w44b0gl72g3wfp0pw8gwnm287lh7nd9k5ikpszw5nn49db0h"))))
10896 (build-system qt-build-system)
10897 (native-inputs
10898 (list extra-cmake-modules kdoctools))
10899 (inputs
10900 (list karchive
10901 kcompletion
10902 kconfig
10903 kcoreaddons
10904 kcrash
10905 kdbusaddons
10906 ki18n
10907 ktextwidgets
10908 kxmlgui
10909 libkdegames
10910 qtbase-5
10911 qtdeclarative
10912 qtsvg))
10913 (home-page "https://games.kde.org/")
10914 (synopsis "Find atoms in a grid by shooting electrons")
10915 (description "KBlackbox is a game of hide and seek played on a grid of
10916 boxes where the computer has hidden several balls. The position of the hidden
10917 balls can be deduced by shooting beams into the box
10918
10919 KBlackBox is a game of hide and seek played on an grid of boxes, where the
10920 player shoots rays into the grid to deduce the positions of hidden objects.
10921
10922 This package is part of the KDE games module.")
10923 (license (list license:gpl2+ license:fdl1.2+))))
10924
10925 (define-public knetwalk
10926 (package
10927 (name "knetwalk")
10928 (version "20.12.0")
10929 (source
10930 (origin
10931 (method url-fetch)
10932 (uri (string-append "mirror://kde/stable/release-service/" version
10933 "/src/knetwalk-" version ".tar.xz"))
10934 (sha256
10935 (base32 "060kj06vpigdy570izsjfgnmqqrpmb8bkr9arqc109hg3avl5wjz"))))
10936 (build-system qt-build-system)
10937 (native-inputs
10938 (list extra-cmake-modules kdoctools))
10939 (inputs
10940 (list kcompletion
10941 kconfig
10942 kconfigwidgets
10943 kcoreaddons
10944 kcrash
10945 kdbusaddons
10946 ki18n
10947 ktextwidgets
10948 kwidgetsaddons
10949 kxmlgui
10950 libkdegames
10951 qtbase-5
10952 qtdeclarative))
10953 (home-page "https://games.kde.org/")
10954 (synopsis "Turn the board pieces to get all computers connected")
10955 (description "KNetWalk is a small game where you have to build up a
10956 computer network by rotating the wires to connect the terminals to the server.
10957 When the network is build, a highscore-list comes up where competitions can be
10958 fought out.
10959
10960 KNetwalk is a puzzle game where the player arranges sections of wire to
10961 connect all the computers on the board.
10962
10963 This package is part of the KDE games module.")
10964 (license (list license:gpl2+ license:fdl1.2+))))
10965
10966 (define-public bomber
10967 (package
10968 (name "bomber")
10969 (version "20.12.0")
10970 (source
10971 (origin
10972 (method url-fetch)
10973 (uri (string-append "mirror://kde/stable/release-service/" version
10974 "/src/bomber-" version ".tar.xz"))
10975 (sha256
10976 (base32 "1fjcwm591jgx3bgqpi0j5fnb2l2r2h3r6lav3vhaxz4rkf56pg2a"))))
10977 (build-system qt-build-system)
10978 (native-inputs
10979 (list extra-cmake-modules kdoctools))
10980 (inputs
10981 (list kcompletion
10982 kconfig
10983 kcoreaddons
10984 kcrash
10985 kdbusaddons
10986 ki18n
10987 kxmlgui
10988 libkdegames
10989 qtbase-5
10990 qtdeclarative))
10991 (home-page "https://games.kde.org/")
10992 (synopsis "Arcade bombing game")
10993 (description "Bomber is a single player arcade game.
10994
10995 The player is invading various cities in a plane that is decreasing in height.
10996 The goal of the game is to destroy all the buildings and advance to the next
10997 level. Each level gets a bit harder by increasing the speed of the plane and
10998 the height of the buildings.
10999
11000 Bomber is a game where you fly a spaceship and attempt to bomb the buildings
11001 below you. Each pass the spaceship makes, it gets lower and lower. If you've
11002 not destroyed a building in your path, you will crash into it.
11003
11004 This package is part of the KDE games module.")
11005 (license (list license:gpl2+ license:fdl1.2+))))
11006
11007 (define-public granatier
11008 (package
11009 (name "granatier")
11010 (version "20.12.0")
11011 (source
11012 (origin
11013 (method url-fetch)
11014 (uri (string-append "mirror://kde/stable/release-service/" version
11015 "/src/granatier-" version ".tar.xz"))
11016 (sha256
11017 (base32 "1fyh7zyacb3pnlfd29jw2jmyl8a7sjw354pi234nd5x5999xw5z6"))))
11018 (build-system qt-build-system)
11019 (native-inputs
11020 (list extra-cmake-modules kdoctools))
11021 (inputs
11022 (list kcompletion
11023 kconfig
11024 kconfigwidgets
11025 kcoreaddons
11026 kcrash
11027 kdbusaddons
11028 ki18n
11029 knewstuff
11030 kwidgetsaddons
11031 kxmlgui
11032 libkdegames
11033 qtbase-5
11034 qtdeclarative
11035 qtsvg))
11036 (home-page "https://games.kde.org/")
11037 (synopsis "Bomberman clone")
11038 (description "Granatier is a clone of the classic Bomberman game,
11039 inspired by the work of the Clanbomber clone.
11040
11041 This package is part of the KDE games module.")
11042 (license (list license:gpl2+ license:fdl1.2+))))
11043
11044 (define-public ksirk
11045 (package
11046 (name "ksirk")
11047 (version "20.12.0")
11048 (source
11049 (origin
11050 (method url-fetch)
11051 (uri (string-append "mirror://kde/stable/release-service/" version
11052 "/src/ksirk-" version ".tar.xz"))
11053 (sha256
11054 (base32 "10y7nm0x6zcc0gh3am69bbxyyb8azbbfyrdqsa023ggr7n04cn21"))))
11055 (build-system qt-build-system)
11056 (native-inputs
11057 (list extra-cmake-modules kdoctools))
11058 (inputs
11059 (list kcrash
11060 ki18n
11061 kiconthemes
11062 kio
11063 knewstuff
11064 kwallet
11065 kxmlgui
11066 libkdegames
11067 phonon
11068 qca
11069 qtbase-5
11070 qtdeclarative
11071 qtsvg
11072 zlib))
11073 (home-page "https://games.kde.org/")
11074 (synopsis "Computerized version of the well known strategy board game
11075 'Risk'")
11076 (description "KsirK is a multi-player network-enabled game. The goal of
11077 the game is simply to conquer the world by attacking your neighbors with your
11078 armies.
11079
11080 At the beginning of the game, countries are distributed to all the players.
11081 Each country contains one army represented by an infantryman. Each player has
11082 some armies to distribute to his countries. On each turn, each player can
11083 attack his neighbours, eventually conquering one or more countries. At the
11084 end of each turn, some bonus armies are distributed to the players in function
11085 of the number of countries they own. The winner is the player that conquered
11086 all the world.
11087
11088 Features:
11089 @itemize
11090 @item Support for 1-6 human or computer players
11091 @item Multi-player gaming over a network
11092 @item You can easily create new skins with SVG graphics and the skin editor
11093 @item Hot New Stuff support. You can easily download and install new skins
11094 @end itemize
11095
11096 This package is part of the KDE games module.")
11097 (license (list license:gpl2+ license:lgpl2.0+ license:fdl1.2+))))
11098
11099 (define-public palapeli
11100 (package
11101 (name "palapeli")
11102 (version "20.12.0")
11103 (source
11104 (origin
11105 (method url-fetch)
11106 (uri (string-append "mirror://kde/stable/release-service/" version
11107 "/src/palapeli-" version ".tar.xz"))
11108 (sha256
11109 (base32 "0xxz9g4zxljlg20g88a5lkbwzzm9yg4vxnrfigk8m018cz0nqd5b"))))
11110 (build-system qt-build-system)
11111 (native-inputs
11112 (list extra-cmake-modules kdoctools))
11113 (inputs
11114 (list karchive
11115 kcompletion
11116 kconfig
11117 kconfigwidgets
11118 kcoreaddons
11119 kcrash
11120 kcrash
11121 ki18n
11122 ki18n
11123 kio
11124 kitemviews
11125 knotifications
11126 kservice
11127 kwidgetsaddons
11128 kxmlgui
11129 libkdegames
11130 qtbase-5
11131 qtdeclarative
11132 qtsvg
11133 shared-mime-info))
11134 (home-page "https://games.kde.org/")
11135 (synopsis "Jigsaw puzzle game")
11136 (description "Palapeli is a jigsaw puzzle game. Unlike other games in
11137 that genre, you are not limited to aligning pieces on imaginary grids. The
11138 pieces are freely moveable. Also, Palapeli features real persistency, i.e.
11139 everything you do is saved on your disk immediately.
11140
11141 Palapeli is the Finnish word for jigsaw puzzle.
11142
11143 This package is part of the KDE games module.")
11144 (license license:gpl2+)))
11145
11146 (define-public kiriki
11147 (package
11148 (name "kiriki")
11149 (version "20.12.0")
11150 (source
11151 (origin
11152 (method url-fetch)
11153 (uri (string-append "mirror://kde/stable/release-service/" version
11154 "/src/kiriki-" version ".tar.xz"))
11155 (sha256
11156 (base32 "0milc8fl1rj4yrwdvm60ampd47dyiys1xvqi5f0g7y6mgymgyk4x"))))
11157 (build-system qt-build-system)
11158 (native-inputs
11159 (list extra-cmake-modules kdoctools))
11160 (inputs
11161 (list kcompletion
11162 kconfig
11163 kconfigwidgets
11164 kcoreaddons
11165 kcrash
11166 kdbusaddons
11167 ki18n
11168 kiconthemes
11169 kxmlgui
11170 libkdegames
11171 qtbase-5
11172 qtdeclarative))
11173 (home-page "https://games.kde.org/")
11174 (synopsis "Yahtzee dice game")
11175 (description "Kiriki is an addictive and fun dice game, designed to be
11176 played by as many as six players.
11177
11178 Participants have to collect points by rolling five dice for up to three times
11179 per single turn to make combinations with the highest score.
11180
11181 This package is part of the KDE games module.")
11182 (license (list license:gpl2+ license:fdl1.2+))))
11183
11184 (define-public kigo
11185 (package
11186 (name "kigo")
11187 (version "20.12.0")
11188 (source
11189 (origin
11190 (method url-fetch)
11191 (uri (string-append "mirror://kde/stable/release-service/" version
11192 "/src/kigo-" version ".tar.xz"))
11193 (sha256
11194 (base32 "088752yzmfsnppd27p8hld4x5s7sw5fagm08024l5ra1mlicdfz9"))))
11195 (build-system qt-build-system)
11196 (native-inputs
11197 (list extra-cmake-modules kdoctools))
11198 (inputs
11199 (list kconfig
11200 kconfigwidgets
11201 kcoreaddons
11202 kcrash
11203 kdbusaddons
11204 ki18n
11205 kio
11206 knewstuff
11207 ktextwidgets
11208 kxmlgui
11209 libkdegames
11210 qtbase-5
11211 qtdeclarative
11212 qtsvg))
11213 (home-page "https://games.kde.org/")
11214 (synopsis "Go board game")
11215 (description "Kigo is an open-source implementation of the popular Go
11216 game.
11217
11218 Go is a strategic board game for two players. It is also known as
11219 igo (Japanese), weiqi or wei ch'i (Chinese) or baduk (Korean). Go is noted
11220 for being rich in strategic complexity despite its simple rules. The game is
11221 played by two players who alternately place black and white stones (playing
11222 pieces, now usually made of glass or plastic) on the vacant intersections of a
11223 grid of 19x19 lines (9x9 or 13x13 for easier games).
11224
11225 You also need to install a go engine, e.g. @code{gnugo}.
11226
11227 This package is part of the KDE games module.")
11228 (license license:gpl3+)))
11229
11230 (define-public kubrick
11231 (package
11232 (name "kubrick")
11233 (version "20.12.0")
11234 (source
11235 (origin
11236 (method url-fetch)
11237 (uri (string-append "mirror://kde/stable/release-service/" version
11238 "/src/kubrick-" version ".tar.xz"))
11239 (sha256
11240 (base32 "0h3mypwd67sss08j5vvrih5f5ss85m9kax6412y40xmsm51lz2pq"))))
11241 (build-system qt-build-system)
11242 (native-inputs
11243 (list extra-cmake-modules kdoctools))
11244 (inputs
11245 (list glu
11246 kconfig
11247 kconfigwidgets
11248 kcoreaddons
11249 kcrash
11250 ki18n
11251 kio
11252 kwidgetsaddons
11253 kxmlgui
11254 libkdegames
11255 qtbase-5
11256 qtdeclarative
11257 qtsvg))
11258 (home-page "https://games.kde.org/")
11259 (synopsis "Game based on Rubik's Cube")
11260 (description "Kubrick is a game based on the Rubik's Cube puzzle.
11261
11262 The cube sizes range from 2x2x2 up to 6x6x6, or you can play with irregular
11263 \"bricks\" such as 5x3x2 or \"mats\" such as 6x4x1 or 2x2x1. The game has a
11264 selection of puzzles at several levels of difficulty, as well as demos of
11265 pretty patterns and solution moves, or you can make up your own puzzles. The
11266 game has unlimited undo, redo, save and reload capabilities.
11267
11268 This package is part of the KDE games module.")
11269 (license (list license:gpl2+ license:fdl1.2+))))
11270
11271 (define-public lskat
11272 (package
11273 (name "lskat")
11274 (version "20.12.0")
11275 (source
11276 (origin
11277 (method url-fetch)
11278 (uri (string-append "mirror://kde/stable/release-service/" version
11279 "/src/lskat-" version ".tar.xz"))
11280 (sha256
11281 (base32 "1wg9zxp64kwjxqs4qw0h7j8yhgffbmvh8j9d4dgmz45dscngnjli"))))
11282 (build-system qt-build-system)
11283 (native-inputs
11284 (list extra-cmake-modules kdoctools))
11285 (inputs
11286 (list kcompletion
11287 kconfig
11288 kcoreaddons
11289 kcrash
11290 kguiaddons
11291 ki18n
11292 kwidgetsaddons
11293 kxmlgui
11294 libkdegames
11295 qtbase-5
11296 qtdeclarative
11297 qtsvg))
11298 (home-page "https://games.kde.org/")
11299 (synopsis "Lieutnant Skat card game")
11300 (description "Lieutnant Skat (from German \"Offiziersskat\") is a fun and
11301 engaging card game for two players, where the second player is either live
11302 opponent, or a built in artificial intelligence.
11303
11304 Lieutnant Skat is a simplified variant of the Skat card game for two players.
11305
11306 This package is part of the KDE games module.")
11307 (license (list license:gpl2+ license:lgpl2.0+ license:fdl1.2+))))
11308
11309 (define-public kapman
11310 (package
11311 (name "kapman")
11312 (version "20.12.0")
11313 (source
11314 (origin
11315 (method url-fetch)
11316 (uri (string-append "mirror://kde/stable/release-service/" version
11317 "/src/kapman-" version ".tar.xz"))
11318 (sha256
11319 (base32 "14x3v6li4r3gzzwfd6ar9saq2rhc7yxs0sp9ygalzq8vq4d7i1kh"))))
11320 (build-system qt-build-system)
11321 (native-inputs
11322 (list extra-cmake-modules kdoctools))
11323 (inputs
11324 (list kcompletion
11325 kconfig
11326 kconfigwidgets
11327 kcoreaddons
11328 kcrash
11329 kdbusaddons
11330 ki18n
11331 kxmlgui
11332 libkdegames
11333 qtbase-5
11334 qtdeclarative
11335 qtsvg))
11336 (home-page "https://games.kde.org/")
11337 (synopsis "Pac-Man clone")
11338 (description "Kapman is a clone of the well known game Pac-Man.
11339
11340 You must run through the maze to eat all pills without being captured by a
11341 ghost. By eating an energizer, Kapman gets the ability to eat ghosts for a
11342 few seconds. When a stage is cleared of pills and energizer the player is
11343 taken to the next stage with slightly increased game speed
11344
11345 This package is part of the KDE games module.")
11346 (license (list license:gpl2+ license:fdl1.2+))))
11347
11348 (define-public kspaceduel
11349 (package
11350 (name "kspaceduel")
11351 (version "20.12.0")
11352 (source
11353 (origin
11354 (method url-fetch)
11355 (uri (string-append "mirror://kde/stable/release-service/" version
11356 "/src/kspaceduel-" version ".tar.xz"))
11357 (sha256
11358 (base32 "1aixh6ygif2cm1a5g32sl5y6b5x68139pzihaxq4334c6avamdai"))))
11359 (build-system qt-build-system)
11360 (native-inputs
11361 (list extra-cmake-modules kdoctools))
11362 (inputs
11363 (list kcompletion
11364 kconfig
11365 kconfigwidgets
11366 kcoreaddons
11367 kcrash
11368 kdbusaddons
11369 ki18n
11370 kxmlgui
11371 libkdegames
11372 qtbase-5
11373 qtdeclarative
11374 qtsvg))
11375 (home-page "https://games.kde.org/")
11376 (synopsis "Two player game with shooting spaceships flying around a sun")
11377 (description "KSpaceduel is a space battle game for one or two players,
11378 where two ships fly around a star in a struggle to be the only survivor.
11379
11380 This package is part of the KDE games module.")
11381 (license (list license:gpl2+ license:fdl1.2+))))
11382
11383 (define-public bovo
11384 (package
11385 (name "bovo")
11386 (version "20.12.0")
11387 (source
11388 (origin
11389 (method url-fetch)
11390 (uri (string-append "mirror://kde/stable/release-service/" version
11391 "/src/bovo-" version ".tar.xz"))
11392 (sha256
11393 (base32 "18qbac366m0xma3ary11q9zxz0wgnysppcl7kpypl6ic3nf61wqz"))))
11394 (build-system qt-build-system)
11395 (native-inputs
11396 (list extra-cmake-modules kdoctools))
11397 (inputs
11398 (list kcompletion
11399 kcoreaddons
11400 kcrash
11401 kdbusaddons
11402 ki18n
11403 kxmlgui
11404 libkdegames
11405 qtbase-5
11406 qtdeclarative
11407 qtsvg))
11408 (home-page "https://games.kde.org/")
11409 (synopsis "Classic pen and paper game: five in a line")
11410 (description "Bovo is a Gomoku (from Japanese 五目並べ - lit. \"five
11411 points\") like game for two players, where the opponents alternate in placing
11412 their respective pictogram on the game board. The winner is the first to
11413 complete a line of five markers. (Also known as: Connect Five, Five in a row,
11414 X and O, Naughts and Crosses)
11415
11416 This package is part of the KDE games module.")
11417 (license (list license:gpl2+ license:fdl1.2+))))
11418
11419 (define-public killbots
11420 (package
11421 (name "killbots")
11422 (version "20.12.0")
11423 (source
11424 (origin
11425 (method url-fetch)
11426 (uri (string-append "mirror://kde/stable/release-service/" version
11427 "/src/killbots-" version ".tar.xz"))
11428 (sha256
11429 (base32 "1296gww42nwnai7y6m2qpjqpyc30p7z9chfv5rv0n48jvdhva88y"))))
11430 (build-system qt-build-system)
11431 (native-inputs
11432 (list extra-cmake-modules kdoctools))
11433 (inputs
11434 (list kcompletion
11435 kconfig
11436 kconfigwidgets
11437 kcoreaddons
11438 kcrash
11439 kdbusaddons
11440 ki18n
11441 kwidgetsaddons
11442 kxmlgui
11443 libkdegames
11444 qtbase-5
11445 qtdeclarative))
11446 (home-page "https://games.kde.org/")
11447 (synopsis "Port of the classic BSD console game robots")
11448 (description "Killbots is a simple game of evading killer robots.
11449
11450 Who created the robots and why they have been programmed to destroy, no one
11451 knows. All that is known is that the robots are numerous and their sole
11452 objective is to destroy you. Fortunately for you, their creator has focused
11453 on quantity rather than quality and as a result the robots are severely
11454 lacking in intelligence. Your superior wit and a fancy teleportation device
11455 are your only weapons against the never-ending stream of mindless automatons.
11456
11457 This package is part of the KDE games module.")
11458 (license (list license:gpl2+ license:fdl1.2+))))
11459
11460 (define-public ksnakeduel
11461 (package
11462 (name "ksnakeduel")
11463 (version "20.12.0")
11464 (source
11465 (origin
11466 (method url-fetch)
11467 (uri (string-append "mirror://kde/stable/release-service/" version
11468 "/src/ksnakeduel-" version ".tar.xz"))
11469 (sha256
11470 (base32 "0mp6g258n3xzvgf23jnhkw10xgwqwqdzqfdc6r9jq6a6m8v77swz"))))
11471 (build-system qt-build-system)
11472 (native-inputs
11473 (list extra-cmake-modules kdoctools))
11474 (inputs
11475 (list kcompletion
11476 kconfig
11477 kconfigwidgets
11478 kcoreaddons
11479 kcrash
11480 kdbusaddons
11481 kguiaddons
11482 ki18n
11483 kxmlgui
11484 libkdegames
11485 qtbase-5
11486 qtdeclarative
11487 qtsvg))
11488 (home-page "https://games.kde.org/")
11489 (synopsis "Snake race played against the computer")
11490 (description "KSnakeDuel is a fast action game where you steer a snake
11491 which has to eat food. While eating the snake grows. But once a player
11492 collides with the other snake or the wall the game is lost. This becomes of
11493 course more and more difficult the longer the snakes grow.
11494
11495 This package is part of the KDE games module.")
11496 (license (list license:gpl2+ license:fdl1.2+))))
11497
11498 (define-public kollision
11499 (package
11500 (name "kollision")
11501 (version "20.12.0")
11502 (source
11503 (origin
11504 (method url-fetch)
11505 (uri (string-append "mirror://kde/stable/release-service/" version
11506 "/src/kollision-" version ".tar.xz"))
11507 (sha256
11508 (base32 "180ybafizpwjsg80npy0l9142cjsnlyxwv9dz3bq6r8v4smn2g6b"))))
11509 (build-system qt-build-system)
11510 (native-inputs
11511 (list extra-cmake-modules kdoctools))
11512 (inputs
11513 (list kcompletion
11514 kconfig
11515 kcoreaddons
11516 kcrash
11517 kdbusaddons
11518 ki18n
11519 kwidgetsaddons
11520 kxmlgui
11521 libkdegames
11522 qtbase-5
11523 qtdeclarative))
11524 (home-page "https://games.kde.org/")
11525 (synopsis "Simple ball dodging game")
11526 (description "In Kollision you use mouse to control a small blue ball in a
11527 closed space environment filled with small red balls, which move about
11528 chaotically. Your goal is to avoid touching any of those red balls with your
11529 blue one, because the moment you do the game will be over. The longer you can
11530 stay in game the higher will your score be.
11531
11532 This package is part of the KDE games module.")
11533 (license (list license:gpl2+ license:fdl1.2+))))
11534
11535 (define-public knavalbattle
11536 (package
11537 (name "knavalbattle")
11538 (version "20.12.0")
11539 (source
11540 (origin
11541 (method url-fetch)
11542 (uri (string-append "mirror://kde/stable/release-service/" version
11543 "/src/knavalbattle-" version ".tar.xz"))
11544 (sha256
11545 (base32 "03rqf4avn61b0v340ymmzgp7s0axygjgxq1nlp5aaqbx70zcb4lq"))))
11546 (build-system qt-build-system)
11547 (native-inputs
11548 (list extra-cmake-modules kdoctools))
11549 (inputs
11550 (list kauth
11551 kcompletion
11552 kconfig
11553 kconfigwidgets
11554 kcoreaddons
11555 kcrash
11556 kdbusaddons
11557 kdnssd
11558 ki18n
11559 ktextwidgets
11560 kxmlgui
11561 libkdegames
11562 qtbase-5
11563 qtdeclarative))
11564 (home-page "https://games.kde.org/")
11565 (synopsis "Battleship board game with built-in game server")
11566 (description "KBattleship is a Battle Ship game for KDE.
11567
11568 Ships are placed on a board which represents the sea. Players try to hit each
11569 others ships in turns without knowing where they are placed. The first player
11570 to destroy all ships wins the game.
11571
11572 This package is part of the KDE games module.")
11573 (license (list license:gpl2+ license:fdl1.2+))))
11574
11575 (define-public kreversi
11576 (package
11577 (name "kreversi")
11578 (version "20.08.3")
11579 (source
11580 (origin
11581 (method url-fetch)
11582 (uri (string-append "mirror://kde/stable/release-service/" version
11583 "/src/kreversi-" version ".tar.xz"))
11584 (sha256
11585 (base32 "0d3y072q61xcik9lf0pz0c9njvarwlvf6hqv5fp5jyqaf2902pmi"))))
11586 (build-system qt-build-system)
11587 (native-inputs
11588 (list extra-cmake-modules kdoctools))
11589 (inputs
11590 (list kconfig
11591 kconfigwidgets
11592 kcoreaddons
11593 kcrash
11594 kdbusaddons
11595 kdeclarative
11596 ki18n
11597 kiconthemes
11598 kio
11599 kxmlgui
11600 libkdegames
11601 qtbase-5
11602 qtdeclarative
11603 qtsvg))
11604 (home-page "https://games.kde.org/")
11605 (synopsis "Old reversi board game, also known as othello")
11606 (description "KReversi is a simple one player strategy game played
11607 against the computer.
11608
11609 If a player's piece is captured by an opposing player, that piece is turned
11610 over to reveal the color of that player. A winner is declared when one player
11611 has more pieces of his own color on the board and there are no more possible
11612 moves.
11613
11614 This package is part of the KDE games module.")
11615 (license (list license:gpl2+ license:fdl1.2+))))
11616
11617 (define-public ksquares
11618 (package
11619 (name "ksquares")
11620 (version "20.12.0")
11621 (source
11622 (origin
11623 (method url-fetch)
11624 (uri (string-append "mirror://kde/stable/release-service/" version
11625 "/src/ksquares-" version ".tar.xz"))
11626 (sha256
11627 (base32 "0chd30byl2kww1k699vkygrxq2wdyvi84m2bimk23q96fl8h831y"))))
11628 (build-system qt-build-system)
11629 (native-inputs
11630 (list extra-cmake-modules kdoctools))
11631 (inputs
11632 (list kcompletion
11633 kconfig
11634 kconfigwidgets
11635 kcoreaddons
11636 kcrash
11637 kdbusaddons
11638 ki18n
11639 kwidgetsaddons
11640 kxmlgui
11641 libkdegames
11642 qtbase-5
11643 qtdeclarative))
11644 (home-page "https://games.kde.org/")
11645 (synopsis "Dots and Boxes game")
11646 (description "KSquares is an implementation of the popular paper based
11647 game Squares. Two players take turns connecting dots on a grid to complete
11648 squares, the player with the most squares wins.
11649
11650 This package is part of the KDE games module.")
11651 (license (list license:gpl2+ license:lgpl2.0+ license:fdl1.2+))))
11652
11653 (define-public kjumpingcube
11654 (package
11655 (name "kjumpingcube")
11656 (version "20.12.0")
11657 (source
11658 (origin
11659 (method url-fetch)
11660 (uri (string-append "mirror://kde/stable/release-service/" version
11661 "/src/kjumpingcube-" version ".tar.xz"))
11662 (sha256
11663 (base32 "1mk73il4jh15z5pm3fp65hsyvmrga11c3h7w96yamy2n2bbniapq"))))
11664 (build-system qt-build-system)
11665 (native-inputs
11666 (list extra-cmake-modules kdoctools))
11667 (inputs
11668 (list kconfig
11669 kconfigwidgets
11670 kcoreaddons
11671 kcrash
11672 kdbusaddons
11673 ki18n
11674 kio
11675 kwidgetsaddons
11676 kxmlgui
11677 libkdegames
11678 qtbase-5
11679 qtdeclarative
11680 qtsvg))
11681 (home-page "https://games.kde.org/")
11682 (synopsis "Simple tactical game for number-crunchers")
11683 (description "KJumpingcube is a simple tactical game for one or two
11684 players, played on a grid of numbered squares. Each turn, players compete for
11685 control of the board by capturing or adding to one square.
11686
11687 This package is part of the KDE games module.")
11688 (license (list license:gpl2+ license:fdl1.2+))))
11689
11690 (define-public xmoto
11691 (package
11692 (name "xmoto")
11693 (version "0.6.1")
11694 (source
11695 (origin
11696 (method git-fetch)
11697 (uri (git-reference
11698 (url "https://github.com/xmoto/xmoto")
11699 (commit version)))
11700 (file-name (git-file-name name version))
11701 (sha256
11702 (base32 "00f5ha79lfa2iiaz66wl0hl5dapa1l15qdr7m7knzi0ll7j6z66n"))
11703 (modules '((guix build utils)
11704 (ice-9 ftw)
11705 (srfi srfi-1)))
11706 ;; XXX: Remove some bundled libraries. Guix provides Chipmunk, but
11707 ;; it appears to be incompatible with the (older) one bundled.
11708 (snippet
11709 `(begin
11710 (let ((keep '("chipmunk" "glad" "md5sum")))
11711 (with-directory-excursion "vendor"
11712 (for-each delete-file-recursively
11713 (lset-difference string=?
11714 (scandir ".")
11715 (cons* "." ".." keep))))
11716 (substitute* "src/CMakeLists.txt"
11717 (("add_subdirectory\\(.*?/vendor/(.+?)\".*" line library)
11718 (if (member library keep) line ""))))
11719 #t))))
11720 (build-system cmake-build-system)
11721 (arguments
11722 `(#:tests? #f ;no test
11723 #:phases
11724 (modify-phases %standard-phases
11725 (add-after 'unpack 'fix-hard-coded-directory
11726 (lambda* (#:key outputs #:allow-other-keys)
11727 (substitute* "src/common/VFileIO.cpp"
11728 (("/usr/share")
11729 (string-append (assoc-ref outputs "out") "/share")))
11730 #t))
11731 (add-before 'build 'set-SDL
11732 ;; Set correct environment for SDL.
11733 (lambda* (#:key inputs #:allow-other-keys)
11734 (setenv "CPATH"
11735 (string-append
11736 (assoc-ref inputs "sdl") "/include/SDL:"
11737 (or (getenv "CPATH") "")))
11738 #t))
11739 (add-after 'install 'unbundle-fonts
11740 ;; Unbundle DejaVuSans TTF files.
11741 (lambda* (#:key outputs inputs #:allow-other-keys)
11742 (let ((font-dir (string-append (assoc-ref inputs "font-dejavu")
11743 "/share/fonts/truetype/"))
11744 (target-dir (string-append (assoc-ref outputs "out")
11745 "/share/xmoto/Textures/Fonts/")))
11746 (for-each (lambda (f)
11747 (let ((font (string-append font-dir f))
11748 (target (string-append target-dir f)))
11749 (delete-file target)
11750 (symlink font target)))
11751 '("DejaVuSans.ttf" "DejaVuSansMono.ttf"))
11752 #t))))))
11753 (native-inputs
11754 `(("gettext" ,gettext-minimal)
11755 ("pkg-config" ,pkg-config)))
11756 (inputs
11757 `(("bzip2" ,bzip2)
11758 ("curl" ,curl)
11759 ("font-dejavu" ,font-dejavu)
11760 ("glu" ,glu)
11761 ("libjpeg" ,libjpeg-turbo)
11762 ("libpng" ,libpng)
11763 ("libxdg-basedir" ,libxdg-basedir)
11764 ("libxml2" ,libxml2)
11765 ("lua" ,lua-5.1)
11766 ("ode" ,ode)
11767 ("sdl" ,(sdl-union (list sdl sdl-mixer sdl-net sdl-ttf)))
11768 ("sqlite" ,sqlite)
11769 ("zlib" ,zlib)))
11770 (home-page "https://xmoto.tuxfamily.org/")
11771 (synopsis "2D motocross platform game")
11772 (description
11773 "X-Moto is a challenging 2D motocross platform game, where
11774 physics play an all important role in the gameplay. You need to
11775 control your bike to its limit, if you want to have a chance finishing
11776 the more difficult challenges.")
11777 (license (list license:gpl2+ ;whole project
11778 license:bsd-3 ;vendor/md5sum
11779 license:lgpl2.1+
11780 license:expat))))
11781
11782 (define-public eboard
11783 (package
11784 (name "eboard")
11785 (version "1.1.3")
11786 (source
11787 (origin
11788 (method git-fetch)
11789 (uri (git-reference
11790 (url "https://github.com/fbergo/eboard")
11791 (commit (string-append "v" version))))
11792 (file-name (git-file-name name version))
11793 (sha256
11794 (base32 "1z4pwpqyvxhlda99h6arh2rjk90fbms9q29fqizjblrdn01dlxn1"))))
11795 (build-system gnu-build-system)
11796 (native-inputs
11797 (list perl pkg-config))
11798 (inputs
11799 (list gtk+-2 libpng gstreamer))
11800 (arguments
11801 `(#:tests? #f
11802 #:phases
11803 (modify-phases %standard-phases
11804 (replace 'configure
11805 (lambda* (#:key outputs #:allow-other-keys)
11806 (make-file-writable "eboard-config")
11807 (setenv "CC" "gcc")
11808 (invoke "./configure"
11809 (string-append "--prefix=" (assoc-ref outputs "out")))
11810 #t))
11811 (add-before 'install 'make-required-directories
11812 (lambda* (#:key outputs #:allow-other-keys)
11813 (mkdir-p (string-append (assoc-ref outputs "out")
11814 "/share/eboard"))
11815 #t)))))
11816 (synopsis "Graphical user interface to play chess")
11817 (description
11818 "Eboard is a chess board interface for ICS (Internet Chess Servers)
11819 and chess engines.")
11820 (home-page "https://www.bergo.eng.br/eboard/")
11821 (license license:gpl2+)))
11822
11823 (define-public chessx
11824 (package
11825 (name "chessx")
11826 (version "1.5.6")
11827 (source
11828 (origin
11829 (method url-fetch)
11830 (uri (string-append "mirror://sourceforge/chessx/chessx/"
11831 version "/chessx-" version ".tgz"))
11832 (sha256
11833 (base32 "01fjchil2h6ry2ywr0dwjw2g7zd29580cr4c74d5z74h999lp6nh"))))
11834 (build-system qt-build-system)
11835 (native-inputs
11836 (list qttools))
11837 (inputs
11838 (list qtbase-5 qtmultimedia qtspeech qtsvg zlib))
11839 (arguments
11840 `(#:tests? #f
11841 #:phases
11842 (modify-phases %standard-phases
11843 (add-after 'unpack 'fix-paths
11844 (lambda* (#:key inputs #:allow-other-keys)
11845 (substitute* "chessx.pro"
11846 (("\\$\\$\\[QT_INSTALL_BINS\\]/lrelease")
11847 (search-input-file inputs "/bin/lrelease")))))
11848 (add-after 'fix-paths 'make-qt-deterministic
11849 (lambda _
11850 (setenv "QT_RCC_SOURCE_DATE_OVERRIDE" "1")
11851 #t))
11852 (add-after 'make-qt-deterministic 'disable-versioncheck
11853 (lambda _
11854 (substitute* "src/database/settings.cpp"
11855 (("\"/General/onlineVersionCheck\", true")
11856 "\"/General/onlineVersionCheck\", false"))
11857 #t))
11858 (replace 'configure
11859 (lambda _
11860 (invoke "qmake")
11861 #t))
11862 (replace 'install
11863 (lambda* (#:key outputs #:allow-other-keys)
11864 (let ((out (assoc-ref outputs "out")))
11865 (install-file "release/chessx" (string-append out "/bin"))
11866 (install-file "unix/chessx.desktop"
11867 (string-append out "/share/applications")))
11868 #t)))))
11869 (synopsis "Chess game database")
11870 (description
11871 "ChessX is a chess database. With ChessX you can operate on your
11872 collection of chess games in many ways: browse, edit, add, organize, analyze,
11873 etc. You can also play games on FICS or against an engine.")
11874 (home-page "http://chessx.sourceforge.net/")
11875 (license license:gpl2+)))
11876
11877 (define-public stockfish
11878 (let ((neural-network-revision "13406b1dcbe0")) ; also update hash below
11879 (package
11880 (name "stockfish")
11881 (version "14.1")
11882 (source
11883 (origin
11884 (method git-fetch)
11885 (uri (git-reference
11886 (url "https://github.com/official-stockfish/Stockfish")
11887 (commit (string-append "sf_" version))))
11888 (file-name (git-file-name name version))
11889 (sha256
11890 (base32 "0apqqcgpcflm3c6mcl13ln2y04f6zksnljmk4ys7naf7xk4vdgkd"))))
11891 (build-system gnu-build-system)
11892 (inputs
11893 `(("neural-network"
11894 ,(origin
11895 (method url-fetch)
11896 (uri (string-append "https://tests.stockfishchess.org/api/nn/nn-"
11897 neural-network-revision ".nnue"))
11898 (sha256
11899 (base32
11900 "0vr3hcmlqqm74pn7hc54gmfs9drqvgc53nh7bvy6v8z0rcfnnh0k"))))))
11901 (arguments
11902 `(#:tests? #f
11903 #:make-flags (list "-C" "src"
11904 "build"
11905 (string-append "PREFIX="
11906 (assoc-ref %outputs "out"))
11907 (string-append "ARCH="
11908 ,(match (%current-system)
11909 ("x86_64-linux" "x86-64")
11910 ("i686-linux" "x86-32")
11911 ("aarch64-linux" "armv8")
11912 ("armhf-linux" "armv7")
11913 ("mips64el-linux" "general-64")
11914 (_ "general-32"))))
11915 #:phases (modify-phases %standard-phases
11916 (delete 'configure)
11917 ;; The official neural network file is needed for building
11918 ;; and is embedded in the resulting binary.
11919 (add-after 'unpack 'copy-net
11920 (lambda* (#:key inputs #:allow-other-keys)
11921 (copy-file (assoc-ref inputs "neural-network")
11922 (format #f "src/nn-~a.nnue"
11923 ,neural-network-revision)))))))
11924 (synopsis "Strong chess engine")
11925 (description
11926 "Stockfish is a very strong chess engine. It is much stronger than the
11927 best human chess grandmasters. It can be used with UCI-compatible GUIs like
11928 ChessX.")
11929 (home-page "https://stockfishchess.org/")
11930 (license license:gpl3+))))
11931
11932 (define-public barrage
11933 (package
11934 (name "barrage")
11935 (version "1.0.5")
11936 (source
11937 (origin
11938 (method url-fetch)
11939 (uri (string-append "mirror://sourceforge/lgames/barrage/"
11940 "barrage-" version ".tar.gz"))
11941 (sha256
11942 (base32 "0139wxyrir10cbkvkjn548xgmp84wax8mfwk80yxbxlcdamrg257"))))
11943 (build-system gnu-build-system)
11944 (inputs
11945 (list hicolor-icon-theme sdl sdl-mixer))
11946 (arguments
11947 `(#:configure-flags
11948 (list
11949 (string-append "CFLAGS="
11950 "-I" (assoc-ref %build-inputs "sdl-mixer")
11951 "/include/SDL"))))
11952 (home-page "http://lgames.sourceforge.net/Barrage/")
11953 (synopsis "Violent point-and-click shooting game with nice effects")
11954 (description
11955 "Barrage is a rather destructive action game that puts you on a shooting
11956 range with the objective to hit as many dummy targets as possible within
11957 3 minutes. You control a gun that may either fire small or large grenades at
11958 soldiers, jeeps and tanks. The gameplay is simple but it is not that easy to
11959 get high scores.")
11960 (license license:gpl2+)))
11961
11962 (define-public burgerspace
11963 (package
11964 (name "burgerspace")
11965 (version "1.9.4")
11966 (source
11967 (origin
11968 (method url-fetch)
11969 (uri (string-append "http://perso.b2b2c.ca/~sarrazip/dev/"
11970 "burgerspace-" version ".tar.gz"))
11971 (sha256
11972 (base32 "1xb4immzmd419aa08lgkzf7ibxa6ax238zb2l5iw9nkgvzlh1v6l"))))
11973 (build-system gnu-build-system)
11974 (native-inputs
11975 (list pkg-config))
11976 (inputs
11977 (list flatzebra))
11978 (home-page "http://perso.b2b2c.ca/~sarrazip/dev/burgerspace.html")
11979 (synopsis "Avoid evil foodstuffs and make burgers")
11980 (description
11981 "This is a clone of the classic game BurgerTime. In it, you play
11982 the part of a chef who must create burgers by stepping repeatedly on
11983 the ingredients until they fall into place. And to make things more
11984 complicated, you also must avoid evil animate food items while
11985 performing this task, with nothing but your trusty pepper shaker to
11986 protect you.")
11987 (license license:gpl2+)))
11988
11989 (define-public 7kaa
11990 (package
11991 (name "7kaa")
11992 (version "2.15.4p1")
11993 (source
11994 (origin
11995 (method url-fetch)
11996 (uri (string-append "https://github.com/the3dfxdude/7kaa/"
11997 "releases/download/v" version "/"
11998 "7kaa-" version ".tar.xz"))
11999 (sha256
12000 (base32 "1y7v0jhp3apb619p7asikqr1dnwb2yxbh40wbx1ppmr5f03mq9ph"))))
12001 (build-system gnu-build-system)
12002 (native-inputs
12003 (list gettext-minimal pkg-config))
12004 (inputs
12005 (list curl enet openal sdl2))
12006 (home-page "https://7kfans.com/")
12007 (synopsis "Seven Kingdoms Ancient Adversaries: real-time strategy game")
12008 (description
12009 "Seven Kingdoms, designed by Trevor Chan, brings a blend of Real-Time
12010 Strategy with the addition of trade, diplomacy, and espionage. The game
12011 enables players to compete against up to six other kingdoms allowing players
12012 to conquer opponents by defeating them in war (with troops or machines),
12013 capturing their buildings with spies, or offering opponents money for their
12014 kingdom.")
12015 (license license:gpl2+)))
12016
12017 (define-public neverball
12018 ;; Git version is 6-years younger than latest release.
12019 (let ((commit "760a25d32a5fb0661b99426d4ddcb9ac9f3d1644")
12020 (revision "1"))
12021 (package
12022 (name "neverball")
12023 (version (git-version "1.6.0" revision commit))
12024 (source
12025 (origin
12026 (method git-fetch)
12027 (uri (git-reference
12028 (url "https://github.com/Neverball/neverball")
12029 (commit commit)))
12030 (sha256
12031 (base32
12032 "0bwh67df3lyf33bv710y25l3frjdd34j9b7gsjadwxviz6r1vpj5"))
12033 (file-name (git-file-name name version))
12034 (modules '((guix build utils)))
12035 (snippet
12036 '(begin
12037 ;; Octocat seems to be non-free. Oddly, Debian doesn't strip it.
12038 (delete-file-recursively "data/ball/octocat")
12039 #t))))
12040 (build-system copy-build-system)
12041 (arguments
12042 `(#:install-plan
12043 '(("neverball" "bin/")
12044 ("neverputt" "bin/")
12045 ("mapc" "bin/")
12046 ("data" "share/games/neverball/")
12047 ("locale" "share/")
12048 ("dist/" "share/games/neverball" #:include ("neverball_replay.png"
12049 "neverlogos.svg"
12050 "svg readme.txt"))
12051 ("dist/" "share/applications" #:include ("neverball.desktop"
12052 "neverputt.desktop"))
12053 ("dist/neverball_16.png"
12054 "/share/icons/hicolor/16x16/apps/neverball.png")
12055 ("dist/neverball_24.png"
12056 "/share/icons/hicolor/24x24/apps/neverball.png")
12057 ("dist/neverball_32.png"
12058 "/share/icons/hicolor/32x32/apps/neverball.png")
12059 ("dist/neverball_48.png"
12060 "/share/icons/hicolor/48x48/apps/neverball.png")
12061 ("dist/neverball_64.png"
12062 "/share/icons/hicolor/64x64/apps/neverball.png")
12063 ("dist/neverball_128.png"
12064 "/share/icons/hicolor/128x128/apps/neverball.png")
12065 ("dist/neverball_256.png"
12066 "/share/icons/hicolor/256x256/apps/neverball.png")
12067 ("dist/neverball_512.png"
12068 "/share/icons/hicolor/512x512/apps/neverball.png")
12069 ("dist/neverputt_16.png"
12070 "/share/icons/hicolor/16x16/apps/neverputt.png")
12071 ("dist/neverputt_24.png"
12072 "/share/icons/hicolor/24x24/apps/neverputt.png")
12073 ("dist/neverputt_32.png"
12074 "/share/icons/hicolor/32x32/apps/neverputt.png")
12075 ("dist/neverputt_48.png"
12076 "/share/icons/hicolor/48x48/apps/neverputt.png")
12077 ("dist/neverputt_64.png"
12078 "/share/icons/hicolor/64x64/apps/neverputt.png")
12079 ("dist/neverputt_128.png"
12080 "/share/icons/hicolor/128x128/apps/neverputt.png")
12081 ("dist/neverputt_256.png"
12082 "/share/icons/hicolor/256x256/apps/neverputt.png")
12083 ("dist/neverputt_512.png"
12084 "/share/icons/hicolor/512x512/apps/neverputt.png")
12085 ("dist/" "share/man/man1" #:include ("mapc.1"))
12086 ("dist/" "share/man/man6" #:include ("neverball.6" "neverputt.6"))
12087 ("doc/" "share/doc/neverball")
12088 ("README.md" "share/doc/neverball/"))
12089 #:phases
12090 (modify-phases %standard-phases
12091 (add-before 'install 'build
12092 (lambda* (#:key inputs outputs #:allow-other-keys)
12093 (let* ((out (assoc-ref outputs "out"))
12094 (sdl (assoc-ref inputs "sdl")))
12095 (invoke "make" "-j" (number->string (parallel-job-count))
12096 "--environment-overrides"
12097 "CC=gcc" "BUILD=release"
12098 (string-append "DATADIR="
12099 out
12100 "/share/games/neverball/data")
12101 (string-append "LOCALEDIR=" out "/share/locale")
12102 (string-append "SDL_CPPFLAGS=-I"
12103 sdl
12104 "/include/SDL2/")))
12105 #t))
12106 (add-after 'install 'fix-some-broken-fonts
12107 (lambda* (#:key outputs #:allow-other-keys)
12108 (let* ((out (assoc-ref outputs "out")))
12109 (wrap-program (string-append out "/bin/neverball")
12110 `("LANG" = ("en_US.utf8")))
12111 (wrap-program (string-append out "/bin/neverputt")
12112 `("LANG" = ("en_US.utf8"))))
12113 #t)))))
12114 (native-inputs
12115 `(("gettext" ,gettext-minimal))) ;for msgfmt
12116 (inputs
12117 `(("libjpeg" ,libjpeg-turbo)
12118 ("libpng" ,libpng)
12119 ("libvorbis" ,libvorbis)
12120 ("physfs" ,physfs)
12121 ("sdl" ,(sdl-union (list sdl2 sdl2-ttf)))))
12122 (home-page "https://neverball.org/")
12123 (synopsis "3D floor-tilting game")
12124 (description
12125 "In the grand tradition of Marble Madness and Super Monkey Ball,
12126 Neverball has you guide a rolling ball through dangerous territory. Balance
12127 on narrow bridges, navigate mazes, ride moving platforms, and dodge pushers
12128 and shovers to get to the goal. Race against the clock to collect coins to
12129 earn extra balls. Also included is Neverputt, which is a 3D miniature golf
12130 game.") ;thanks to Debian for description
12131 (license license:gpl2+))))
12132
12133 (define-public pokerth
12134 (package
12135 (name "pokerth")
12136 (version "1.1.2")
12137 (source
12138 (origin
12139 (method url-fetch)
12140 (uri (string-append "mirror://sourceforge/pokerth/pokerth/"
12141 version "/pokerth-" version ".tar.gz"))
12142 (sha256
12143 (base32 "0yi9bj3k8yc1gkwmaf14zbbvvn13n54n1dli8k6j1pkph3p3vjq2"))
12144 (modules '((guix build utils)))
12145 (snippet
12146 '(begin
12147 ;; Remove bundled websocketpp.
12148 (delete-file-recursively "src/third_party/websocketpp")
12149 (substitute* "pokerth_lib.pro"
12150 (("src/third_party/websocketpp")
12151 ""))
12152 #t))))
12153 (build-system qt-build-system)
12154 (inputs
12155 `(("boost" ,boost)
12156 ("curl" ,curl)
12157 ("gsasl" ,gsasl)
12158 ("libgcrypt" ,libgcrypt)
12159 ("libircclient" ,libircclient)
12160 ("protobuf" ,protobuf-2) ; remove package when no longer needed
12161 ("qtbase" ,qtbase-5)
12162 ("sdl" ,(sdl-union (list sdl sdl-mixer)))
12163 ("sqlite" ,sqlite)
12164 ("tinyxml" ,tinyxml)
12165 ("websocketpp" ,websocketpp)
12166 ("zlib" ,zlib)))
12167 (arguments
12168 `(#:tests? #f ; No test suite
12169 #:phases
12170 (modify-phases %standard-phases
12171 (add-after 'unpack 'fix-paths
12172 (lambda* (#:key inputs #:allow-other-keys)
12173 (substitute* (find-files "." "\\.pro$")
12174 (("/opt/gsasl")
12175 (assoc-ref inputs "gsasl"))
12176 (("\\$\\$\\{PREFIX\\}/include/libircclient")
12177 (search-input-directory inputs "/include/libircclient"))
12178 (("LIB_DIRS =")
12179 (string-append "LIB_DIRS = "
12180 (assoc-ref inputs "boost") "/lib")))
12181 #t))
12182 (add-after 'unpack 'fix-build
12183 (lambda _
12184 ;; Fixes for Boost versions >= 1.66.
12185 (substitute* '("src/net/common/clientthread.cpp"
12186 "src/net/serveraccepthelper.h")
12187 (("boost::asio::socket_base::non_blocking_io command\\(true\\);")
12188 "")
12189 (("newSock->io_control\\(command\\);")
12190 "newSock->non_blocking(true);")
12191 (("acceptedSocket->io_control\\(command\\);")
12192 "acceptedSocket->non_blocking(true);"))
12193 #t))
12194 (replace 'configure
12195 (lambda* (#:key outputs #:allow-other-keys)
12196 (invoke "qmake" "pokerth.pro" "CONFIG+=client"
12197 (string-append "PREFIX=" (assoc-ref outputs "out"))))))))
12198 (home-page "https://www.pokerth.net")
12199 (synopsis "Texas holdem poker game")
12200 (description
12201 "With PokerTH you can play the Texas holdem poker game, either against
12202 computer opponents or against real players online.")
12203 (license license:agpl3+)))
12204
12205 (define-public azimuth
12206 (package
12207 (name "azimuth")
12208 ;; Not marked as latest release, but it fixes a compiling issue
12209 ;; and adds the install target.
12210 (version "1.0.3")
12211 (source
12212 (origin
12213 (method git-fetch)
12214 (uri (git-reference
12215 (url "https://github.com/mdsteele/azimuth")
12216 (commit (string-append "v" version))))
12217 (file-name (git-file-name name version))
12218 (sha256
12219 (base32
12220 "1znfvpmqiixd977jv748glk5zc4cmhw5813zp81waj07r9b0828r"))))
12221 (build-system gnu-build-system)
12222 (arguments
12223 `(#:test-target "test"
12224 #:phases
12225 (modify-phases %standard-phases
12226 (delete 'configure) ; no configure script
12227 ;; Build release version instead of debug version.
12228 (add-after 'unpack 'set-release
12229 (lambda _
12230 (setenv "BUILDTYPE" "release") #t))
12231 (add-after 'unpack 'fix-install ; set install directory
12232 (lambda* (#:key outputs #:allow-other-keys)
12233 (substitute* "Makefile" (("/usr") (assoc-ref outputs "out"))) #t)))))
12234 (inputs (list sdl))
12235 (home-page "https://mdsteele.games/azimuth/")
12236 (synopsis "Metroidvania game with vector graphics")
12237 (description
12238 "Pilot your ship inside a planet to find and rescue the colonists trapped
12239 inside the Zenith Colony.")
12240 (license license:gpl3+)))
12241
12242 (define-public cgoban
12243 (package
12244 (name "cgoban")
12245 (version "1.9.14")
12246 (source
12247 (origin
12248 (method url-fetch)
12249 (uri (string-append "mirror://sourceforge/cgoban1/cgoban1/"
12250 version "/cgoban-" version ".tar.gz"))
12251 (sha256
12252 (base32 "0qlvkiaglqq0izfph3l04mp4rqqqm9ks6rcsrmzrggw9x706z2iv"))))
12253 (build-system gnu-build-system)
12254 (inputs
12255 (list libx11 libxt xorgproto))
12256 (home-page "http://cgoban1.sourceforge.net/")
12257 (synopsis "Go client for X11")
12258 (description "Provides a large set of Go-related services for X11:
12259 @itemize
12260 @item Local games with precise implementation of the Chinese and Japanese rulesets
12261 @item Edition and visualization of SGF files-Connection to the NNGS or IGS Go servers
12262 @item Bridge to Go modem protocol, allowing to play against Go modem-capable AIs
12263 such as GnuGo.
12264 @end itemize")
12265 (license license:gpl2+)))
12266
12267 (define-public passage
12268 (package
12269 (name "passage")
12270 (version "4")
12271 (source
12272 (origin
12273 (method url-fetch)
12274 (uri (string-append "mirror://sourceforge/hcsoftware/Passage/v"
12275 version "/Passage_v" version "_UnixSource.tar.gz"))
12276 (sha256
12277 (base32 "02ky4a4xdjvr71r58339jjrjyz76b5skcnbq4f8707mrln9vhby3"))))
12278 (build-system gnu-build-system)
12279 (arguments
12280 `(#:tests? #false ; there are none
12281 #:phases
12282 (modify-phases %standard-phases
12283 (add-after 'unpack 'chdir
12284 (lambda _
12285 (chdir "gamma256/gameSource")
12286 (system "cat Makefile.GnuLinux Makefile.all > Makefile")))
12287 (replace 'configure
12288 (lambda* (#:key outputs inputs #:allow-other-keys)
12289 (setenv "CPATH"
12290 (string-append
12291 (assoc-ref inputs "sdl") "/include/SDL:"
12292 (or (getenv "CPATH") "")))
12293 (let* ((out (assoc-ref outputs "out"))
12294 (assets (string-append out "/share/passage")))
12295 (substitute* "common.cpp"
12296 (("readTGA\\( \"graphics\"")
12297 (format #false "readTGA(\"~a/graphics\"" assets)))
12298 (substitute* "musicPlayer.cpp"
12299 (("readTGA\\( \"music\"")
12300 (format #false "readTGA(\"~a/music\"" assets))))))
12301 (replace 'install
12302 (lambda* (#:key outputs #:allow-other-keys)
12303 (let* ((out (assoc-ref outputs "out"))
12304 (bin (string-append out "/bin"))
12305 (assets (string-append out "/share/passage/")))
12306 (install-file "Passage" bin)
12307 (install-file "../documentation/Readme.txt" assets)
12308 (copy-recursively "graphics" (string-append assets "graphics"))
12309 (copy-recursively "music" (string-append assets "music"))
12310 (copy-recursively "settings" (string-append assets "settings"))))))))
12311 (inputs
12312 `(("sdl" ,(sdl-union (list sdl sdl-mixer)))))
12313 (native-inputs
12314 (list imagemagick))
12315 (home-page "http://hcsoftware.sourceforge.net/passage/")
12316 (synopsis "Memento mori game")
12317 (description
12318 "Passage is meant to be a memento mori game. It presents an entire life,
12319 from young adulthood through old age and death, in the span of five minutes.
12320 Of course, it's a game, not a painting or a film, so the choices that you make
12321 as the player are crucial. There's no ``right'' way to play Passage, just as
12322 there's no right way to interpret it.")
12323 (license license:public-domain)))
12324
12325 (define-public paperview
12326 (let ((commit "9f8538eb6734c76877b878b8f1e52587f2ae19e6")
12327 (revision "1"))
12328 (package
12329 (name "paperview")
12330 (version (git-version "0.0.1" revision commit)) ;no upstream release
12331 (source (origin
12332 (method git-fetch)
12333 (uri (git-reference
12334 (url "https://github.com/glouw/paperview")
12335 (commit commit)))
12336 (file-name (git-file-name name version))
12337 (sha256
12338 (base32
12339 "09sb9sg44fvkgfdyycrm1ndpx7cnkrglxhci41y8f3gpagnvi7jk"))))
12340 (build-system gnu-build-system)
12341 (inputs
12342 (list sdl2))
12343 (arguments
12344 '(#:tests? #f ;no tests
12345 #:make-flags
12346 (list (string-append "PREFIX=" (assoc-ref %outputs "out")))
12347 #:phases
12348 (modify-phases %standard-phases
12349 (delete 'configure))))
12350 (home-page "https://github.com/glouw/paperview/")
12351 (synopsis "High performance X11 animated wallpaper setter")
12352 (description "High performance animated desktop background setter for
12353 X11 that won't set your CPU on fire, drain your laptop battery, or lower video
12354 game FPS.")
12355 (license license:unlicense))))
12356
12357 (define-public curseofwar
12358 (package
12359 (name "curseofwar")
12360 (version "1.3.0")
12361 (source
12362 (origin
12363 (method git-fetch)
12364 (uri (git-reference
12365 (url "https://github.com/a-nikolaev/curseofwar")
12366 (commit (string-append "v" version))))
12367 (file-name (git-file-name name version))
12368 (sha256
12369 (base32 "1wd71wdnj9izg5d95m81yx3684g4zdi7fsy0j5wwnbd9j34ilz1i"))))
12370 (build-system gnu-build-system)
12371 (arguments
12372 `(#:tests? #f ; no tests
12373 #:make-flags
12374 (list (string-append "CC=" ,(cc-for-target))
12375 (string-append "PREFIX=" (assoc-ref %outputs "out")))
12376 #:phases
12377 (modify-phases %standard-phases
12378 (delete 'configure))))
12379 (inputs (list ncurses))
12380 (home-page "https://a-nikolaev.github.io/curseofwar/")
12381 (synopsis "Fast-paced action strategy game")
12382 (description "Curse of War is a fast-paced action strategy game originally
12383 implemented using ncurses user interface. An SDL graphical version is also
12384 available.")
12385 (license license:gpl3+)))
12386
12387 (define-public schiffbruch
12388 ;; There haven't been any releases for several years, so I've taken the most
12389 ;; recent commit from the master branch that didn't fail to build (the last
12390 ;; commit gave me a compile error).
12391 (let ((commit "e41916d15d87749c82c5005cbb42d1bb079b43d9"))
12392 (package
12393 (name "schiffbruch")
12394 (version (git-version "1.2.1" "0" commit))
12395 (source
12396 (origin
12397 (method git-fetch)
12398 (uri (git-reference
12399 (url "https://github.com/sandsmark/Schiffbruch")
12400 (commit commit)))
12401 (file-name (git-file-name name version))
12402 (sha256
12403 (base32 "0lg3rqacrapf6c4sxi12cm9bmg43mlbclway1zxcm848pi1xkzwv"))))
12404 (build-system cmake-build-system)
12405 (arguments
12406 `(#:tests? #f ; no tests
12407 #:build-type "Release"))
12408 (native-inputs
12409 (list gcc-11)) ; need C++20-compatible compiler
12410 (inputs
12411 (list sfml))
12412 (home-page "https://github.com/sandsmark/Schiffbruch/")
12413 (synopsis "Pixelart survival game")
12414 (description
12415 "Schiffbruch is a mix of building, strategy and adventure and gets played
12416 with a two-dimensional view. The game deals with the consequences of a ship
12417 wreckage. You're stranded on a desert island and have to survive. In order to
12418 do so you need to explore the island, find food, build a shelter and try to
12419 get attention, so you get found.")
12420 (license license:cc-by4.0))))
12421
12422 (define-public sdlpop
12423 (package
12424 (name "sdlpop")
12425 (version "1.22")
12426 (source (origin
12427 (method git-fetch)
12428 (uri (git-reference
12429 (url "https://github.com/NagyD/SDLPoP")
12430 (commit (string-append "v" version))))
12431 (file-name (git-file-name name version))
12432 (sha256
12433 (base32
12434 "1yy5r1r0hv0xggk8qd8bwk2zy7abpv89nikq4flqgi53fc5q9xl7"))))
12435 (build-system gnu-build-system)
12436 (arguments
12437 `(#:tests? #f ; no tests provided
12438 #:phases
12439 (modify-phases %standard-phases
12440 (delete 'configure)
12441 (add-before 'build 'prepare-build
12442 ;; Set correct environment for SDL.
12443 (lambda* (#:key inputs #:allow-other-keys)
12444 (setenv "CPATH"
12445 (string-append (assoc-ref inputs "sdl")
12446 "/include/SDL2:"
12447 (or (getenv "CPATH") "")))))
12448 (add-after 'unpack 'chdir
12449 (lambda _
12450 (chdir "src")))
12451 (replace 'install
12452 (lambda* (#:key outputs #:allow-other-keys)
12453 (let* ((out (assoc-ref outputs "out"))
12454 (bin (string-append out "/bin"))
12455 (opt (string-append out "/opt/sdlpop"))
12456 (app (string-append out "/usr/share/applications"))
12457 (template "src/SDLPoP.desktop.template"))
12458 (chdir "..")
12459 (install-file "prince" bin)
12460 (substitute* template (("\\$ROOT") out))
12461 (substitute* "src/seg009.c"
12462 (("g_argv[0]") (string-append "\"" out "\"")))
12463 (install-file template app)
12464 (rename-file (string-append app "/SDLPoP.desktop.template")
12465 (string-append app "/SDLPoP.desktop"))
12466 (install-file "SDLPoP.ini" opt)
12467 (copy-recursively "data" (string-append bin "/data"))
12468 (copy-recursively "doc" opt)
12469 (copy-recursively "mods" opt)))))))
12470 (native-inputs (list pkg-config))
12471 (inputs `(("sdl" ,(sdl-union (list sdl2
12472 sdl2-image
12473 sdl2-mixer)))))
12474 (synopsis "Port of Prince of Persia game")
12475 (description "This package provides port of Prince of Persia, based on the
12476 disassembly of the DOS version, extended with new features.")
12477 (home-page "https://github.com/NagyD/SDLPoP")
12478 (license license:gpl3+)))
12479
12480 (define-public fheroes2
12481 (package
12482 (name "fheroes2")
12483 (version "0.9.9")
12484 (build-system cmake-build-system)
12485 (arguments
12486 `(#:tests? #f ; no tests
12487 #:make-flags '("FHEROES2_STRICT_COMPILATION=1"
12488 "RELEASE=1")))
12489 (native-inputs
12490 `(("gettext" ,gettext-minimal)))
12491 (inputs
12492 `(("libpng" ,libpng)
12493 ("sdl" ,(sdl-union (list sdl2 sdl2-image sdl2-mixer sdl2-ttf)))
12494 ("zlib" ,zlib)))
12495 (source
12496 (origin
12497 (method git-fetch)
12498 (uri (git-reference
12499 (url "https://github.com/ihhub/fheroes2")
12500 (commit version)))
12501 (file-name (git-file-name name version))
12502 (sha256
12503 (base32 "030kfaagxy3i7bjvbx2nf05jmbbh5g2r52l17y9bl6vbfj67yvxy"))))
12504 (home-page "https://ihhub.github.io/fheroes2/")
12505 (synopsis "Turn-based strategy game engine")
12506 (description "@code{fheroes2} is an implementation of Heroes of Might and
12507 Magic II (aka HOMM2) game engine. It requires assets and game resources to
12508 play; it will look for them at @file{~/.local/share/fheroes2} folder.")
12509 (license license:gpl2)))