gnu: Fix common unquote typos.
[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, 2016 David Thompson <dthompson2@worcester.edu>
5 ;;; Copyright © 2014, 2015, 2016, 2017 Eric Bavier <bavier@member.fsf.org>
6 ;;; Copyright © 2014 Cyrill Schenkel <cyrill.schenkel@gmail.com>
7 ;;; Copyright © 2014 Sylvain Beucler <beuc@beuc.net>
8 ;;; Copyright © 2014, 2015 Ludovic Courtès <ludo@gnu.org>
9 ;;; Copyright © 2014, 2015, 2016 Sou Bunnbu <iyzsong@gmail.com>
10 ;;; Copyright © 2014, 2015 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 Christopher Allan Webber <cwebber@dustycloud.org>
14 ;;; Copyright © 2015, 2016, 2017, 2018 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 ng0 <ng0@n0.is>
19 ;;; Copyright © 2016 Albin Söderqvist <albin@fripost.org>
20 ;;; Copyright © 2016, 2017, 2018 Kei Kebreau <kkebreau@posteo.net>
21 ;;; Copyright © 2016 Alex Griffin <a@ajgrf.com>
22 ;;; Copyright © 2016, 2017 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 Arun Isaac <arunisaac@systemreboot.net>
27 ;;; Copyright © 2017 Tobias Geerinckx-Rice <me@tobias.gr>
28 ;;; Copyright © 2017 nee <nee-git@hidamari.blue>
29 ;;; Copyright © 2017 Clément Lassieur <clement@lassieur.org>
30 ;;; Copyright © 2017 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 Nicolas Goaziou <mail@nicolasgoaziou.fr>
34 ;;; Copyright © 2018 okapi <okapi@firemail.cc>
35 ;;;
36 ;;; This file is part of GNU Guix.
37 ;;;
38 ;;; GNU Guix is free software; you can redistribute it and/or modify it
39 ;;; under the terms of the GNU General Public License as published by
40 ;;; the Free Software Foundation; either version 3 of the License, or (at
41 ;;; your option) any later version.
42 ;;;
43 ;;; GNU Guix is distributed in the hope that it will be useful, but
44 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
45 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
46 ;;; GNU General Public License for more details.
47 ;;;
48 ;;; You should have received a copy of the GNU General Public License
49 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
50
51 (define-module (gnu packages games)
52 #:use-module (ice-9 match)
53 #:use-module ((guix licenses) #:prefix license:)
54 #:use-module (guix utils)
55 #:use-module (guix packages)
56 #:use-module (guix download)
57 #:use-module (guix git-download)
58 #:use-module (guix svn-download)
59 #:use-module (guix gexp)
60 #:use-module (gnu packages)
61 #:use-module (gnu packages algebra)
62 #:use-module (gnu packages autotools)
63 #:use-module (gnu packages backup)
64 #:use-module (gnu packages base)
65 #:use-module (gnu packages build-tools)
66 #:use-module (gnu packages admin)
67 #:use-module (gnu packages audio)
68 #:use-module (gnu packages avahi)
69 #:use-module (gnu packages boost)
70 #:use-module (gnu packages documentation)
71 #:use-module (gnu packages docbook)
72 #:use-module (gnu packages fltk)
73 #:use-module (gnu packages freedesktop)
74 #:use-module (gnu packages fribidi)
75 #:use-module (gnu packages game-development)
76 #:use-module (gnu packages gettext)
77 #:use-module (gnu packages ghostscript)
78 #:use-module (gnu packages gimp)
79 #:use-module (gnu packages gl)
80 #:use-module (gnu packages glib)
81 #:use-module (gnu packages gnome)
82 #:use-module (gnu packages gperf)
83 #:use-module (gnu packages graphics)
84 #:use-module (gnu packages gtk)
85 #:use-module (gnu packages guile)
86 #:use-module (gnu packages imagemagick)
87 #:use-module (gnu packages libcanberra)
88 #:use-module (gnu packages libedit)
89 #:use-module (gnu packages libunwind)
90 #:use-module (gnu packages haskell)
91 #:use-module (gnu packages mp3)
92 #:use-module (gnu packages music)
93 #:use-module (gnu packages icu4c)
94 #:use-module (gnu packages image)
95 #:use-module (gnu packages ncurses)
96 #:use-module (gnu packages netpbm)
97 #:use-module (gnu packages networking)
98 #:use-module (gnu packages ocaml)
99 #:use-module (gnu packages python)
100 #:use-module (gnu packages readline)
101 #:use-module (gnu packages textutils)
102 #:use-module (gnu packages xorg)
103 #:use-module (gnu packages pkg-config)
104 #:use-module (gnu packages databases)
105 #:use-module (gnu packages shells)
106 #:use-module (gnu packages sdl)
107 #:use-module (gnu packages swig)
108 #:use-module (gnu packages texinfo)
109 #:use-module (gnu packages check)
110 #:use-module (gnu packages fonts)
111 #:use-module (gnu packages fontutils)
112 #:use-module (gnu packages gstreamer)
113 #:use-module (gnu packages bash)
114 #:use-module (gnu packages perl)
115 #:use-module (gnu packages qt)
116 #:use-module (gnu packages compression)
117 #:use-module (gnu packages pulseaudio)
118 #:use-module (gnu packages linux)
119 #:use-module (gnu packages xiph)
120 #:use-module (gnu packages curl)
121 #:use-module (gnu packages lua)
122 #:use-module (gnu packages video)
123 #:use-module (gnu packages xml)
124 #:use-module (gnu packages tcl)
125 #:use-module (gnu packages xdisorg)
126 #:use-module (gnu packages tls)
127 #:use-module (gnu packages pcre)
128 #:use-module (gnu packages cyrus-sasl)
129 #:use-module (gnu packages messaging)
130 #:use-module (gnu packages upnp)
131 #:use-module (gnu packages wxwidgets)
132 #:use-module (gnu packages bison)
133 #:use-module (gnu packages flex)
134 #:use-module (gnu packages cmake)
135 #:use-module (gnu packages gnuzilla)
136 #:use-module (gnu packages icu4c)
137 #:use-module (gnu packages networking)
138 #:use-module (gnu packages vulkan)
139 #:use-module (gnu packages web)
140 #:use-module (guix build-system gnu)
141 #:use-module (guix build-system go)
142 #:use-module (guix build-system haskell)
143 #:use-module (guix build-system python)
144 #:use-module (guix build-system cmake)
145 #:use-module (guix build-system trivial))
146
147 (define-public armagetronad
148 (package
149 (name "armagetronad")
150 (version "0.2.8.3.4")
151 (source (origin
152 (method url-fetch)
153 (uri (string-append "mirror://sourceforge/" name "/stable/"
154 version "/" name "-" version ".src.tar.gz"))
155 (sha256
156 (base32
157 "1pgy0r80z702qdv94aw3ywdn4ynnr4cdi86ml558pljfc5ygasj4"))))
158 (build-system gnu-build-system)
159 (inputs
160 `(("libxml2" ,libxml2)
161 ("sdl" ,sdl)
162 ("sdl-image" ,sdl-image)
163 ("freeglut" ,freeglut)
164 ("libpng" ,libpng)
165 ("libjpeg-turbo" ,libjpeg-turbo)))
166 (home-page "http://www.armagetronad.org")
167 (synopsis "Tron clone in 3D")
168 (description "Armagetron is a multiplayer game in 3d that attempts to
169 emulate and expand on the lightcycle sequence from the movie Tron. It's
170 an old school arcade game slung into the 21st century. Highlights include
171 a customizable playing arena, HUD, unique graphics, and AI bots. For the
172 more advanced player there are new game modes and a wide variety of physics
173 settings to tweak as well.")
174 (license license:gpl2+)))
175
176 (define-public cataclysm-dda
177 (package
178 (name "cataclysm-dda")
179 (version "0.C")
180 (source (origin
181 (method url-fetch)
182 (uri (string-append "https://github.com/CleverRaven/Cataclysm-DDA/"
183 "archive/" version ".tar.gz"))
184 (file-name (string-append name "-" version ".tar.gz"))
185 (sha256
186 (base32
187 "1xlajmgl9cviqyjpp5g5q4rbljy9gqc49v54bi8gpzr68s14gsb9"))
188 (modules '((guix build utils)))
189 (snippet
190 ;; Import cmath header for the std::pow function.
191 '(for-each (lambda (file)
192 (substitute* file
193 (("#include <math.h>")
194 "#include <cmath>")))
195 (find-files "src")))))
196 (build-system gnu-build-system)
197 (arguments
198 '(#:make-flags (list (string-append "PREFIX=" (assoc-ref %outputs "out"))
199 "USE_HOME_DIR=1" "DYNAMIC_LINKING=1" "RELEASE=1")
200 #:phases
201 (modify-phases %standard-phases
202 (replace 'configure
203 (lambda _
204 (substitute* "Makefile"
205 (("ncursesw5-config") "ncursesw6-config")
206 (("RELEASE_FLAGS = -Werror") "RELEASE_FLAGS ="))
207 #t))
208 (add-after 'build 'build-tiles
209 (lambda* (#:key make-flags outputs #:allow-other-keys)
210 ;; Change prefix directory and enable tile graphics and sound.
211 (zero?
212 (apply system* "make" "TILES=1" "SOUND=1"
213 (string-append "PREFIX="
214 (assoc-ref outputs "tiles"))
215 (cdr make-flags)))))
216 (add-after 'install 'install-tiles
217 (lambda* (#:key make-flags outputs #:allow-other-keys)
218 (zero?
219 (apply system* "make" "install" "TILES=1" "SOUND=1"
220 (string-append "PREFIX="
221 (assoc-ref outputs "tiles"))
222 (cdr make-flags))))))
223 ;; TODO: Add libtap++ from https://github.com/cbab/libtappp as a native
224 ;; input in order to support tests.
225 #:tests? #f))
226 (outputs '("out"
227 "tiles")) ; For tile graphics and sound support.
228 (native-inputs
229 `(("gettext" ,gettext-minimal)
230 ("pkg-config" ,pkg-config)))
231 (inputs
232 `(("freetype" ,freetype)
233 ("libogg" ,libogg)
234 ("libvorbis" ,libvorbis)
235 ("ncurses" ,ncurses)
236 ("sdl2" ,sdl2)
237 ("sdl2-image" ,sdl2-image)
238 ("sdl2-ttf" ,sdl2-ttf)
239 ("sdl2-mixer" ,sdl2-mixer)))
240 (home-page "http://en.cataclysmdda.com/")
241 (synopsis "Survival horror roguelike video game")
242 (description
243 "Cataclysm: Dark Days Ahead is a roguelike set in a post-apocalyptic world.
244 Struggle to survive in a harsh, persistent, procedurally generated world.
245 Scavenge the remnants of a dead civilization for food, equipment, or, if you are
246 lucky, a vehicle with a full tank of gas to get you out of Dodge. Fight to
247 defeat or escape from a wide variety of powerful monstrosities, from zombies to
248 giant insects to killer robots and things far stranger and deadlier, and against
249 the others like yourself, that want what you have.")
250 (license license:cc-by-sa3.0)))
251
252 (define-public cowsay
253 (package
254 (name "cowsay")
255 (version "3.04")
256 (source (origin
257 (method url-fetch)
258 (uri (string-append "https://github.com/tnalpgge/"
259 "rank-amateur-cowsay/archive/"
260 name "-" version ".tar.gz"))
261 (sha256
262 (base32
263 "12w7apbf6a9qffk92r32b16w22na2fjcqbl32rn0n7zw5hrp3f6q"))))
264 (build-system gnu-build-system)
265 (arguments
266 `(#:phases
267 (modify-phases %standard-phases
268 (delete 'configure) ; no configure script
269 (delete 'build) ; nothing to be built
270 (replace 'install
271 (lambda* (#:key outputs #:allow-other-keys)
272 (zero? (system* "sh" "install.sh"
273 (assoc-ref outputs "out")))))
274 (delete 'check)
275 (add-after 'install 'check
276 (lambda* (#:key outputs #:allow-other-keys)
277 (zero? (system* (string-append (assoc-ref outputs "out")
278 "/bin/cowsay")
279 "We're done!")))))))
280 (inputs
281 `(("perl" ,perl)))
282 (home-page (string-append "https://web.archive.org/web/20071026043648/"
283 "http://www.nog.net:80/~tony/warez/cowsay.shtml"))
284 (synopsis "Speaking cow text filter")
285 (description "Cowsay is basically a text filter. Send some text into it,
286 and you get a cow saying your text. If you think a talking cow isn't enough,
287 cows can think too: all you have to do is run @command{cowthink}. If you're
288 tired of cows, a variety of other ASCII-art messengers are available.")
289 (license license:gpl3+)))
290
291 (define-public freedoom
292 (package
293 (name "freedoom")
294 (version "0.11.3")
295 (source (origin
296 (method url-fetch)
297 (uri (string-append "https://github.com/" name "/" name
298 "/archive/v" version ".tar.gz"))
299 (file-name (string-append name "-" version ".tar.gz"))
300 (sha256
301 (base32
302 "1bjijdfqhpazyifx1qda7scj7dry1azhjrnl8h8zn2vqfgdmlh0q"))))
303 (build-system gnu-build-system)
304 (arguments
305 '(#:make-flags `(,(string-append "prefix=" (assoc-ref %outputs "out")))
306 #:parallel-build? #f
307 #:tests? #f ; no check target
308 #:phases
309 (modify-phases %standard-phases
310 (replace 'configure
311 (lambda* (#:key inputs outputs #:allow-other-keys)
312 (let* ((dejavu (assoc-ref inputs "font-dejavu"))
313 (freedoom (assoc-ref outputs "out"))
314 (wad-dir (string-append freedoom "/share/games/doom")))
315 ;; Replace the font-searching function in a shell
316 ;; script with a direct path to the required font.
317 ;; This is necessary because ImageMagick can only find the
318 ;; most basic fonts while in the build environment.
319 (substitute* "graphics/titlepic/create_caption"
320 (("font=\\$\\(find_font.*$")
321 (string-append
322 "font=" dejavu
323 "/share/fonts/truetype/DejaVuSansCondensed-Bold.ttf\n")))
324 ;; Make icon creation reproducible.
325 (substitute* "dist/Makefile"
326 (("freedm.png")
327 "-define png:exclude-chunks=date freedm.png")
328 (("freedoom1.png")
329 "-define png:exclude-chunks=date freedoom1.png")
330 (("freedoom2.png")
331 "-define png:exclude-chunks=date freedoom2.png"))
332 ;; Make sure that the install scripts know where to find
333 ;; the appropriate WAD files.
334 (substitute* "dist/freedoom"
335 (("IWAD=freedm.wad")
336 (string-append "IWAD=" wad-dir "/freedm.wad"))
337 (("IWAD=freedoom1.wad")
338 (string-append "IWAD=" wad-dir "/freedoom1.wad"))
339 (("IWAD=freedoom2.wad")
340 (string-append "IWAD=" wad-dir "/freedoom2.wad")))
341 #t))))))
342 (native-inputs
343 `(("asciidoc" ,asciidoc)
344 ("deutex" ,deutex)
345 ("font-dejavu" ,font-dejavu)
346 ("imagemagick" ,imagemagick)
347 ("python" ,python-2)))
348 (inputs
349 `(("prboom-plus" ,prboom-plus)))
350 (home-page "https://freedoom.github.io/")
351 (synopsis "Free content game based on the Doom engine")
352 (native-search-paths
353 (list (search-path-specification
354 (variable "DOOMWADDIR")
355 (files '("share/games/doom")))
356 (search-path-specification
357 (variable "DOOMWADPATH")
358 (files '("share/games/doom")))))
359 (description
360 "The Freedoom project aims to create a complete free content first person
361 shooter game. Freedoom by itself is just the raw material for a game: it must
362 be paired with a compatible game engine (such as @code{prboom-plus}) to be
363 played. Freedoom complements the Doom engine with free levels, artwork, sound
364 effects and music to make a completely free game.")
365 (license license:bsd-3)))
366
367 (define-public golly
368 (package
369 (name "golly")
370 (version "3.1")
371 (source (origin
372 (method url-fetch)
373 (uri (string-append "mirror://sourceforge/golly/golly/golly-"
374 version "/golly-" version
375 "-src.tar.gz"))
376 (sha256
377 (base32
378 "0dn74k3rylhx023n047lz4z6qrqijfcxi0b6jryqklhmm2n532f7"))))
379 (build-system gnu-build-system)
380 (arguments
381 '(#:make-flags (list "CC=gcc"
382 (string-append "GOLLYDIR="
383 (assoc-ref %outputs "out")
384 "/share/golly"))
385 #:tests? #f ; no check target
386 #:phases
387 (modify-phases %standard-phases
388 (replace 'configure
389 (lambda* (#:key inputs #:allow-other-keys)
390 ;; For some reason, setting the PYTHON_SHLIB make flag doesn't
391 ;; properly set the path to the Python shared library. This
392 ;; substitution acheives the same end by different means.
393 (substitute* "gui-wx/wxprefs.cpp"
394 (("pythonlib = wxT\\(STRINGIFY\\(PYTHON_SHLIB\\)\\)")
395 (string-append "pythonlib = \""
396 (assoc-ref inputs "python")
397 "/lib/libpython-2.7.so\"")))
398 #t))
399 (replace 'build
400 (lambda* (#:key make-flags outputs #:allow-other-keys)
401 (with-directory-excursion "gui-wx"
402 (apply invoke `("make" ,@make-flags "-f" "makefile-gtk")))))
403 (replace 'install
404 (lambda* (#:key outputs #:allow-other-keys)
405 (let* ((out (assoc-ref outputs "out"))
406 (bin (string-append out "/bin"))
407 (doc (string-append out "/share/doc/golly"))
408 (pixmaps (string-append out "/share/pixmaps"))
409 (share (string-append out "/share/golly")))
410 (for-each (lambda (binary)
411 (install-file binary bin))
412 '("bgolly" "golly"))
413 (for-each (lambda (document)
414 (install-file
415 (string-append "docs/" document ".html")
416 doc))
417 '("License" "ReadMe" "ToDo"))
418 (install-file "gui-wx/icons/appicon.xpm" pixmaps)
419 (for-each (lambda (folder)
420 (copy-recursively
421 folder
422 (string-append share "/" folder)))
423 '("Help" "Patterns" "Rules" "Scripts")))
424 #t)))))
425 (native-inputs
426 `(("lua" ,lua)))
427 (inputs
428 `(("glu" ,glu)
429 ("mesa" ,mesa)
430 ("python" ,python-2)
431 ("wxwidgets" ,wxwidgets-gtk2)
432 ("zlib" ,zlib)))
433 (home-page "http://golly.sourceforge.net/")
434 (synopsis "Software for exploring cellular automata")
435 (description
436 "Golly simulates Conway's Game of Life and many other types of cellular
437 automata. The following features are available:
438 @enumerate
439 @item Support for bounded and unbounded universes, with cells of up to 256
440 states.
441 @item Support for multiple algorithms, including Bill Gosper's Hashlife
442 algorithm.
443 @item Loading patterns from BMP, PNG, GIF and TIFF image files.
444 @item Reading RLE, macrocell, Life 1.05/1.06, dblife and MCell files.
445 @item Scriptable via Lua or Python.
446 @item Extracting patterns, rules and scripts from zip files.
447 @item Downloading patterns, rules and scripts from online archives.
448 @item Pasting patterns from the clipboard.
449 @item Unlimited undo/redo.
450 @item Configurable keyboard shortcuts.
451 @item Auto fit option to keep patterns within the view.
452 @end enumerate")
453 (license license:gpl2+)))
454
455 (define-public meandmyshadow
456 (package
457 (name "meandmyshadow")
458 (version "0.4")
459 (source (origin
460 (method url-fetch)
461 (uri (string-append "mirror://sourceforge/meandmyshadow/"
462 version "/meandmyshadow-" version
463 "-src.tar.gz"))
464 (sha256
465 (base32
466 "1dpb7s32b2psj5w3nr5kqibib8nndi86mw8gxp4hmxwrfiisf86d"))))
467 (build-system cmake-build-system)
468 (arguments
469 '(#:tests? #f ; there are no tests
470 #:phases
471 (modify-phases %standard-phases
472 (add-after 'unpack 'set-sdl'paths
473 (lambda* (#:key inputs #:allow-other-keys)
474 (substitute* "cmake/Modules/FindSDL_gfx.cmake"
475 (("/usr/local/include/SDL")
476 (string-append (assoc-ref inputs "sdl")
477 "/include/SDL")))
478 ;; Because SDL provides lib/libX11.so.6 we need to explicitly
479 ;; link with libX11, even though we're using the GL backend.
480 (substitute* "CMakeLists.txt"
481 (("\\$\\{X11_LIBRARIES\\}") "-lX11"))
482 )))))
483 (native-inputs
484 `(("pkg-config" ,pkg-config)))
485 (inputs
486 `(("sdl" ,(sdl-union (list sdl
487 sdl-image
488 sdl-gfx
489 sdl-mixer
490 sdl-ttf)))
491 ("libx11" ,libx11) ; needed by sdl's libX11
492 ("libarchive" ,libarchive)
493 ("openssl" ,openssl)
494 ("mesa" ,mesa)
495 ("glu" ,glu)
496 ("curl" ,curl)))
497 (home-page "http://meandmyshadow.sourceforge.net/")
498 (synopsis "Puzzle/platform game")
499 (description "Me and My Shadow is a puzzle/platform game in which you try
500 to reach the exit by solving puzzles. Spikes, moving blocks, fragile blocks
501 and much more stand between you and the exit. Record your moves and let your
502 shadow mimic them to reach blocks you couldn't reach alone.")
503 (license license:gpl3+)))
504
505 (define-public knights
506 (package
507 (name "knights")
508 (version "025")
509 (source (origin
510 (method url-fetch)
511 (uri (string-append "http://www.knightsgame.org.uk/files/knights_"
512 version "_src.tar.gz"))
513 (sha256
514 (base32
515 "18vp2ygvn0s0jz8rm585jqf6hjqkam1ximq81k0r9hpmfj7wb88f"))))
516 (build-system gnu-build-system)
517 (arguments
518 '(#:make-flags
519 (list (string-append "PREFIX=" (assoc-ref %outputs "out")))
520 #:phases
521 (modify-phases %standard-phases
522 ;; No configure script.
523 (delete 'configure))
524 #:tests? #f)) ;; No check target.
525 (inputs
526 `(("boost" ,boost)
527 ("sdl-union" ,(sdl-union (list sdl sdl-image sdl-mixer)))
528 ("freetype" ,freetype)
529 ("fontconfig" ,fontconfig)
530 ("curl" ,curl)))
531 (native-inputs
532 `(("pkg-config" ,pkg-config)))
533 (home-page "http://www.knightsgame.org.uk/")
534 (synopsis "Multiplayer dungeon game involving knights and quests")
535 (description "Knights is a multiplayer game involving several knights who
536 must run around a dungeon and complete various quests. Each game revolves
537 around a quest – for example, you might have to find some items and carry them
538 back to your starting point. This may sound easy, but as there are only
539 enough items in the dungeon for one player to win, you may end up having to
540 kill your opponents to get their stuff! Other quests involve escaping from
541 the dungeon, fighting a duel to the death against the enemy knights, or
542 destroying an ancient book using a special wand.")
543 ;; This package includes modified sources of lua (X11), enet (Expat), and
544 ;; guichan (BSD-3). The "Coercri" library is released under the Boost
545 ;; license. The whole package is released under GPLv3+.
546 (license license:gpl3+)))
547
548 (define-public gnubg
549 (package
550 (name "gnubg")
551 (version "1.02")
552 (source
553 (origin
554 (method url-fetch)
555 (uri (string-append "http://files.gnubg.org/media/sources/gnubg-release-"
556 version ".000-sources." "tar.gz"))
557 (sha256
558 (base32
559 "015mvjk2iw1cg1kxwxfnvp2rxb9cylf6yc39i30fdy414k07zkky"))))
560 (build-system gnu-build-system)
561 (inputs `(("glib" ,glib)
562 ("readline" ,readline)
563 ("gtk+" ,gtk+-2)
564 ("mesa" ,mesa)
565 ("glu" ,glu)
566 ("gtkglext" ,gtkglext)
567 ("sqlite" ,sqlite)
568 ("libcanberra" ,libcanberra)))
569 (native-inputs `(("python-2" ,python-2)
570 ("pkg-config" ,pkg-config)))
571 (home-page "http://gnubg.org")
572 (synopsis "Backgammon game")
573 (description "The GNU backgammon application can be used for playing, analyzing and
574 teaching the game. It has an advanced evaluation engine based on artificial
575 neural networks suitable for both beginners and advanced players. In
576 addition to a command-line interface, it also features an attractive, 3D
577 representation of the playing board.")
578 (license license:gpl3+)))
579
580 (define-public gnubik
581 (package
582 (name "gnubik")
583 (version "2.4.3")
584 (source
585 (origin
586 (method url-fetch)
587 (uri (string-append "mirror://gnu/gnubik/gnubik-"
588 version ".tar.gz"))
589 (sha256
590 (base32
591 "1vlf924mq8hg93bsjj0rzvs0crc6psmlxyc6zn0fr7msnmpx6gib"))))
592 (build-system gnu-build-system)
593 (inputs `(("gtk+" ,gtk+-2)
594 ("mesa" ,mesa)
595 ("glu" ,glu)
596 ("libx11" ,libx11)
597 ("guile" ,guile-2.0)
598 ("gtkglext" ,gtkglext)))
599 (native-inputs `(("gettext" ,gettext-minimal)
600 ("pkg-config" ,pkg-config)))
601 (home-page "https://www.gnu.org/software/gnubik/")
602 (synopsis "3d Rubik's cube game")
603 (description
604 "GNUbik is a puzzle game in which you must manipulate a cube to make
605 each of its faces have a uniform color. The game is customizable, allowing
606 you to set the size of the cube (the default is 3x3) or to change the colors.
607 You may even apply photos to the faces instead of colors. The game is
608 scriptable with Guile.")
609 (license license:gpl3+)))
610
611 (define-public gnushogi
612 (package
613 (name "gnushogi")
614 (version "1.4.2")
615 (source
616 (origin
617 (method url-fetch)
618 (uri (string-append "mirror://gnu/gnushogi/gnushogi-"
619 version ".tar.gz"))
620 (sha256
621 (base32
622 "0a9bsl2nbnb138lq0h14jfc5xvz7hpb2bcsj4mjn6g1hcsl4ik0y"))))
623 (arguments `(#:tests? #f)) ;; No check target.
624 (build-system gnu-build-system)
625 (home-page "https://www.gnu.org/software/gnushogi/")
626 (synopsis "The game of Shogi (Japanese chess)")
627 (description "GNU Shogi is a program that plays the game Shogi (Japanese
628 Chess). It is similar to standard chess but this variant is far more complicated.")
629 (license license:gpl3+)))
630
631 (define-public ltris
632 (package
633 (name "ltris")
634 (version "1.0.19")
635 (source
636 (origin
637 (method url-fetch)
638 (uri (string-append "http://prdownloads.sourceforge.net/lgames/"
639 name "-" version ".tar.gz"))
640 (sha256
641 (base32
642 "1895wv1fqklrj4apkz47rnkcfhfav7zjknskw6p0886j35vrwslg"))))
643 (build-system gnu-build-system)
644 (arguments
645 '(;; The code in LTris uses traditional GNU semantics for inline functions
646 #:configure-flags '("CFLAGS=-fgnu89-inline")
647 #:phases
648 (modify-phases %standard-phases
649 (add-after 'set-paths 'set-sdl-paths
650 (lambda* (#:key inputs #:allow-other-keys)
651 (setenv "CPATH"
652 (string-append (assoc-ref inputs "sdl-union")
653 "/include/SDL"))
654 #t)))))
655 (inputs
656 `(("sdl-union" ,(sdl-union (list sdl sdl-mixer)))))
657 (home-page "http://lgames.sourceforge.net/LTris/")
658 (synopsis "Tetris clone based on the SDL library")
659 (description
660 "LTris is a tetris clone: differently shaped blocks are falling down the
661 rectangular playing field and can be moved sideways or rotated by 90 degree
662 units with the aim of building lines without gaps which then disappear (causing
663 any block above the deleted line to fall down). LTris has three game modes: In
664 Classic you play until the stack of blocks reaches the top of the playing field
665 and no new blocks can enter. In Figures the playing field is reset to a new
666 figure each level and later on tiles and lines suddenly appear. In Multiplayer
667 up to three players (either human or CPU) compete with each other sending
668 removed lines to all opponents. There is also a Demo mode in which you can
669 watch your CPU playing while enjoying a cup of tea!")
670 (license license:gpl2+)))
671
672 (define-public prboom-plus
673 (package
674 (name "prboom-plus")
675 (version "2.5.1.4")
676 (source (origin
677 (method url-fetch)
678 (uri (string-append "mirror://sourceforge/" name "/" name "/"
679 version "/" name "-" version ".tar.gz"))
680 (sha256
681 (base32
682 "151v6nign86m1a2vqz27krsccpc9m4d1jax4y43v2fa82wfj9qp0"))
683 (modules '((guix build utils)))
684 (snippet
685 '(substitute* "src/version.c"
686 (("__DATE__") "")
687 (("__TIME__") "")))))
688 (build-system gnu-build-system)
689 (arguments
690 '(#:configure-flags '("--disable-cpu-opt")
691 #:make-flags `(,(string-append "gamesdir="
692 (assoc-ref %outputs "out") "/bin"))
693 #:phases
694 (modify-phases %standard-phases
695 (add-after 'set-paths 'set-sdl'paths
696 (lambda* (#:key inputs #:allow-other-keys)
697 (setenv "CPATH"
698 (string-append (assoc-ref inputs "sdl-union")
699 "/include/SDL"))
700 #t)))))
701 (inputs
702 `(("fluidsynth" ,fluidsynth)
703 ("glu" ,glu)
704 ("libmad" ,libmad)
705 ("libpng" ,libpng)
706 ("libvorbis" ,libvorbis)
707 ("pcre" ,pcre)
708 ("portmidi" ,portmidi)
709 ("sdl-union" ,(sdl-union (list sdl sdl-image sdl-mixer sdl-net)))))
710 (home-page "http://prboom-plus.sourceforge.net/")
711 (synopsis "Version of the classic 3D shoot'em'up game Doom")
712 (description
713 "PrBoom+ is a Doom source port developed from the original PrBoom project.")
714 (license license:gpl2+)))
715
716 (define-public retux
717 (package
718 (name "retux")
719 (version "1.3.5")
720 (source (origin
721 (method url-fetch)
722 (uri (string-append "mirror://savannah/retux/"
723 (version-major+minor version) "/retux-"
724 version "-src.tar.gz"))
725 (sha256
726 (base32
727 "1pcrh3z16fl412r3k7xccrgika19ahb1xh90jihgl8yy7zza2i6p"))))
728 (build-system python-build-system)
729 (arguments
730 `(#:tests? #f ; no check target
731 #:phases
732 (modify-phases %standard-phases
733 ;; no setup.py script
734 (delete 'build)
735 (replace 'install
736 (lambda* (#:key outputs #:allow-other-keys)
737 (let* ((out (assoc-ref outputs "out"))
738 (bin (string-append out "/bin"))
739 (data (string-append out "/share/retux"))
740 (doc (string-append out "/share/doc/retux")))
741 (mkdir-p bin)
742
743 (substitute* "retux.py"
744 ;; Use the correct data directory.
745 (("os\\.path\\.join\\(os\\.path\\.dirname\\(__file__\\), \"data\"\\),")
746 (string-append "\"" data "\","))
747 ;; Use Python 3 so the patch-shebangs phase works properly.
748 ((".*python2.*") "#!/usr/bin/python3"))
749
750 (copy-file "retux.py" (string-append bin "/retux"))
751
752 (copy-recursively "data" data)
753
754 (install-file "COPYING" doc)))))))
755 (inputs
756 `(("python-sge-pygame" ,python-sge-pygame)
757 ("python-six" ,python-six)
758 ("python-xsge" ,python-xsge)))
759 (home-page "http://retux.nongnu.org")
760 (synopsis "Action platformer game")
761 (description
762 "ReTux is an action platformer loosely inspired by the Mario games,
763 utilizing the art assets from the @code{SuperTux} project.")
764 ;; GPL version 3 or later is the license for the code and some art.
765 ;; The rest of the licenses are for the art exclusively, as listed in
766 ;; data/LICENSES.
767 (license (list license:cc0
768 license:cc-by3.0
769 license:cc-by-sa3.0
770 license:cc-by-sa4.0
771 license:gpl2+
772 license:gpl3+))))
773
774 (define-public roguebox-adventures
775 (let ((commit "19a2c340b34d5b4e7cc89118c7aedc058babbd93")
776 (revision "1"))
777 (package
778 (name "roguebox-adventures")
779 (version (git-version "2.1.2" revision commit))
780 (source
781 (origin
782 (method git-fetch)
783 (uri
784 (git-reference
785 (url "https://git.postactiv.com/themightyglider/RogueBoxAdventures.git")
786 (commit commit)))
787 (file-name (git-file-name name version))
788 (sha256
789 (base32
790 "0afmg8fjdcs3sqdp5rc7irgr7riil8jwysfjn1imfxslf1wcx5ah"))))
791 (build-system python-build-system)
792 (arguments
793 '(#:tests? #f ; no check target
794 #:phases
795 (modify-phases %standard-phases
796 ;; no setup.py script
797 (replace 'build
798 (lambda* (#:key outputs #:allow-other-keys)
799 (let* ((out (assoc-ref outputs "out"))
800 (data (string-append
801 out "/share/games/roguebox-adventures")))
802 ;; Use the correct data directory.
803 (substitute* '("main.py" "LIB/getch.py" "LIB/getch_gcwz.py")
804 (("basic_path + os\\.sep + 'DATA'")
805 (string-append "'" data "'"))
806 (("^basic_path.*$")
807 (string-append "basic_path ='" data "'\n")))
808 (substitute* "LIB/gra_files.py"
809 (("basic_path = b_path\\.replace\\('/LIB',''\\)")
810 (string-append "basic_path ='" data "'\n")))
811
812 ;; The game must save in the user's home directory because
813 ;; the store is read-only.
814 (substitute* "main.py"
815 (("home_save = False") "home_save = True")
816 (("'icon_small.png'")
817 (string-append "'" data "/icon_small.png'"))))
818 #t))
819 (replace 'install
820 (lambda* (#:key outputs #:allow-other-keys)
821 (let* ((out (assoc-ref outputs "out"))
822 (bin (string-append out "/bin"))
823 (data (string-append
824 out "/share/games/roguebox-adventures"))
825 (doc (string-append
826 out "/share/doc/roguebox-adventures")))
827 (mkdir-p bin)
828 (mkdir-p doc)
829 (copy-file "main.py"
830 (string-append bin "/roguebox-adventures"))
831 (chmod (string-append bin "/roguebox-adventures") #o555)
832
833 (for-each (lambda (file)
834 (copy-recursively file
835 (string-append data "/" file)))
836 '("AUDIO" "FONT" "GRAPHIC" "LIB" "LICENSE"
837 "icon_big.png" "icon_small.png"))
838
839 (copy-recursively "DOC" doc)
840
841 (wrap-program (string-append bin "/roguebox-adventures")
842 `("PYTHONPATH" ":" prefix (,(string-append data "/LIB")))))
843 #t)))))
844 (inputs
845 `(("python-pygame" ,python-pygame)
846 ("python-tmx" ,python-tmx)))
847 (home-page "https://rogueboxadventures.tuxfamily.org")
848 (synopsis "A classical roguelike/sandbox game")
849 (description
850 "RogueBox Adventures is a graphical roguelike with strong influences
851 from sandbox games like Minecraft or Terraria. The main idea of RogueBox
852 Adventures is to offer the player a kind of roguelike toy-world. This world
853 can be explored and changed freely.")
854 ;; The GPL3+ is for code, the rest are for art.
855 (license (list license:cc0
856 license:cc-by3.0
857 license:gpl3+
858 license:silofl1.1)))))
859
860 (define-public xshogi
861 (package
862 (name "xshogi")
863 (version "1.4.2")
864 (source
865 (origin
866 (method url-fetch)
867 (uri (string-append "mirror://gnu/gnushogi/xshogi-"
868 version ".tar.gz"))
869 (sha256
870 (base32
871 "1dns0nhymak44by18sv48m4xb2skiwbi2i3nb9hl6w9iwd2i2brf"))))
872 (build-system gnu-build-system)
873 (inputs
874 `(("libxaw" ,libxaw)
875 ("libxt" ,libxt)))
876 (home-page "https://www.gnu.org/software/gnushogi/")
877 (synopsis "User interface for gnushogi")
878 (description "A graphical user interface for the package @code{gnushogi}.")
879 ;; Contains a copy of GPLv3 but the licence notices simply
880 ;; state "GNU General Public Licence" without specifying a version.
881 (license license:gpl1+)))
882
883 (define-public abbaye
884 (package
885 (name "abbaye")
886 (version "2.0.1")
887 (source
888 (origin
889 (method url-fetch)
890 (uri (string-append "https://github.com/nevat/abbayedesmorts-gpl/"
891 "archive/v" version ".tar.gz"))
892 (file-name (string-append name "-" version ".tar.gz"))
893 (sha256
894 (base32
895 "1a67b0hq6271dd7pvwndjq29cwn2n8gawwz17xafa3k1hrhf8vw3"))
896 (modules '((guix build utils)))
897 (snippet
898 ;; Unbundle fonts.
899 '(delete-file-recursively "fonts"))))
900 (build-system gnu-build-system)
901 (arguments
902 '(#:make-flags '("CC=gcc")
903 #:phases (modify-phases %standard-phases
904 (add-after 'set-paths 'set-sdl-paths
905 (lambda* (#:key inputs #:allow-other-keys)
906 (setenv "CPATH"
907 (string-append (assoc-ref inputs "sdl-union")
908 "/include/SDL"))))
909 (add-after 'patch-source-shebangs 'patch-makefile
910 (lambda* (#:key outputs #:allow-other-keys)
911 ;; Replace /usr with package output directory.
912 (substitute* "Makefile"
913 (("/usr") (assoc-ref outputs "out")))))
914 (add-before 'install 'make-install-dirs
915 (lambda* (#:key outputs #:allow-other-keys)
916 (let ((prefix (assoc-ref outputs "out")))
917 ;; Create directories that the makefile assumes exist.
918 (mkdir-p (string-append prefix "/bin"))
919 (mkdir-p (string-append prefix "/share/applications"))
920 (mkdir-p (string-append prefix "/share/pixmaps")))))
921 ;; No configure script.
922 (delete 'configure))
923 #:tests? #f)) ;; No check target.
924 (native-inputs `(("pkg-config" ,pkg-config)))
925 (inputs `(("sdl-union" ,(sdl-union (list sdl2 sdl2-image sdl2-mixer)))))
926 (home-page "https://github.com/nevat/abbayedesmorts-gpl")
927 (synopsis "GNU/Linux port of the indie game \"l'Abbaye des Morts\"")
928 (description "L'Abbaye des Morts is a 2D platform game set in 13th century
929 France. The Cathars, who preach about good Christian beliefs, were being
930 expelled by the Catholic Church out of the Languedoc region in France. One of
931 them, called Jean Raymond, found an old church in which to hide, not knowing
932 that beneath its ruins lay buried an ancient evil.")
933 (license license:gpl3)))
934
935 (define-public angband
936 (package
937 (name "angband")
938 (version "4.0.5")
939 (source
940 (origin
941 (method url-fetch)
942 (uri (string-append "http://rephial.org/downloads/4.0/"
943 "angband-" version ".tar.gz"))
944 (sha256
945 (base32
946 "0lpq2kms7hp421vrasx2bkkn9w08kr581ldwik3v0hlq6h7rlxhd"))
947 (modules '((guix build utils)))
948 (snippet
949 ;; So, some of the sounds/graphics/tilesets are under different
950 ;; licenses... some of them even nonfree! This is a console-only
951 ;; version of this package so we just remove them.
952 ;; In the future, if someone tries to make a graphical variant of
953 ;; this package, they can deal with that mess themselves. :)
954 '(begin
955 (for-each
956 (lambda (subdir)
957 (let ((lib-subdir (string-append "lib/" subdir)))
958 (delete-file-recursively lib-subdir)))
959 '("fonts" "icons" "sounds" "tiles"))
960 (substitute* "lib/Makefile"
961 ;; And don't try to invoke makefiles in the directories we removed
962 (("gamedata customize help screens fonts tiles sounds icons user")
963 "gamedata customize help screens user"))))))
964 (build-system gnu-build-system)
965 (arguments
966 `(#:tests? #f ;no check target
967 #:configure-flags (list (string-append "--bindir=" %output "/bin"))
968 #:phases
969 (modify-phases %standard-phases
970 (add-after 'unpack 'autogen.sh
971 (lambda _
972 (substitute* "acinclude.m4"
973 (("ncursesw5-config") "ncursesw6-config"))
974 (zero? (system* "sh" "autogen.sh")))))))
975 (native-inputs
976 `(("autoconf" ,autoconf)
977 ("automake" ,automake)))
978 (inputs `(("ncurses" ,ncurses)))
979 (home-page "http://rephial.org/")
980 (synopsis "Dungeon exploration roguelike")
981 (description "Angband is a Classic dungeon exploration roguelike. Explore
982 the depths below Angband, seeking riches, fighting monsters, and preparing to
983 fight Morgoth, the Lord of Darkness.")
984 (license license:gpl2)))
985
986 (define-public pingus
987 (package
988 (name "pingus")
989 (version "0.7.6")
990 (source
991 (origin
992 (method url-fetch)
993 (uri (string-append "https://github.com/Pingus/pingus/archive/v"
994 version ".tar.gz"))
995 (file-name (string-append name "-" version ".tar.gz"))
996 (sha256
997 (base32
998 "0r9v6as5vi7skvvy7b0fcaimhdlzmik64pyy68plgljhsghqkkf4"))
999 (patches (search-patches "pingus-sdl-libs-config.patch"))))
1000 (build-system gnu-build-system)
1001 (native-inputs `(("pkg-config" ,pkg-config)
1002 ("scons-python2" ,scons-python2)))
1003 (inputs `(("sdl" ,sdl)
1004 ("sdl-image" ,sdl-image)
1005 ("sdl-mixer" ,sdl-mixer)
1006 ("mesa" ,mesa)
1007 ("glu" ,glu)
1008 ("libpng" ,libpng)
1009 ("boost" ,boost)))
1010 (arguments
1011 '(#:make-flags (list (string-append "PREFIX=" %output))
1012 #:tests? #f ; no check target
1013 #:phases
1014 (modify-phases %standard-phases
1015 (delete 'configure)))) ; no configure script
1016 (home-page "http://pingus.seul.org/welcome.html")
1017 (synopsis "Lemmings clone")
1018 (description
1019 "Pingus is a free Lemmings-like puzzle game in which the player takes
1020 command of a bunch of small animals and has to guide them through levels.
1021 Since the animals walk on their own, the player can only influence them by
1022 giving them commands, like build a bridge, dig a hole, or redirect all animals
1023 in the other direction. Multiple such commands are necessary to reach the
1024 level's exit. The game is presented in a 2D side view.")
1025 ;; Some source files are under bsd-3 and gpl2+ licenses.
1026 (license license:gpl3+)))
1027
1028 (define-public talkfilters
1029 (package
1030 (name "talkfilters")
1031 (version "2.3.8")
1032 (source
1033 (origin
1034 (method url-fetch)
1035 (uri (string-append "http://www.hyperrealm.com/" name "/"
1036 name "-" version ".tar.gz"))
1037 (sha256
1038 (base32 "19nc5vq4bnkjvhk8srqddzhcs93jyvpm9r6lzjzwc1mgf08yg0a6"))))
1039 (build-system gnu-build-system)
1040 (home-page "https://www.gnu.org/software/talkfilters/")
1041 (synopsis "Convert English text to humorous dialects")
1042 (description "The GNU Talk Filters are programs that convert English text
1043 into stereotyped or otherwise humorous dialects. The filters are provided as
1044 a C library, so they can easily be integrated into other programs.")
1045 (license license:gpl2+)))
1046
1047 (define-public cmatrix
1048 (package
1049 (name "cmatrix")
1050 (version "1.2a")
1051 (source
1052 (origin
1053 (method url-fetch)
1054 (uri (string-append "http://www.asty.org/cmatrix/dist/cmatrix-" version
1055 ".tar.gz"))
1056 (sha256
1057 (base32
1058 "0k06fw2n8nzp1pcdynhajp5prba03gfgsbj91bknyjr5xb5fd9hz"))))
1059 (build-system gnu-build-system)
1060 (arguments
1061 '(#:phases
1062 (modify-phases %standard-phases
1063 (replace 'configure
1064 (lambda* (#:key outputs #:allow-other-keys)
1065 ;; This old ‘configure’ script doesn't support
1066 ;; variables passed as arguments.
1067 (let ((out (assoc-ref outputs "out")))
1068 (setenv "CONFIG_SHELL" (which "bash"))
1069 (zero?
1070 (system* "./configure"
1071 (string-append "--prefix=" out)))))))))
1072 (inputs `(("ncurses" ,ncurses)))
1073 (home-page "http://www.asty.org/cmatrix")
1074 (synopsis "Simulate the display from \"The Matrix\"")
1075 (description "CMatrix simulates the display from \"The Matrix\" and is
1076 based on the screensaver from the movie's website. It works with terminal
1077 settings up to 132x300 and can scroll lines all at the same rate or
1078 asynchronously and at a user-defined speed.")
1079 (license license:gpl2+)))
1080
1081 (define-public chess
1082 (package
1083 (name "chess")
1084 (version "6.2.5")
1085 (source
1086 (origin
1087 (method url-fetch)
1088 (uri (string-append "mirror://gnu/chess/gnuchess-" version
1089 ".tar.gz"))
1090 (sha256
1091 (base32
1092 "00j8s0npgfdi41a0mr5w9qbdxagdk2v41lcr42rwl1jp6miyk6cs"))))
1093 (build-system gnu-build-system)
1094 (home-page "https://www.gnu.org/software/chess/")
1095 (synopsis "Full chess implementation")
1096 (description "GNU Chess is a chess engine. It allows you to compete
1097 against the computer in a game of chess, either through the default terminal
1098 interface or via an external visual interface such as GNU XBoard.")
1099 (license license:gpl3+)))
1100
1101 (define freedink-engine
1102 (package
1103 (name "freedink-engine")
1104 (version "108.4")
1105 (source (origin
1106 (method url-fetch)
1107 (uri (string-append "mirror://gnu/freedink/freedink-" version
1108 ".tar.gz"))
1109 (sha256
1110 (base32
1111 "08c51imfjfcydm7h0va09z8qfw5nc837bi2x754ni2z737hb5kw2"))))
1112 (build-system gnu-build-system)
1113 (arguments `(#:configure-flags '("--disable-embedded-resources")))
1114 (native-inputs `(("gettext" ,gettext-minimal)
1115 ("pkg-config" ,pkg-config)))
1116 (inputs `(("sdl" ,sdl)
1117 ("sdl-image" ,sdl-image)
1118 ("sdl-mixer" ,sdl-mixer)
1119 ("sdl-ttf" ,sdl-ttf)
1120 ("sdl-gfx" ,sdl-gfx)
1121 ("fontconfig" ,fontconfig)
1122 ("check" ,check)))
1123 (home-page "https://www.gnu.org/software/freedink/")
1124 (synopsis "Twisted adventures of young pig farmer Dink Smallwood")
1125 (description
1126 "GNU FreeDink is a free and portable re-implementation of the engine
1127 for the role-playing game Dink Smallwood. It supports not only the original
1128 game data files but it also supports user-produced game mods or \"D-Mods\".
1129 To that extent, it also includes a front-end for managing all of your D-Mods.")
1130 (license license:gpl3+)))
1131
1132 (define freedink-data
1133 (package
1134 (name "freedink-data")
1135 (version "1.08.20170401")
1136 (source (origin
1137 (method url-fetch)
1138 (uri (string-append "mirror://gnu/freedink/freedink-data-"
1139 version ".tar.xz"))
1140 (sha256
1141 (base32
1142 "1zx7qywibhznj7bnz217404scr8dfh0xj24xjihnda5iapzz7lz8"))))
1143 (build-system gnu-build-system)
1144 (arguments
1145 `(#:phases
1146 (modify-phases %standard-phases
1147 (delete 'configure) ; no configure script
1148 (delete 'check)) ; no tests
1149 #:make-flags (list (string-append "PREFIX=" (assoc-ref %outputs "out")))))
1150 (home-page "https://www.gnu.org/software/freedink/")
1151 (synopsis "Game data for GNU Freedink")
1152 (description
1153 "This package contains the game data of GNU Freedink.")
1154 (license license:gpl3+)))
1155
1156 ;; TODO: Add freedink-dfarc when there's a wxWidgets package.
1157
1158 (define-public freedink
1159 ;; This is a wrapper that tells the engine where to find the data.
1160 (package (inherit freedink-engine)
1161 (name "freedink")
1162 (build-system trivial-build-system)
1163 (arguments
1164 '(#:builder (begin
1165 (use-modules (guix build utils))
1166
1167 (let* ((output (assoc-ref %outputs "out"))
1168 (bin (string-append output "/bin"))
1169 (executable (string-append bin "/freedink")))
1170 (mkdir-p bin)
1171 (call-with-output-file executable
1172 (lambda (port)
1173 (format port "#!~a/bin/sh
1174 exec ~a/bin/freedink -refdir ~a/share/dink\n"
1175 (assoc-ref %build-inputs "bash")
1176 (assoc-ref %build-inputs "engine")
1177 (assoc-ref %build-inputs "data"))
1178 (chmod port #o777)))))
1179 #:modules ((guix build utils))))
1180 (inputs `(("engine" ,freedink-engine)
1181 ("data" ,freedink-data)
1182 ("bash" ,bash)))
1183 (native-inputs '())))
1184
1185 (define-public xboard
1186 (package
1187 (name "xboard")
1188 (version "4.9.1")
1189 (source
1190 (origin
1191 (method url-fetch)
1192 (uri (string-append "mirror://gnu/xboard/xboard-" version
1193 ".tar.gz"))
1194 (sha256
1195 (base32
1196 "1mkh36xnnacnz9r00b5f9ld9309k32jv6mcavklbdnca8bl56bib"))))
1197 (build-system gnu-build-system)
1198 (inputs
1199 `(("gtk+" ,gtk+-2)
1200 ("librsvg" ,librsvg)))
1201 (native-inputs
1202 `(("texinfo" ,texinfo)
1203 ("pkg-config" ,pkg-config)))
1204 (home-page "https://www.gnu.org/software/xboard/")
1205 (synopsis "Graphical user interface for chess programs")
1206 (description "GNU XBoard is a graphical board for all varieties of chess,
1207 including international chess, xiangqi (Chinese chess), shogi (Japanese chess)
1208 and Makruk. Several lesser-known variants are also supported. It presents a
1209 fully interactive graphical interface and it can load and save games in the
1210 Portable Game Notation.")
1211 (license license:gpl3+)))
1212
1213
1214 (define-public xboing
1215 (package
1216 (name "xboing")
1217 (version "2.4")
1218 (source
1219 (origin
1220 (method url-fetch)
1221 (uri (string-append "http://www.techrescue.org/xboing/xboing"
1222 version ".tar.gz"))
1223 (sha256
1224 (base32 "16m2si8wmshxpifk861vhpqviqxgcg8bxj6wfw8hpnm4r2w9q0b7"))
1225 (patches (search-patches "xboing-CVE-2004-0149.patch"))))
1226 (arguments
1227 `(#:tests? #f
1228 #:phases
1229 (modify-phases %standard-phases
1230 (replace 'configure
1231 (lambda* (#:key outputs #:allow-other-keys)
1232
1233 (substitute* "Imakefile"
1234 (("XPMINCLUDE[\t ]*= -I/usr/X11/include/X11")
1235 (string-append "XPMINCLUDE = -I"
1236 (assoc-ref %build-inputs "libxpm")
1237 "/include/X11")))
1238
1239 (substitute* "Imakefile"
1240 (("XBOING_DIR = \\.") "XBOING_DIR=$(PROJECTROOT)"))
1241
1242 ;; FIXME: HIGH_SCORE_FILE should be set to somewhere writeable
1243
1244 (zero? (system* "xmkmf" "-a"
1245 (string-append "-DProjectRoot="
1246 (assoc-ref outputs "out"))))))
1247 (replace 'install
1248 (lambda* (#:key outputs #:allow-other-keys)
1249 (and
1250 (zero? (system* "make" "install.man"))
1251 (zero? (system* "make" "install"))))))))
1252 (inputs `(("libx11" ,libx11)
1253 ("libxext" ,libxext)
1254 ("libxpm" ,libxpm)))
1255 (native-inputs `(("imake" ,imake)
1256 ("inetutils" ,inetutils)
1257 ("makedepend" ,makedepend)))
1258 (build-system gnu-build-system)
1259 (home-page "http://www.techrescue.org/xboing")
1260 (synopsis "Ball and paddle game")
1261 (description "XBoing is a blockout type game where you have a paddle which
1262 you control to bounce a ball around the game zone destroying blocks with a
1263 proton ball. Each block carries a different point value. The more blocks you
1264 destroy, the better your score. The person with the highest score wins.")
1265 (license (license:x11-style "file://COPYING"
1266 "Very similar to the X11 licence."))))
1267
1268 (define-public gtypist
1269 (package
1270 (name "gtypist")
1271 (version "2.9.5")
1272 (source (origin
1273 (method url-fetch)
1274 (uri (string-append "mirror://gnu/gtypist/gtypist-"
1275 version ".tar.xz"))
1276 (sha256
1277 (base32
1278 "0xzrkkmj0b1dw3yr0m9hml2y634cc4h61im6zwcq57s7285z8fn1"))
1279 (modules '((guix build utils)))
1280 (snippet
1281 ;; We do not provide `ncurses.h' within an `ncursesw'
1282 ;; sub-directory, so patch the source accordingly. See
1283 ;; <http://bugs.gnu.org/19018>.
1284 '(for-each (lambda (file)
1285 (substitute* file
1286 (("ncursesw/ncurses.h")
1287 "ncurses.h")))
1288 (find-files "." "configure$|\\.c$")))))
1289 (build-system gnu-build-system)
1290 (inputs `(("ncurses" ,ncurses)
1291 ("perl" ,perl)))
1292 (home-page "https://www.gnu.org/software/gtypist/")
1293 (synopsis "Typing tutor")
1294 (description
1295 "GNU Typist is a universal typing tutor. It can be used to learn and
1296 practice touch-typing. Several tutorials are included; in addition to
1297 tutorials for the standard QWERTY layout, there are also tutorials for the
1298 alternative layouts Dvorak and Colemak, as well as for the numpad. Tutorials
1299 are primarily in English, however some in other languages are provided.")
1300 (license license:gpl3+)))
1301
1302 (define-public irrlicht
1303 (package
1304 (name "irrlicht")
1305 (version "1.8.4")
1306 (source (origin
1307 (method url-fetch)
1308 (uri (string-append
1309 "mirror://sourceforge/irrlicht/Irrlicht%20SDK/"
1310 (version-major+minor version)
1311 "/" version "/irrlicht-" version ".zip"))
1312 (sha256
1313 (base32
1314 "0cz4z4dwrv5ypl19ll67wl6jjpy5k6ly4vr042w4br88qq5jhazl"))))
1315 (build-system gnu-build-system)
1316 (arguments
1317 `(#:phases
1318 (modify-phases %standard-phases
1319 (add-after 'unpack 'fix-build-env
1320 (lambda* (#:key outputs #:allow-other-keys)
1321 (let ((out (assoc-ref outputs "out")))
1322 (substitute* "Makefile"
1323 (("INSTALL_DIR = /usr/local/lib")
1324 (string-append "INSTALL_DIR = " out "/lib")))
1325 ;; The Makefile assumes these directories exist.
1326 (mkdir-p (string-append out "/lib"))
1327 (mkdir-p (string-append out "/include")))))
1328 (replace 'unpack
1329 (lambda* (#:key source #:allow-other-keys)
1330 (and (zero? (system* "unzip" source))
1331 ;; The actual source is buried a few directories deep.
1332 (chdir (string-append "irrlicht-" ,version
1333 "/source/Irrlicht/")))))
1334 (delete 'configure)) ; no configure script
1335 #:tests? #f ; no check target
1336 #:make-flags '("CC=gcc" "sharedlib")))
1337 (native-inputs
1338 `(("unzip" ,unzip)))
1339 (inputs
1340 `(("mesa" ,mesa)
1341 ("glu" ,glu)))
1342 (synopsis "3D game engine written in C++")
1343 (description
1344 "The Irrlicht Engine is a high performance realtime 3D engine written in
1345 C++. Features include an OpenGL renderer, extensible materials, scene graph
1346 management, character animation, particle and other special effects, support
1347 for common mesh file formats, and collision detection.")
1348 (home-page "http://irrlicht.sourceforge.net/")
1349 (license license:zlib)))
1350
1351 (define-public mars
1352 ;; The latest release on SourceForge relies on an unreleased version of SFML
1353 ;; with a different API, so we take the latest version from the official
1354 ;; repository on Github.
1355 (let ((commit "c855d044094a1d92317e38935d81ba938946132e")
1356 (revision "1"))
1357 (package
1358 (name "mars")
1359 (version (string-append "0.7.5." revision "." (string-take commit 7) ))
1360 (source (origin
1361 (method git-fetch)
1362 (uri (git-reference
1363 (url "https://github.com/thelaui/M.A.R.S..git")
1364 (commit commit)))
1365 (file-name (string-append name "-" version))
1366 (sha256
1367 (base32
1368 "1r4c5gap1z2zsv4yjd34qriqkxaq4lb4rykapyzkkdf4g36lc3nh"))
1369 (patches (search-patches "mars-sfml-2.3.patch"
1370 "mars-install.patch"))))
1371 (build-system cmake-build-system)
1372 (arguments
1373 `(#:tests? #f ; There are no tests
1374 #:phases
1375 (modify-phases %standard-phases
1376 (add-after 'unpack 'fix-install-path
1377 (lambda _
1378 (substitute* "src/CMakeLists.txt"
1379 (("\\$\\{CMAKE_INSTALL_PREFIX\\}/games")
1380 "${CMAKE_INSTALL_PREFIX}/bin"))
1381 #t))
1382 (add-after 'unpack 'fix-data-path
1383 (lambda* (#:key outputs #:allow-other-keys)
1384 (substitute* "src/System/settings.cpp"
1385 (("C_dataPath = \"./data/\";")
1386 (string-append "C_dataPath = \""
1387 (assoc-ref outputs "out")
1388 "/share/games/marsshooter/\";")))
1389 #t)))))
1390 (inputs
1391 `(("mesa" ,mesa)
1392 ("fribidi" ,fribidi)
1393 ("taglib" ,taglib)
1394 ("sfml" ,sfml)))
1395 (home-page "http://marsshooter.org")
1396 (synopsis "2D space shooter")
1397 (description
1398 "M.A.R.S. is a 2D space shooter with pretty visual effects and
1399 attractive physics. Players can battle each other or computer controlled
1400 enemies in different game modes such as space ball, death match, team death
1401 match, cannon keep, and grave-itation pit.")
1402 (license license:gpl3+))))
1403
1404 (define minetest-data
1405 (package
1406 (name "minetest-data")
1407 (version "0.4.16")
1408 (source (origin
1409 (method url-fetch)
1410 (uri (string-append
1411 "https://github.com/minetest/minetest_game/archive/"
1412 version ".tar.gz"))
1413 (file-name (string-append name "-" version ".tar.gz"))
1414 (sha256
1415 (base32
1416 "0nibpm600rbv9dg1zgcsl5grlbqx0b5l6cg1lp6sqkwvjialb4ga"))))
1417 (build-system trivial-build-system)
1418 (native-inputs
1419 `(("source" ,source)
1420 ("tar" ,tar)
1421 ("gzip" ,(@ (gnu packages compression) gzip))))
1422 (arguments
1423 `(#:modules ((guix build utils))
1424 #:builder (begin
1425 (use-modules (guix build utils))
1426 (let ((tar (string-append (assoc-ref %build-inputs "tar")
1427 "/bin/tar"))
1428 (install-dir (string-append
1429 %output
1430 "/share/minetest/games/minetest_game"))
1431 (path (string-append (assoc-ref %build-inputs
1432 "gzip")
1433 "/bin")))
1434 (setenv "PATH" path)
1435 (system* tar "xvf" (assoc-ref %build-inputs "source"))
1436 (chdir (string-append "minetest_game-" ,version))
1437 (mkdir-p install-dir)
1438 (copy-recursively "." install-dir)))))
1439 (synopsis "Main game data for the Minetest game engine")
1440 (description
1441 "Game data for the Minetest infinite-world block sandox game.")
1442 (home-page "http://minetest.net")
1443 (license license:lgpl2.1+)))
1444
1445 (define-public minetest
1446 (package
1447 (name "minetest")
1448 (version "0.4.16")
1449 (source (origin
1450 (method url-fetch)
1451 (uri (string-append
1452 "https://github.com/minetest/minetest/archive/"
1453 version ".tar.gz"))
1454 (file-name (string-append name "-" version ".tar.gz"))
1455 (sha256
1456 (base32
1457 "0mbnf1ma4gsw9ah68ply04059xkfx5psdxwalxp78sgmx4ypkwqf"))))
1458 (build-system cmake-build-system)
1459 (arguments
1460 '(#:configure-flags
1461 (list "-DRUN_IN_PLACE=0"
1462 "-DENABLE_FREETYPE=1"
1463 "-DENABLE_GETTEXT=1"
1464 (string-append "-DIRRLICHT_INCLUDE_DIR="
1465 (assoc-ref %build-inputs "irrlicht")
1466 "/include/irrlicht")
1467 (string-append "-DCURL_INCLUDE_DIR="
1468 (assoc-ref %build-inputs "curl")
1469 "/include/curl"))
1470 #:tests? #f)) ; no check target
1471 (native-search-paths
1472 (list (search-path-specification
1473 (variable "MINETEST_SUBGAME_PATH")
1474 (files '("share/minetest/games")))))
1475 (native-inputs
1476 `(("pkg-config" ,pkg-config)))
1477 (inputs
1478 `(("irrlicht" ,irrlicht)
1479 ("libpng" ,libpng)
1480 ("libjpeg" ,libjpeg)
1481 ("libxxf86vm" ,libxxf86vm)
1482 ("mesa" ,mesa)
1483 ("libogg" ,libogg)
1484 ("libvorbis" ,libvorbis)
1485 ("openal" ,openal)
1486 ("freetype" ,(@ (gnu packages fontutils) freetype))
1487 ("curl" ,curl)
1488 ("luajit" ,luajit)
1489 ("gettext" ,gettext-minimal)
1490 ("sqlite" ,sqlite)))
1491 (propagated-inputs
1492 `(("minetest-data" ,minetest-data)))
1493 (synopsis "Infinite-world block sandbox game")
1494 (description
1495 "Minetest is a sandbox construction game. Players can create and destroy
1496 various types of blocks in a three-dimensional open world. This allows
1497 forming structures in every possible creation, on multiplayer servers or as a
1498 single player. Mods and texture packs allow players to personalize the game
1499 in different ways.")
1500 (home-page "http://minetest.net")
1501 (license license:lgpl2.1+)))
1502
1503 (define glkterm
1504 (package
1505 (name "glkterm")
1506 (version "1.0.4")
1507 (source
1508 (origin
1509 (method url-fetch)
1510 (uri (string-append "http://www.ifarchive.org/if-archive/programming/"
1511 "glk/implementations/glkterm-104.tar.gz"))
1512 (sha256
1513 (base32
1514 "0zlj9nlnkdlvgbiliczinirqygiq8ikg5hzh5vgcmnpg9pvnwga7"))))
1515 (build-system gnu-build-system)
1516 (propagated-inputs `(("ncurses" ,ncurses))) ; required by Make.glkterm
1517 (arguments
1518 '(#:tests? #f ; no check target
1519 #:phases
1520 (modify-phases %standard-phases
1521 (replace 'install
1522 (lambda* (#:key outputs #:allow-other-keys)
1523 (let* ((out (assoc-ref outputs "out"))
1524 (inc (string-append out "/include"))
1525 (lib (string-append out "/lib")))
1526 (for-each
1527 (lambda (file)
1528 (install-file file inc))
1529 '("glk.h" "glkstart.h" "gi_blorb.h" "gi_dispa.h" "Make.glkterm"))
1530 (install-file "libglkterm.a" lib))
1531 #t))
1532 (delete 'configure)))) ; no configure script
1533 (home-page "http://www.eblong.com/zarf/glk/")
1534 (synopsis "Curses Implementation of the Glk API")
1535 (description
1536 "Glk defines a portable API for applications with text UIs. It was
1537 primarily designed for interactive fiction, but it should be suitable for many
1538 interactive text utilities, particularly those based on a command line.
1539 This is an implementation of the Glk library which runs in a terminal window,
1540 using the @code{curses.h} library for screen control.")
1541 (license (license:fsf-free "file://README"))))
1542
1543 (define-public glulxe
1544 (package
1545 (name "glulxe")
1546 (version "0.5.4")
1547 (source
1548 (origin
1549 (method url-fetch)
1550 (uri (string-append "http://www.ifarchive.org/if-archive/programming/"
1551 "glulx/interpreters/glulxe/glulxe-054.tar.gz"))
1552 (sha256
1553 (base32
1554 "0vipydg6ra90yf9b3ipgppwxyb2xdhcxwvirgjy0v20wlf56zhhz"))))
1555 (build-system gnu-build-system)
1556 (inputs `(("glk" ,glkterm)))
1557 (arguments
1558 '(#:tests? #f ; no check target
1559 #:make-flags
1560 (let* ((glk (assoc-ref %build-inputs "glk")))
1561 (list (string-append "GLKINCLUDEDIR=" glk "/include")
1562 (string-append "GLKLIBDIR=" glk "/lib")
1563 (string-append "GLKMAKEFILE=" "Make.glkterm")))
1564 #:phases
1565 (modify-phases %standard-phases
1566 (replace 'install
1567 (lambda* (#:key outputs #:allow-other-keys)
1568 (let* ((out (assoc-ref outputs "out"))
1569 (bin (string-append out "/bin")))
1570 (install-file "glulxe" bin))
1571 #t))
1572 (delete 'configure)))) ; no configure script
1573 (home-page "http://www.eblong.com/zarf/glulx/")
1574 (synopsis "Interpreter for Glulx VM")
1575 (description
1576 "Glulx is a 32-bit portable virtual machine intended for writing and
1577 playing interactive fiction. It was designed by Andrew Plotkin to relieve
1578 some of the restrictions in the venerable Z-machine format. This is the
1579 reference interpreter, using the Glk API.")
1580 (license license:expat)))
1581
1582 (define-public fizmo
1583 (package
1584 (name "fizmo")
1585 (version "0.8.4")
1586 (source (origin
1587 (method url-fetch)
1588 (uri (string-append "https://christoph-ender.de/fizmo/source/"
1589 name "-" version ".tar.gz"))
1590 (sha256
1591 (base32
1592 "1sd988db2302r7cbfcfghbmg8ck43c6hvnlnlpb0rqxb7pm9cwyy"))))
1593 (build-system gnu-build-system)
1594 (arguments
1595 '(#:configure-flags
1596 (let ((libjpeg (assoc-ref %build-inputs "libjpeg"))
1597 (ncurses (assoc-ref %build-inputs "ncurses")))
1598 (list (string-append "jpeg_CFLAGS=-I" libjpeg "/include")
1599 (string-append "jpeg_LIBS=-ljpeg")
1600 (string-append "ncursesw_CFLAGS=-I" ncurses "/include")
1601 (string-append "ncursesw_LIBS=-lncursesw")))))
1602 (native-inputs
1603 `(("pkg-config" ,pkg-config)))
1604 (inputs
1605 `(("freetype" ,freetype)
1606 ("libjpeg" ,libjpeg)
1607 ("libpng" ,libpng)
1608 ("libsndfile" ,libsndfile)
1609 ("libxml2" ,libxml2)
1610 ("ncurses" ,ncurses)
1611 ("sdl2" ,sdl2)))
1612 (home-page "https://christoph-ender.de/fizmo/")
1613 (synopsis "Z-machine interpreter")
1614 (description
1615 "Fizmo is a console-based Z-machine interpreter. It is used to play
1616 interactive fiction, also known as text adventures, which were implemented
1617 either by Infocom or created using the Inform compiler.")
1618 (license license:bsd-3)))
1619
1620 (define-public gnugo
1621 (package
1622 (name "gnugo")
1623 (version "3.8")
1624 (source (origin
1625 (method url-fetch)
1626 (uri (string-append "mirror://gnu/gnugo/gnugo-" version
1627 ".tar.gz"))
1628 (sha256
1629 (base32
1630 "0wkahvqpzq6lzl5r49a4sd4p52frdmphnqsfdv7gdp24bykdfs6s"))))
1631 (build-system gnu-build-system)
1632 (inputs `(("readline" ,readline)))
1633 (synopsis "Play the game of Go")
1634 (description
1635 "GNU Go is a program that plays the game of Go, in which players
1636 place stones on a grid to form territory or capture other stones. While
1637 it can be played directly from the terminal, rendered in ASCII characters,
1638 it is also possible to play GNU Go with 3rd party graphical interfaces or
1639 even in Emacs. It supports the standard game storage format (SGF, Smart
1640 Game Format) and inter-process communication format (GMP, Go Modem
1641 Protocol).")
1642 (home-page "https://www.gnu.org/software/gnugo/")
1643 (license license:gpl3+)))
1644
1645 (define-public extremetuxracer
1646 (package
1647 (name "extremetuxracer")
1648 (version "0.7.4")
1649 (source (origin
1650 (method url-fetch)
1651 (uri (string-append
1652 "mirror://sourceforge/extremetuxracer/releases/"
1653 version "/etr-" version ".tar.xz"))
1654 (sha256
1655 (base32
1656 "0d2j4ybdjmimg67v2fndgahgq4fvgz3fpfb3a4l1ar75n6hy776s"))))
1657 (build-system gnu-build-system)
1658 (native-inputs
1659 `(("pkg-config" ,pkg-config)))
1660 (inputs
1661 `(("glu" ,glu)
1662 ("sfml" ,sfml)))
1663 (synopsis "High speed arctic racing game based on Tux Racer")
1664 ;; Snarfed straight from Debian
1665 (description "Extreme Tux Racer, or etracer as it is called for short, is
1666 a simple OpenGL racing game featuring Tux, the Linux mascot. The goal of the
1667 game is to slide down a snow- and ice-covered mountain as quickly as possible,
1668 avoiding the trees and rocks that will slow you down.
1669
1670 Collect herrings and other goodies while sliding down the hill, but avoid fish
1671 bones.
1672
1673 This game is based on the GPL version of the famous game TuxRacer.")
1674 (home-page "https://sourceforge.net/projects/extremetuxracer/")
1675 (license license:gpl2+)))
1676
1677 (define-public supertuxkart
1678 (package
1679 (name "supertuxkart")
1680 (version "0.9.3")
1681 (source
1682 (origin
1683 (method url-fetch)
1684 (uri (string-append "mirror://sourceforge/supertuxkart/SuperTuxKart/"
1685 version "/supertuxkart-" version "-src.tar.xz"))
1686 (sha256
1687 (base32
1688 "1c4w47ibj87lgwiqygq8qi7jiz6gklj4dwf5bs5zk15s0rqlw0fq"))
1689 (modules '((guix build utils)))
1690 (snippet
1691 ;; Delete bundled library sources
1692 '(begin
1693 ;; FIXME: try to unbundle enet, and angelscript
1694 (for-each delete-file-recursively
1695 '("lib/zlib"
1696 "lib/libpng"
1697 "lib/jpeglib"
1698 "lib/glew"
1699 "lib/wiiuse"))
1700 (substitute* "CMakeLists.txt"
1701 ;; Supertuxkart uses modified versions of the Irrlicht engine
1702 ;; and the bullet library. The developers gave an explanation here:
1703 ;; http://forum.freegamedev.net/viewtopic.php?f=17&t=3906
1704 (("add_subdirectory\\(.*/(glew|zlib)\"\\)") ""))
1705 #t))))
1706 (build-system cmake-build-system)
1707 (arguments
1708 `(#:tests? #f ; no check target
1709 #:configure-flags
1710 (list "-DUSE_WIIUSE=0"
1711 ;; Do not use the bundled zlib
1712 "-DNO_IRR_COMPILE_WITH_ZLIB_=TRUE"
1713 ;; FIXME: needs libopenglrecorder
1714 "-DBUILD_RECORDER=0"
1715 ;; Irrlicht returns an integer instead of a boolean
1716 "-DCMAKE_C_FLAGS=-fpermissive")
1717 #:phases
1718 (modify-phases %standard-phases
1719 (add-after 'unpack 'unbundle
1720 (lambda* (#:key inputs #:allow-other-keys)
1721 (substitute* "CMakeLists.txt"
1722 (("glew")
1723 (string-append (assoc-ref inputs "glew")
1724 "/lib/libGLEW.a"))
1725 (("include_directories\\(\"\\$\\{PROJECT_SOURCE_DIR\\}/lib/glew/include\"\\)")
1726 (string-append "include_directories(\""
1727 (assoc-ref inputs "glew")
1728 "/include\")")))
1729 #t)))))
1730 (inputs
1731 `(("glew" ,glew)
1732 ("zlib" ,zlib)
1733 ("openal" ,openal)
1734 ("libvorbis" ,libvorbis)
1735 ("freetype" ,freetype)
1736 ("fribidi" ,fribidi)
1737 ("mesa" ,mesa)
1738 ("libx11" ,libx11)
1739 ("libxrandr" ,libxrandr)
1740 ("curl" ,curl)
1741 ;; The following input is needed to build the bundled and modified
1742 ;; version of irrlicht.
1743 ("libjpeg" ,libjpeg)))
1744 (native-inputs
1745 `(("pkg-config" ,pkg-config)))
1746 (home-page "https://supertuxkart.net/")
1747 (synopsis "3D kart racing game")
1748 (description "SuperTuxKart is a 3D kart racing game, with a focus on
1749 having fun over realism. You can play with up to 4 friends on one PC, racing
1750 against each other or just trying to beat the computer; single-player mode is
1751 also available.")
1752 (license license:gpl3+)))
1753
1754 (define-public gnujump
1755 (package
1756 (name "gnujump")
1757 (version "1.0.8")
1758 (source (origin
1759 (method url-fetch)
1760 (uri (string-append "mirror://gnu/gnujump/gnujump-"
1761 version ".tar.gz"))
1762 (sha256
1763 (base32
1764 "05syy9mzbyqcfnm0hrswlmhwlwx54f0l6zhcaq8c1c0f8dgzxhqk"))))
1765 (build-system gnu-build-system)
1766 (arguments
1767 '(#:phases
1768 (modify-phases %standard-phases
1769 (add-before
1770 'configure 'link-libm
1771 (lambda _ (setenv "LIBS" "-lm"))))))
1772 (inputs
1773 `(("glu" ,glu)
1774 ("mesa" ,mesa)
1775 ("sdl" ,sdl)
1776 ("sdl-image" ,sdl-image)
1777 ("sdl-mixer" ,sdl-mixer)))
1778 (home-page "http://gnujump.es.gnu.org/")
1779 (synopsis
1780 "Game of jumping to the next floor, trying not to fall")
1781 (description
1782 "GNUjump is a simple, yet addictive game in which you must jump from
1783 platform to platform to avoid falling, while the platforms drop at faster rates
1784 the higher you go. The game features multiplayer, unlimited FPS, smooth floor
1785 falling, themeable graphics and sounds, and replays.")
1786 (license license:gpl3+)))
1787
1788 (define-public wesnoth
1789 (package
1790 (name "wesnoth")
1791 (version "1.12.6")
1792 (source (origin
1793 (method url-fetch)
1794 (uri (string-append "mirror://sourceforge/wesnoth/wesnoth-"
1795 (version-major+minor version) "/wesnoth-"
1796 version "/"
1797 name "-" version ".tar.bz2"))
1798 (sha256
1799 (base32
1800 "0kifp6g1dsr16m6ngjq2hx19h851fqg326ps3krnhpyix963h3x5"))))
1801 (build-system cmake-build-system)
1802 (arguments
1803 '(#:tests? #f ; no check target
1804 #:configure-flags
1805 ;; XXX: Failed to compile with '-Werror=old-style-cast'.
1806 ;; boost/mpl/assert.hpp:313:58: error:
1807 ;; use of old-style cast [-Werror=old-style-cast]
1808 ;; [...]
1809 ;; cc1plus: all warnings being treated as errors
1810 '("-DENABLE_STRICT_COMPILATION=OFF")))
1811 (native-inputs
1812 `(("gettext" ,gettext-minimal)
1813 ("pkg-config" ,pkg-config)))
1814 (inputs
1815 `(("boost" ,boost)
1816 ("dbus" ,dbus)
1817 ("fribidi" ,fribidi)
1818 ("libvorbis" ,libvorbis)
1819 ("pango" ,pango)
1820 ("sdl-image" ,sdl-image)
1821 ("sdl-mixer" ,sdl-mixer)
1822 ("sdl-net" ,sdl-net)
1823 ("sdl-ttf" ,sdl-ttf)))
1824 (home-page "http://www.wesnoth.org/")
1825 (synopsis "Turn-based strategy game")
1826 (description
1827 "The Battle for Wesnoth is a fantasy, turn based tactical strategy game,
1828 with several single player campaigns, and multiplayer games (both networked and
1829 local).
1830
1831 Battle for control on a range of maps, using variety of units which have
1832 advantages and disadvantages against different types of attacks. Units gain
1833 experience and advance levels, and are carried over from one scenario to the
1834 next campaign.")
1835 (license license:gpl2+)))
1836
1837 (define-public wesnoth-server
1838 (package
1839 (inherit wesnoth)
1840 (name "wesnoth-server")
1841 (inputs
1842 `(("boost" ,boost)
1843 ("sdl-net" ,sdl-net)))
1844 (arguments
1845 (append
1846 (substitute-keyword-arguments (package-arguments wesnoth)
1847 ((#:configure-flags configure-flags)
1848 `(append ,configure-flags (list "-DENABLE_GAME=OFF"))))
1849 `(#:phases
1850 (modify-phases %standard-phases
1851 ;; Delete game assets not required by the server.
1852 (add-after 'install 'delete-data
1853 (lambda* (#:key outputs #:allow-other-keys)
1854 (delete-file-recursively (string-append (assoc-ref outputs "out")
1855 "/share/wesnoth"))))))))
1856 (synopsis "Dedicated @emph{Battle for Wesnoth} server")
1857 (description "This package contains a dedicated server for @emph{The
1858 Battle for Wesnoth}.")))
1859
1860 (define-public gamine
1861 (package
1862 (name "gamine")
1863 (version "1.5")
1864 (source (origin
1865 (method url-fetch)
1866 (uri (string-append "mirror://sourceforge/gamine-game/"
1867 "gamine-" version ".tar.gz"))
1868 (sha256
1869 (base32
1870 "08wnk7w84c2413hwny89j2cn89cvfdf67bfc6wl0bf475if0mf4h"))))
1871 (build-system gnu-build-system)
1872 (native-inputs
1873 `(("pkg-config" ,pkg-config)
1874 ("intltool" ,intltool)))
1875 (inputs
1876 `(("gstreamer" ,gstreamer)
1877 ("gst-plugins-base" ,gst-plugins-base) ;playbin plugin
1878 ("gst-plugins-good" ,gst-plugins-good) ;for wav playback
1879 ("gtk+" ,gtk+)))
1880 (arguments
1881 `(#:tests? #f
1882 #:make-flags
1883 (let ((out (assoc-ref %outputs "out")))
1884 (list (string-append "PREFIX=" out)
1885 (string-append "SYSCONFDIR=" out "/etc")))
1886 #:phases
1887 (modify-phases %standard-phases
1888 (delete 'configure)
1889 (add-after
1890 'install 'wrap-gamine
1891 (lambda* (#:key outputs #:allow-other-keys)
1892 (let ((out (assoc-ref outputs "out"))
1893 (gst-plugin-path (getenv "GST_PLUGIN_SYSTEM_PATH")))
1894 (wrap-program (string-append out "/bin/gamine")
1895 `("GST_PLUGIN_SYSTEM_PATH" ":" prefix (,gst-plugin-path))))
1896 #t)))))
1897 (home-page "http://gamine-game.sourceforge.net/")
1898 (synopsis "Mouse and keyboard discovery for children")
1899 (description
1900 "Gamine is a game designed for young children who are learning to use the
1901 mouse and keyboard. The child uses the mouse to draw colored dots and lines
1902 on the screen and keyboard to display letters.")
1903 ;; Most files under gpl2+ or gpl3+, but eat.wav under gpl3
1904 (license license:gpl3)))
1905
1906 (define-public raincat
1907 (package
1908 (name "raincat")
1909 (version "1.1.1.3")
1910 (source
1911 (origin
1912 (method url-fetch)
1913 (uri (string-append
1914 "http://hackage.haskell.org/package/Raincat/Raincat-"
1915 version
1916 ".tar.gz"))
1917 (sha256
1918 (base32
1919 "1aalh68h6799mv4vyg30zpskl5jkn6x2j1jza7p4lrflyifxzar8"))))
1920 (build-system haskell-build-system)
1921 (inputs
1922 `(("ghc-extensible-exceptions" ,ghc-extensible-exceptions)
1923 ("ghc-mtl" ,ghc-mtl)
1924 ("ghc-random" ,ghc-random)
1925 ("ghc-glut" ,ghc-glut)
1926 ("freeglut" ,freeglut)
1927 ("ghc-opengl" ,ghc-opengl)
1928 ("ghc-sdl" ,ghc-sdl)
1929 ("ghc-sdl-image" ,ghc-sdl-image)
1930 ("ghc-sdl-mixer" ,ghc-sdl-mixer)))
1931 (home-page "http://www.bysusanlin.com/raincat/")
1932 (synopsis "Puzzle game with a cat in lead role")
1933 (description "Project Raincat is a game developed by Carnegie Mellon
1934 students through GCS during the Fall 2008 semester. Raincat features game
1935 play inspired from classics Lemmings and The Incredible Machine. The project
1936 proved to be an excellent learning experience for the programmers. Everything
1937 is programmed in Haskell.")
1938 (license license:bsd-3)))
1939
1940 (define-public manaplus
1941 (package
1942 (name "manaplus")
1943 (version "1.7.6.10")
1944 (source (origin
1945 (method url-fetch)
1946 (uri (string-append
1947 "http://repo.manaplus.org/manaplus/download/"
1948 version "/manaplus-" version ".tar.xz"))
1949 (sha256
1950 (base32
1951 "0l7swvpzq20am4w2rsjpp6fsvbjv07il6wbfy45a7h9zsdihmqhl"))))
1952 (build-system gnu-build-system)
1953 (arguments
1954 '(#:configure-flags
1955 (list (string-append "CPPFLAGS=-I"
1956 (assoc-ref %build-inputs "sdl-union")
1957 "/include/SDL"))))
1958 (native-inputs
1959 `(("pkg-config" ,pkg-config)))
1960 (inputs
1961 `(("glu" ,glu)
1962 ("curl" ,curl)
1963 ("libxml2" ,libxml2)
1964 ("mesa" ,mesa)
1965 ("sdl-union" ,(sdl-union))))
1966 (home-page "http://manaplus.org")
1967 (synopsis "Client for 'The Mana World' and similar games")
1968 (description
1969 "ManaPlus is a 2D MMORPG client for game servers. It is the only
1970 fully supported client for @uref{http://www.themanaworld.org, The mana
1971 world}, @uref{http://evolonline.org, Evol Online} and
1972 @uref{http://landoffire.org, Land of fire}.")
1973 ;; "src/debug/*" and "src/sdl2gfx/*" are under Zlib.
1974 ;; "data/themes/{golden-delicious,jewelry}/*" are under CC-BY-SA.
1975 ;; The rest is under GPL2+.
1976 (license (list license:gpl2+ license:zlib license:cc-by-sa4.0))))
1977
1978 (define openttd-engine
1979 (package
1980 (name "openttd-engine")
1981 (version "1.7.1")
1982 (source
1983 (origin (method url-fetch)
1984 (uri (string-append "http://binaries.openttd.org/releases/"
1985 version "/openttd-" version "-source.tar.xz"))
1986 (sha256
1987 (base32
1988 "0dhv5bbbg1dmmq7fi3xss0a9jq2rqgb5sf9fsqzlsjcdm590j6b1"))
1989 (modules '((guix build utils)))
1990 (snippet
1991 ;; The DOS port contains proprietary software.
1992 '(delete-file-recursively "os/dos"))))
1993 (build-system gnu-build-system)
1994 (arguments
1995 `(#:tests? #f ; no "check" target
1996 #:phases
1997 (modify-phases %standard-phases
1998 ;; The build process fails if the configure script is passed the
1999 ;; option "--enable-fast-install".
2000 (replace 'configure
2001 (lambda* (#:key inputs outputs (configure-flags '())
2002 #:allow-other-keys)
2003 (let ((out (assoc-ref outputs "out"))
2004 (lzo (assoc-ref inputs "lzo")))
2005 (zero?
2006 (apply system* "./configure"
2007 (string-append "--prefix=" out)
2008 ;; Provide the "lzo" path.
2009 (string-append "--with-liblzo2="
2010 lzo "/lib/liblzo2.a")
2011 ;; Put the binary in 'bin' instead of 'games'.
2012 "--binary-dir=bin"
2013 configure-flags))))))))
2014 (native-inputs `(("pkg-config" ,pkg-config)))
2015 (inputs
2016 `(("allegro" ,allegro-4)
2017 ("fontconfig" ,fontconfig)
2018 ("freetype" ,freetype)
2019 ("icu4c" ,icu4c)
2020 ("libpng" ,libpng)
2021 ("lzo" ,lzo)
2022 ("sdl" ,sdl)
2023 ("xz" ,xz)
2024 ("zlib" ,zlib)))
2025 (synopsis "Transportation economics simulator")
2026 (description "OpenTTD is a game in which you transport goods and
2027 passengers by land, water and air. It is a re-implementation of Transport
2028 Tycoon Deluxe with many enhancements including multiplayer mode,
2029 internationalization support, conditional orders and the ability to clone,
2030 autoreplace and autoupdate vehicles. This package only includes the game
2031 engine. When you start it you will be prompted to download a graphics set.")
2032 (home-page "http://openttd.org/")
2033 ;; This package is GPLv2, except for a few files located in
2034 ;; "src/3rdparty/" which are under the 3-clause BSD, LGPLv2.1+ and Zlib
2035 ;; licenses. In addition, this software contains an in-game downloader
2036 ;; from which the user may find non-functional data licensed under
2037 ;; different terms.
2038 (license (list license:bsd-3 license:gpl2 license:lgpl2.1+ license:zlib))))
2039
2040 (define openttd-opengfx
2041 (package
2042 (name "openttd-opengfx")
2043 (version "0.5.2")
2044 (source
2045 (origin
2046 (method url-fetch)
2047 (uri (string-append "http://binaries.openttd.org/extra/opengfx/"
2048 version "/opengfx-" version "-source.tar.xz"))
2049 (sha256
2050 (base32
2051 "0iz66q7p1mf00njfjbc4vibh3jaybki7armkl18iz7p6x4chp9zv"))))
2052 (build-system gnu-build-system)
2053 (arguments
2054 '(#:make-flags (list "CC=gcc"
2055 (string-append "INSTALL_DIR="
2056 (assoc-ref %outputs "out")
2057 "/share/games/openttd/baseset/opengfx"))
2058 #:phases
2059 (modify-phases %standard-phases
2060 (replace 'configure
2061 (lambda _
2062 ;; Make sure HOME is writable for GIMP.
2063 (setenv "HOME" (getcwd))
2064
2065 ;; Redirect stdout, not stderr, to /dev/null. This prevents
2066 ;; dos2unix from receiving its version information as a flag.
2067 (substitute* "Makefile"
2068 (("\\$\\(UNIX2DOS\\) -q --version 2>/dev/null")
2069 "$(UNIX2DOS) -q --version 1>/dev/null")))))
2070 ;; The check phase for this package only checks the md5sums of the built
2071 ;; GRF files against the md5sums of the release versions. Because we use
2072 ;; different software versions than upstream does, some of the md5sums
2073 ;; are different. However, the package is still reproducible, it's safe
2074 ;; to disable this test.
2075 #:tests? #f
2076 #:parallel-build? #f))
2077 (native-inputs `(("dos2unix" ,dos2unix)
2078 ("gimp" ,gimp)
2079 ("grfcodec" ,grfcodec)
2080 ("nml" ,nml)
2081 ("python" ,python-2)))
2082 (home-page "http://dev.openttdcoop.org/projects/opengfx")
2083 (synopsis "Base graphics set for OpenTTD")
2084 (description
2085 "The OpenGFX projects is an implementation of the OpenTTD base grahics
2086 set that aims to ensure the best possible out-of-the-box experience.
2087
2088 OpenGFX provides you with...
2089 @enumerate
2090 @item All graphics you need to enjoy OpenTTD.
2091 @item Uniquely drawn rail vehicles for every climate.
2092 @item Completely snow-aware rivers.
2093 @item Different river and sea water.
2094 @item Snow-aware buoys.
2095 @end enumerate")
2096 (license license:gpl2)))
2097
2098 (define openttd-opensfx
2099 (package
2100 (name "openttd-opensfx")
2101 (version "0.2.3")
2102 (source
2103 (origin
2104 (method url-fetch)
2105 (uri (string-append
2106 "https://binaries.openttd.org/extra/opensfx/"
2107 version "/opensfx-" version "-source.tar.gz"))
2108 (sha256
2109 (base32
2110 "03jxgp02ks31hmsdh4xh0xcpkb70ds8jakc9pfc1y9vdrdavh4p5"))))
2111 (build-system gnu-build-system)
2112 (native-inputs
2113 `(("catcodec" ,catcodec)
2114 ("python" ,python2-minimal)))
2115 (arguments
2116 `(#:make-flags
2117 (list (string-append "INSTALL_DIR=" %output
2118 "/share/games/openttd/baseset/opensfx"))
2119 #:phases
2120 (modify-phases %standard-phases
2121 (add-after 'unpack 'make-reproducible
2122 (lambda _
2123 ;; Remove the time dependency of the installed tarball by setting
2124 ;; the modification times if its members to 0.
2125 (substitute* "scripts/Makefile.def"
2126 (("-cf") " --mtime=@0 -cf"))
2127 #t))
2128 (delete 'configure))))
2129 (home-page "http://dev.openttdcoop.org/projects/opensfx")
2130 (synopsis "Base sounds for OpenTTD")
2131 (description "OpenSFX is a set of free base sounds for OpenTTD which make
2132 it possible to play OpenTTD without requiring the proprietary sound files from
2133 the original Transport Tycoon Deluxe.")
2134 (license license:cc-sampling-plus-1.0)))
2135
2136 (define openttd-openmsx
2137 (package
2138 (name "openttd-openmsx")
2139 (version "0.3.1")
2140 (source
2141 (origin
2142 (method url-fetch)
2143 (uri (string-append
2144 "https://binaries.openttd.org/extra/openmsx/"
2145 version "/openmsx-" version "-source.tar.gz"))
2146 (sha256
2147 (base32
2148 "0nskq97a6fsv1v6d62zf3yb8whzhqnlh3lap3va3nzvj7csjgf7c"))))
2149 (build-system gnu-build-system)
2150 (native-inputs
2151 `(("python" ,python2-minimal)))
2152 (arguments
2153 `(#:make-flags
2154 (list (string-append "INSTALL_DIR=" %output
2155 "/share/games/openttd/baseset"))
2156 #:phases
2157 (modify-phases %standard-phases
2158 (delete 'configure)
2159 (add-after 'install 'post-install
2160 ;; Rename openmsx-version to openmsx
2161 (lambda* (#:key outputs #:allow-other-keys)
2162 (let ((install-directory (string-append (assoc-ref outputs "out")
2163 "/share/games/openttd/baseset")))
2164 (rename-file (string-append install-directory "/openmsx-" ,version)
2165 (string-append install-directory "/openmsx"))
2166 #t))))))
2167 (home-page "http://dev.openttdcoop.org/projects/openmsx")
2168 (synopsis "Music set for OpenTTD")
2169 (description "OpenMSX is a music set for OpenTTD which makes it possible
2170 to play OpenTTD without requiring the proprietary music from the original
2171 Transport Tycoon Deluxe.")
2172 (license license:gpl2)))
2173
2174 (define-public openttd
2175 (package
2176 (inherit openttd-engine)
2177 (name "openttd")
2178 (arguments
2179 `(#:configure-flags
2180 (list (string-append "--with-midi=" (assoc-ref %build-inputs "timidity++")
2181 "/bin/timidity"))
2182 ,@(substitute-keyword-arguments (package-arguments openttd-engine)
2183 ((#:phases phases)
2184 `(modify-phases ,phases
2185 (add-after 'install 'install-data
2186 (lambda* (#:key inputs outputs #:allow-other-keys)
2187 (for-each
2188 (lambda (input)
2189 (copy-recursively (assoc-ref inputs input)
2190 (assoc-ref outputs "out")))
2191 (list "opengfx" "openmsx" "opensfx"))
2192 #t)))))))
2193 (inputs
2194 `(("timidity++" ,timidity++)
2195 ,@(package-inputs openttd-engine)))
2196 (native-inputs
2197 `(("opengfx" ,openttd-opengfx)
2198 ("openmsx" ,openttd-openmsx)
2199 ("opensfx" ,openttd-opensfx)
2200 ,@(package-native-inputs openttd-engine)))))
2201
2202 (define-public openrct2
2203 (package
2204 (name "openrct2")
2205 (version "0.1.1")
2206 (source
2207 (origin
2208 (method url-fetch)
2209 (uri (string-append "https://github.com/OpenRCT2/OpenRCT2/archive/v"
2210 version ".tar.gz"))
2211 (sha256
2212 (base32
2213 "1bahkzlf9k92cc4zs4nk4wy59323kiw8d3wm0vjps3kp7iznqyjx"))
2214 (file-name (string-append name "-" version ".tar.gz"))))
2215 (build-system cmake-build-system)
2216 (arguments
2217 `(#:tests? #f ;; no tests available
2218 #:phases
2219 (modify-phases %standard-phases
2220 (add-after 'unpack 'fix-usr-share-paths
2221 (lambda* (#:key make-flags outputs #:allow-other-keys)
2222 ;; Fix some references to /usr/share.
2223 (substitute* "src/openrct2/platform/linux.c"
2224 (("/usr/share")
2225 (string-append (assoc-ref %outputs "out") "/share")))))
2226 (add-after 'build 'fix-cmake-install-file
2227 (lambda _
2228 ;; The build system tries to download a file and compare hashes.
2229 ;; Since we have no network, remove this so the install doesn't fail.
2230 (substitute* "cmake_install.cmake"
2231 (("EXPECTED_HASH SHA1=b587d83de508d0b104d14c599b76f8565900fce0")
2232 "")))))))
2233 (inputs `(("curl" ,curl)
2234 ("fontconfig" ,fontconfig)
2235 ("freetype" ,freetype)
2236 ("jansson" ,jansson)
2237 ("libpng" ,libpng)
2238 ("libzip" ,libzip)
2239 ("mesa" ,mesa)
2240 ("openssl" ,openssl)
2241 ("sdl2" ,sdl2)
2242 ("speexdsp" ,speexdsp)
2243 ("zlib" ,zlib)))
2244 (native-inputs
2245 `(("pkg-config" ,pkg-config)))
2246 (home-page "https://github.com/OpenRCT2/OpenRCT2")
2247 (synopsis "Free software re-implementation of RollerCoaster Tycoon 2")
2248 (description "OpenRCT2 is a free software re-implementation of
2249 RollerCoaster Tycoon 2 (RCT2). The gameplay revolves around building and
2250 maintaining an amusement park containing attractions, shops and facilities.
2251
2252 Note that this package does @emph{not} provide the game assets (sounds,
2253 images, etc.)")
2254 ;; See <https://github.com/OpenRCT2/OpenRCT2/wiki/Required-RCT2-files>
2255 ;; regarding assets.
2256 (license license:gpl3+)))
2257
2258 (define-public pinball
2259 (package
2260 (name "pinball")
2261 (version "0.3.1")
2262 (source
2263 (origin (method url-fetch)
2264 (uri (string-append "mirror://sourceforge/pinball/pinball/"
2265 "pinball-" version "/"
2266 "pinball-" version ".tar.gz"))
2267 (sha256
2268 (base32
2269 "1f2whlrfidwfh8lvr8cspcyirc6840r5d1ajm7x99qmngygrhixs"))
2270 (patches (search-patches "pinball-const-fix.patch"
2271 "pinball-cstddef.patch"
2272 "pinball-missing-separators.patch"
2273 "pinball-src-deps.patch"
2274 "pinball-system-ltdl.patch"))))
2275 (build-system gnu-build-system)
2276 (inputs
2277 `(("glu" ,glu)
2278 ("mesa" ,mesa)
2279 ("sdl" ,sdl)
2280 ("sdl-image" ,sdl-image)
2281 ("sdl-mixer" ,sdl-mixer)))
2282 (arguments
2283 '(#:configure-flags
2284 (list (string-append "CPPFLAGS=-I"
2285 (assoc-ref %build-inputs "sdl-image")
2286 "/include/SDL -I"
2287 (assoc-ref %build-inputs "sdl-mixer")
2288 "/include/SDL"))))
2289 (home-page "http://pinball.sourceforge.net")
2290 (synopsis "Pinball simulator")
2291 (description "The Emilia Pinball Project is a pinball simulator. There
2292 are only two levels to play with, but they are very addictive.")
2293 (license license:gpl2)))
2294
2295 (define-public pioneers
2296 (package
2297 (name "pioneers")
2298 (version "15.4")
2299 (source (origin
2300 (method url-fetch)
2301 (uri (string-append "http://downloads.sourceforge.net/pio/"
2302 "pioneers-" version ".tar.gz"))
2303 (sha256
2304 (base32
2305 "1p1d18hrfmqcnghip3shkzcs5qkz6j99jvkdkqfi7pqdvjc323cs"))))
2306 (build-system gnu-build-system)
2307 (inputs `(("gtk+" ,gtk+)
2308 ("librsvg" ,librsvg)
2309 ("avahi" ,avahi)))
2310 (native-inputs `(("intltool" ,intltool)
2311 ("pkg-config" ,pkg-config)))
2312 (synopsis "Board game inspired by The Settlers of Catan")
2313 (description "Pioneers is an emulation of the board game The Settlers of
2314 Catan. It can be played on a local network, on the internet, and with AI
2315 players.")
2316 (home-page "http://pio.sourceforge.net/")
2317 (license license:gpl2+)))
2318
2319 (define-public einstein
2320 (package
2321 (name "einstein")
2322 (version "2.0")
2323 (source (origin
2324 (method url-fetch)
2325 (uri (string-append "http://http.debian.net/debian/pool/main/e/"
2326 "einstein/einstein_2.0.dfsg.2.orig.tar.gz"))
2327 (sha256
2328 (base32
2329 "1hxrlv6n8py48j487i6wbb4n4vd55w0na69r7ccmmr9vmrsw5mlk"))
2330 (patches (search-patches "einstein-build.patch"))))
2331 (build-system gnu-build-system)
2332 (inputs
2333 `(("freetype" ,freetype)
2334 ("sdl" ,(sdl-union (list sdl sdl-mixer sdl-ttf)))
2335 ("zlib" ,zlib)))
2336 (native-inputs
2337 `(("font-dejavu" ,font-dejavu)))
2338 (arguments
2339 `(#:tests? #f ; no check target
2340 #:phases
2341 (modify-phases %standard-phases
2342 (replace 'configure
2343 (lambda* (#:key outputs inputs #:allow-other-keys)
2344 (let ((out (assoc-ref outputs "out"))
2345 (dejavu (string-append (assoc-ref inputs "font-dejavu")
2346 "/share/fonts/truetype/DejaVuSans.ttf")))
2347 (substitute* "Makefile"
2348 (("PREFIX=/usr/local") (string-append "PREFIX=" out)))
2349 ;; The patch above registers a free font for use by the binary,
2350 ;; but the font is copied during the compile phase into a
2351 ;; resources file, so we need to make the ttf file available.
2352 (symlink dejavu "res/DejaVuSans.ttf")
2353 #t))))))
2354 (synopsis "Logic puzzle game")
2355 (description "The goal of this logic game is to open all cards in a 6x6
2356 grid, using a number of hints as to their relative position. The game idea
2357 is attributed to Albert Einstein.")
2358 ;; The original home page has disappeared.
2359 (home-page (string-append "http://web.archive.org/web/20120521062745/"
2360 "http://games.flowix.com/en/index.html"))
2361 ;; License according to
2362 ;; http://web.archive.org/web/20150222180355/http://www.babichev.info/en/projects/index.html
2363 ;; The source code is a DFSG-sanitized tarball and does not contain any
2364 ;; license information.
2365 (license license:gpl3+)))
2366
2367 (define-public powwow
2368 (package
2369 (name "powwow")
2370 (version "1.2.17")
2371 (source (origin
2372 (method url-fetch)
2373 (uri (string-append
2374 "https://www.hoopajoo.net/static/projects/powwow-"
2375 version ".tar.gz"))
2376 (file-name (string-append name "-" version ".tar.gz"))
2377 (sha256
2378 (base32
2379 "1xmsg2y7qcvj67i9ilnih0mvfxcpni7fzrz343x9rdfnkkzf3pp8"))))
2380 (inputs
2381 `(("ncurses" ,ncurses)))
2382 (build-system gnu-build-system)
2383 (home-page "http://www.hoopajoo.net/projects/powwow.html")
2384 (synopsis "MUD and telnet client")
2385 (description
2386 "POWWOW is a client software which can be used for telnet as well as for
2387 @dfn{Multi-User Dungeon} (MUD). Additionally it can serve as a nice client for
2388 the chat server psyced with the specific config located at
2389 http://lavachat.symlynx.com/unix/")
2390 (license license:gpl2+)))
2391
2392 (define-public red-eclipse
2393 (let ((release "1.6.0")
2394 (revision 0)
2395 (data-sources
2396 '(("acerspyro" "07mzgdahnr3w3w7kf8nmy20r199rimfx9ryqxjdr793sw0vawqd3")
2397 ("actors" "1hkgscfhg0kmwgym0mw56fhcckzbb2hh3nsvd45v4mdfyk0xnrm7")
2398 ("appleflap" "1q4xs3x904mrrbxzv6lpr3lywm8p6i8339ijzy9j091s2wdl51ka")
2399 ("blendbrush" "004md2haysr9w8fj6l7bj9wcfjqrq9wx1rrjf9dv16k5sbrkqza9")
2400 ("caustics" "1qmmv8ds70j1ixy4rvli309vbcyjq1l5j1wri6nbnjay10f9fcgq")
2401 ("crosshairs" "0q1vadg5cai9i6igl6y08774fd05gav0kinbgb2757n47ig50bns")
2402 ("dziq" "1s9248ky2qqy24z9c2vgpisz500dvsaj249pv1fkrxgsypjm1z6v")
2403 ("elyvisions" "15synpms05996v4c4kdl0h899spl4z7si9kl8c4m7rvc2yvin1ga")
2404 ("fonts" "1l4727ai8mphi7n3wcjp2lh3p47nh6w82s5dpqbbjpqr9gilb69j")
2405 ("freezurbern" "0hcdbzs02mvpsfhmahhqjv6pd8lbsag1bm6rpy61ns5qwmhg96ys")
2406 ("john" "1whyvlx87mb83kfb7jhhnwz9s7lry4li8l3xar61vmlqgmsnz33d")
2407 ("jojo" "02wxa93f5al4rlnsdjpd0hlnca0ympnj8481lgdxx70hny8zi3qi")
2408 ("jwin" "1gb4l7lbhr150hml1y0wbyx7266q5nslh6n494wwrrsvp11s2qk8")
2409 ("luckystrike" "0wy2spvhx5k233fsl283250ym5bqvkk8i6i19sw3zvzyxp2p4yq9")
2410 ("maps" "1dmvp9mskval606z5srjd909jpm6qz4fdcpaszkkhfr5ajbj30vq")
2411 ("mayhem" "0hkzzx0rxda70ixw9lfh9v1dpsbn2dj86jrr3zxjgasbgaxw37ax")
2412 ("mikeplus64" "144fxhp4qjqjw3gvhf7ym6rnfxvxc0zvd3f54jg1jgnccc1hfyah")
2413 ("misc" "0bpvibyc6vjhbzsf67xxn85yq2h97xs96icbskwzs2wsd860kq8c")
2414 ("nieb" "0d72wsibk9sg9nhin3fwzz9zljiccyln0fn42y2q2xbd4my23b1k")
2415 ("nobiax" "19lr36ys98cmpp739svjar1j942fbxz6r062gi7ygh89zh9yrgfy")
2416 ("particles" "02pnq8ksl7f6kqxss3aza98jssdq2s41rhkhki71ynavp2a5akar")
2417 ("philipk" "1xkrb7wa1pyhbs4xxx7vnnzsxrqzswk7gjbdac7i7rj0lwnfaij2")
2418 ("projectiles" "1hra0f1ifiddh16fv4pqcr2amf046lf445v0653zkyri43zgrj5f")
2419 ("props" "0ff6a8pz62f4nsk4c9cr50kirw108a661y5j6fvlsjickw3xjmyv")
2420 ("skyboxes" "1lq58dhrdiivq7llkiyqwpi3bwa89r8hbi98p7zjhw7wdn34i6n2")
2421 ("snipergoth" "0d5qf01bxd4dlffgxf8i91zq6mbyjmfd00dpyligpfj6fdbz87gc")
2422 ("sounds" "0z6jmxsr3w735hrdnxypdb0gi399pwkaycv9grjpiqy43j3ic7gj")
2423 ("textures" "0k5a47g2z99xn17vw7bqbp0w726gxmk33g5gwmqvfhxxxzzwimvi")
2424 ("torley" "12x23l8xcv9ard5v76lb210lvp66whsns2p3k3xkd1sabp5ixbd5")
2425 ("trak" "03kmwj47yb3dqzb6k9kilna9ja8c6jcnblvbs72x15767fl496pb")
2426 ("ulukai" "0vvd016a7x981ixif6dnlg45s0ak7i89pgyrgwy2fpd94nl2am15")
2427 ("unnamed" "18sxvdha41njp6g8wn56mjy6w9x778c793gh8fr0h9cnysb5gfmi")
2428 ("vanities" "1p38mc2566bmb4vdyr9n9s6fkwmynp2xlpdq2a97gzgi4nmm0232")
2429 ("vegetation" "0pf3qvqzabdcri5za61z6m89b5hq7sd3q0idkazmx88a62mcclkb")
2430 ("weapons" "1jr05y9qhhx53plvir35srvv3cmn6wa065p3bskx6h1x6dcbx3c6")
2431 ("wicked" "14b9f92h8hccp7a015z6rqgbs8236sdyxnwsq991ylnap7cbwvam"))))
2432 (package
2433 (name "red-eclipse")
2434 (version (if (zero? revision)
2435 release
2436 (string-append release "-"
2437 (number->string revision))))
2438 (source (origin
2439 (method url-fetch)
2440 (uri (string-append "https://github.com/red-eclipse/base"
2441 "/archive/v" release ".tar.gz"))
2442 (file-name (string-append name "-" version ".tar.gz"))
2443 (sha256
2444 (base32
2445 "1vs9k6f5fgsiy1n72imlqm8khjwm8cryc08zwd4gr7yxlxv45bs0"))))
2446 (build-system gnu-build-system)
2447 (arguments
2448 `(#:tests? #f ; no check target
2449 #:make-flags (list "CC=gcc" "-Csrc"
2450 (string-append "INSTDIR="
2451 (assoc-ref %outputs "out") "/bin")
2452 (string-append "prefix="
2453 (assoc-ref %outputs "out")))
2454 #:phases
2455 (modify-phases %standard-phases
2456 (add-after 'unpack 'unpack-data
2457 (lambda* (#:key inputs #:allow-other-keys)
2458 (delete-file-recursively "data")
2459 (mkdir "data")
2460 (for-each (lambda (name)
2461 (invoke "tar" "-xvf"
2462 (assoc-ref inputs name)
2463 "-Cdata"
2464 "--transform"
2465 (string-append "s/"
2466 name "-" ,release "/"
2467 name "/")))
2468 (list ,@(map car data-sources)))
2469 #t))
2470 (add-after 'unpack-data 'add-store-data-package-path-as-default
2471 (lambda* (#:key outputs #:allow-other-keys)
2472 (substitute* "src/engine/server.cpp"
2473 (("(else[[:space:]]*)((addpackagedir\\()\"data\"(\\);))"
2474 _
2475 else_part
2476 addpackagedir_original
2477 addpackagedir_open
2478 addpackagedir_close)
2479 (string-append else_part
2480 "{ "
2481 addpackagedir_open
2482 "\""
2483 (assoc-ref outputs "out")
2484 "/share/redeclipse/data\""
2485 addpackagedir_close
2486 " "
2487 addpackagedir_original
2488 " }")))
2489 #t))
2490 (delete 'configure) ; no configure script
2491 (add-after 'set-paths 'set-sdl-paths
2492 (lambda* (#:key inputs #:allow-other-keys)
2493 (setenv "CPATH"
2494 (string-append (assoc-ref inputs "sdl-union")
2495 "/include/SDL2"))
2496 #t))
2497 (add-after 'install 'copy-data
2498 (lambda* (#:key outputs #:allow-other-keys)
2499 (let ((out (assoc-ref outputs "out")))
2500 (copy-recursively "config"
2501 (string-append out "/config"))
2502 (copy-file "doc/examples/servinit.cfg"
2503 (string-append out "/config/servinit.cfg"))
2504 (copy-recursively "data"
2505 (string-append out "/share/redeclipse/data"))
2506 (mkdir-p (string-append out "/lib/redeclipse"))
2507 (symlink (string-append out "/share/redeclipse/data")
2508 (string-append out "/lib/redeclipse/data")))
2509 #t))
2510 (add-after 'copy-data 'wrap-program
2511 (lambda* (#:key inputs outputs #:allow-other-keys)
2512 (let* ((out (assoc-ref outputs "out"))
2513 (bin (string-append out "/bin")))
2514 (with-directory-excursion bin
2515 (rename-file "redeclipse_linux"
2516 ".redeclipse_linux-real")
2517 (rename-file "redeclipse_server_linux"
2518 ".redeclipse_server_linux-real")
2519 (call-with-output-file "redeclipse_linux"
2520 (lambda (port)
2521 (format port "#!~a/bin/sh
2522 # Run the thing from its home, otherwise it just bails out.
2523 cd \"~a\"
2524 exec -a \"$0\" ~a/.redeclipse_linux-real~%"
2525 (assoc-ref inputs "bash") ;implicit input
2526 (string-append out)
2527 (string-append bin))))
2528 (call-with-output-file "redeclipse_server_linux"
2529 (lambda (port)
2530 (format port "#!~a/bin/sh
2531 # Run the thing from its home, otherwise it just bails out.
2532 cd \"~a\"
2533 exec -a \"$0\" ~a/.redeclipse_server_linux-real~%"
2534 (assoc-ref inputs "bash") ;implicit input
2535 (string-append out)
2536 (string-append bin))))
2537 (chmod "redeclipse_linux" #o555)
2538 (chmod "redeclipse_server_linux" #o555)))
2539 #t)))))
2540 (native-inputs `(("pkg-config" ,pkg-config)))
2541 (inputs
2542 `(("curl" ,curl)
2543 ("glu" ,glu)
2544 ("sdl-union" ,(sdl-union (list sdl2
2545 sdl2-image
2546 sdl2-mixer)))
2547 ;; Create origin records for the many separate data packages.
2548 ,@(map (match-lambda
2549 ((name hash)
2550 (list name
2551 (origin
2552 (method url-fetch)
2553 (uri (string-append
2554 "https://github.com/red-eclipse/"
2555 name "/archive/v" release ".tar.gz"))
2556 (sha256 (base32 hash))
2557 (file-name (string-append name "-" version
2558 ".tar.gz"))))))
2559 data-sources)))
2560 (home-page "http://redeclipse.net/")
2561 (synopsis "Arena shooter derived from the Cube 2 engine")
2562 (description
2563 "Red Eclipse is an arena shooter, created from the Cube2 engine.
2564 Offering an innovative parkour system and distinct but all potent weapons,
2565 Red Eclipse provides fast paced and accessible gameplay.")
2566 ;; The engine is under Zlib; data files are covered by the other
2567 ;; licenses. More details at <http://redeclipse.net/wiki/License>.
2568 (license (list license:expat
2569 license:zlib
2570 license:cc-by-sa3.0
2571 license:cc-by3.0
2572 license:cc0)))))
2573
2574 (define-public grue-hunter
2575 (package
2576 (name "grue-hunter")
2577 (version "1.0")
2578 (source (origin
2579 (method url-fetch)
2580 (uri (string-append "https://jxself.org/" name ".tar.gz"))
2581 (sha256
2582 (base32
2583 "1hjcpy5439qs3v2zykis7hsi0i17zjs62gks3zd8mnfw9ni4i2h3"))))
2584 (build-system trivial-build-system) ; no Makefile.PL
2585 (arguments `(#:modules ((guix build utils))
2586 #:builder
2587 (begin
2588 (use-modules (guix build utils))
2589 (use-modules (srfi srfi-1))
2590
2591 (let* ((tarball (assoc-ref %build-inputs "tarball"))
2592 (perl (string-append (assoc-ref %build-inputs
2593 "perl")
2594 "/bin"))
2595 (gzip (string-append (assoc-ref %build-inputs
2596 "gzip")
2597 "/bin/gzip"))
2598 (tar (string-append (assoc-ref %build-inputs
2599 "tar")
2600 "/bin/tar"))
2601 (out (assoc-ref %outputs "out"))
2602 (bin (string-append out "/bin"))
2603 (doc (string-append out
2604 "/share/doc/grue-hunter")))
2605 (begin
2606 (copy-file tarball "grue-hunter.tar.gz")
2607 (zero? (system* gzip "-d" "grue-hunter.tar.gz"))
2608 (zero? (system* tar "xvf" "grue-hunter.tar"))
2609
2610 (mkdir-p bin)
2611 (copy-file "grue-hunter/gh.pl"
2612 (string-append bin "/grue-hunter"))
2613 (patch-shebang (string-append bin "/grue-hunter")
2614 (list perl))
2615
2616 (install-file "grue-hunter/AGPLv3.txt" doc))))))
2617 (inputs `(("perl" ,perl)
2618 ("tar" ,tar)
2619 ("gzip" ,gzip)
2620 ("tarball" ,source)))
2621 (home-page "http://jxself.org/grue-hunter.shtml")
2622 (synopsis "Text adventure game")
2623 (description
2624 "Grue Hunter is a text adventure game written in Perl. You must make
2625 your way through an underground cave system in search of the Grue. Can you
2626 capture it and get out alive?")
2627 (license license:agpl3+)))
2628
2629 (define-public lierolibre
2630 (package
2631 (name "lierolibre")
2632 (version "0.5")
2633 (source (origin
2634 (method url-fetch)
2635 (uri (string-append "https://launchpad.net/lierolibre/trunk/"
2636 version "/+download/lierolibre-"
2637 version ".tar.xz"))
2638 (sha256
2639 (base32
2640 "1cf1gvsn4qq190lrf9k5bpjnqwlcfw7pajvdnh7z5r4jqw0rsbl9"))
2641 (patches
2642 (search-patches "lierolibre-check-unaligned-access.patch"
2643 "lierolibre-try-building-other-arch.patch"
2644 "lierolibre-remove-arch-warning.patch"
2645 "lierolibre-newer-libconfig.patch"
2646 "lierolibre-is-free-software.patch"))
2647 (modules '((guix build utils)))
2648 (snippet
2649 '(begin
2650 ;; Delete pre-compiled files.
2651 (delete-file "data/LIERO.CHR")
2652 (delete-file "data/LIERO.SND")
2653 #t))))
2654 (build-system gnu-build-system)
2655 (native-inputs
2656 `(("imagemagick" ,imagemagick)
2657 ("pkg-config" ,pkg-config)
2658 ("util-linux" ,util-linux)
2659 ("sox" ,sox)))
2660 (inputs
2661 `(("boost" ,boost)
2662 ("libconfig" ,libconfig)
2663 ("sdl-union" ,(sdl-union (list sdl sdl-image sdl-mixer)))
2664 ("zlib" ,zlib)))
2665 (home-page "https://gitlab.com/lierolibre/lierolibre")
2666 (synopsis "Old-school earthworm action game")
2667 (description
2668 "lierolibre is an earthworm action game where you fight another player
2669 (or the computer) underground using a wide array of weapons.
2670
2671 Features:
2672 @itemize
2673 @item 2 worms, 40 weapons, great playability, two game modes: Kill'em All
2674 and Game of Tag, plus AI-players without true intelligence!
2675 @item Dat nostalgia.
2676 @item Extensions via a hidden F1 menu:
2677 @itemize
2678 @item Replays
2679 @item Game controller support
2680 @item Powerlevel palettes
2681 @end itemize
2682 @item Ability to write game variables to plain text files.
2683 @item Ability to load game variables from both EXE and plain text files.
2684 @item Scripts to extract and repack graphics, sounds and levels.
2685 @end itemize
2686
2687 To switch between different window sizes, use F6, F7 and F8, to switch to
2688 fullscreen, use F5 or Alt+Enter.")
2689 ;; Code mainly BSD-2, some parts under Boost 1.0. All assets are WTFPL2.
2690 (license (list license:bsd-2 license:boost1.0 license:wtfpl2))))
2691
2692 (define-public warzone2100
2693 (package
2694 (name "warzone2100")
2695 (version "3.2.1")
2696 (source (origin
2697 (method url-fetch)
2698 (uri (string-append "mirror://sourceforge/" name
2699 "/releases/" version "/" name "-" version
2700 ".tar.xz"))
2701 (sha256
2702 (base32
2703 "1nd609s0g4sya3r4amhkz3f4dpdmm94vsd2ii76ap665a1nbfrhg"))))
2704 (build-system gnu-build-system)
2705 (arguments
2706 `(#:phases
2707 (modify-phases %standard-phases
2708 (add-after 'unpack 'link-tests-with-qt
2709 (lambda _
2710 (substitute* "tests/Makefile.in"
2711 (("(framework_linktest_LDADD|maptest_LDADD) = " prefix)
2712 (string-append prefix "$(QT5_LIBS) ")))
2713 #t))
2714 (add-after 'unpack 'remove-reference-to-missing-file
2715 (lambda _
2716 (substitute* "icons/Makefile.in"
2717 (("\\$\\(INSTALL_DATA\\) \\$\\(srcdir\\)/warzone2100.appdata.xml.*") ""))
2718 #t))
2719 (add-after 'unpack 'patch-for-qt5.8
2720 (lambda _
2721 (substitute* "lib/widget/editbox.cpp"
2722 (("== '\\\\0'")
2723 "== QChar('\\0')"))
2724 #t)))))
2725 (native-inputs `(("pkg-config" ,pkg-config)
2726 ("unzip" ,unzip)
2727 ("zip" ,zip)))
2728 (inputs `(("fontconfig" ,fontconfig)
2729 ("freetype" ,freetype)
2730 ("fribidi" ,fribidi)
2731 ("glew" ,glew)
2732 ("libtheora" ,libtheora)
2733 ("libvorbis" ,libvorbis)
2734 ("libxrandr" ,libxrandr)
2735 ("openal" ,openal)
2736 ("physfs" ,physfs)
2737 ("qtbase" ,qtbase)
2738 ("qtscript" ,qtscript)
2739 ("openssl" ,openssl)
2740 ("quesoglc" ,quesoglc)
2741 ("sdl2" ,sdl2)))
2742 (home-page "http://wz2100.net")
2743 (synopsis "3D Real-time strategy and real-time tactics game")
2744 (description
2745 "Warzone 2100 offers campaign, multi-player, and single-player skirmish
2746 modes. An extensive tech tree with over 400 different technologies, combined
2747 with the unit design system, allows for a wide variety of possible units and
2748 tactics.")
2749 ; Everything is GPLv2+ unless otherwise specified in COPYING.NONGPL
2750 (license (list license:bsd-3
2751 license:cc0
2752 license:cc-by-sa3.0
2753 license:expat
2754 license:gpl2+
2755 license:lgpl2.1+))))
2756
2757 (define-public starfighter
2758 (package
2759 (name "starfighter")
2760 (version "1.7")
2761 (source (origin
2762 (method url-fetch)
2763 (uri (string-append
2764 "mirror://savannah/starfighter/"
2765 (version-major+minor version) "/"
2766 name "-" version "-src.tar.gz"))
2767 (sha256
2768 (base32
2769 "1646hpjq8bz2fkfkja1dah511hn7zd2r7da4w9c9blhad3p5732v"))))
2770 (build-system gnu-build-system)
2771 (native-inputs
2772 `(("pkg-config" ,pkg-config)))
2773 (inputs
2774 `(("sdl2" ,sdl2)
2775 ("sdl2-image" ,sdl2-image)
2776 ("sdl2-mixer" ,sdl2-mixer)))
2777 (home-page "http://starfighter.nongnu.org/")
2778 (synopsis "2D scrolling shooter game")
2779 (description
2780 "In the year 2579, the intergalactic weapons corporation, WEAPCO, has
2781 dominated the galaxy. Guide Chris Bainfield and his friend Sid Wilson on
2782 their quest to liberate the galaxy from the clutches of WEAPCO. Along the
2783 way, you will encounter new foes, make new allies, and assist local rebels
2784 in strikes against the evil corporation.")
2785 ;; gfx and music are under CC-BY 3.0, CC-BY-SA 3.0, CC0 or Public Domain.
2786 (license (list license:gpl3+
2787 license:cc-by3.0
2788 license:cc-by-sa3.0
2789 license:cc0
2790 license:public-domain))))
2791
2792 (define-public chromium-bsu
2793 (package
2794 (name "chromium-bsu")
2795 (version "0.9.16.1")
2796 (source (origin
2797 (method url-fetch)
2798 (uri (string-append "mirror://sourceforge/" name
2799 "/Chromium B.S.U. source code/"
2800 name "-" version ".tar.gz"))
2801 (sha256
2802 (base32
2803 "0jk2w5b6s6nkzri585bbz16cif2fhqcnl5l1mq3rd98r9nil3hd1"))))
2804 (build-system gnu-build-system)
2805 (native-inputs `(("pkg-config" ,pkg-config)))
2806 (inputs `(("gettext" ,gettext-minimal)
2807 ("glu" ,glu)
2808 ("quesoglc" ,quesoglc)
2809 ("sdl-union" ,(sdl-union (list sdl sdl-image sdl-mixer)))))
2810 (home-page "http://chromium-bsu.sourceforge.net/")
2811 (synopsis "Fast-paced, arcade-style, top-scrolling space shooter")
2812 (description
2813 "In this game you are the captain of the cargo ship Chromium B.S.U. and
2814 are responsible for delivering supplies to the troops on the front line. Your
2815 ship has a small fleet of robotic fighters which you control from the relative
2816 safety of the Chromium vessel.")
2817 ;; Clarified Artistic License for everything but sound, which is covered
2818 ;; by the Expat License.
2819 (license (list license:clarified-artistic license:expat))))
2820
2821 (define-public tuxpaint
2822 (package
2823 (name "tuxpaint")
2824 (version "0.9.22") ;keep VER_DATE below in sync
2825 (source
2826 (origin
2827 (method url-fetch)
2828 (uri (string-append "mirror://sourceforge/tuxpaint/tuxpaint/"
2829 version "/tuxpaint-" version ".tar.gz"))
2830 (sha256
2831 (base32
2832 "1qrbrdck9yxpcg3si6jb9i11w8lw9h4hqad0pfaxgyiniqpr7gca"))
2833 (modules '((guix build utils)))
2834 (snippet
2835 '(begin
2836 ;; Remove win32 directory which contains binary dll's and the
2837 ;; deprecated visualc directory.
2838 (for-each delete-file-recursively '("win32" "visualc"))
2839 (substitute* "Makefile"
2840 ;; Do not rely on $(GPERF) being an absolute file name
2841 (("\\[ -x \\$\\(GPERF\\) \\]")
2842 "$(GPERF) --version >/dev/null 2>&1"))))
2843 (patches (search-patches "tuxpaint-stamps-path.patch"))))
2844 (build-system gnu-build-system)
2845 (native-inputs
2846 `(("gperf" ,gperf)
2847 ("pkg-config" ,pkg-config)))
2848 (inputs
2849 `(("cairo" ,cairo)
2850 ("fribidi" ,fribidi)
2851 ("gettext" ,gettext-minimal)
2852 ("libpng" ,libpng)
2853 ("librsvg" ,librsvg)
2854 ("libpaper" ,libpaper)
2855 ("netpbm" ,netpbm)
2856 ("sdl" ,(sdl-union (list sdl sdl-mixer sdl-ttf sdl-image)))))
2857 ;; TODO: Use system fonts rather than those in data/fonts
2858 (arguments
2859 `(#:make-flags `("VER_DATE=2014-08-23"
2860 "GPERF=gperf" "CC=gcc"
2861 "SDL_PCNAME=sdl SDL_image SDL_mixer SDL_ttf"
2862 ,(string-append "PREFIX=" %output)
2863 "GNOME_PREFIX=$(PREFIX)"
2864 "COMPLETIONDIR=$(PREFIX)/etc/bash_completion.d")
2865 #:parallel-build? #f ;fails on some systems
2866 #:tests? #f ;No tests
2867 #:phases (modify-phases %standard-phases
2868 (delete 'configure) ;no configure phase
2869 (add-after 'install 'fix-import
2870 (lambda* (#:key inputs outputs #:allow-other-keys)
2871 (let* ((out (assoc-ref outputs "out"))
2872 (net (assoc-ref inputs "netpbm"))
2873 (tpi (string-append out "/bin/tuxpaint-import")))
2874 (substitute* tpi
2875 ;; Point to installation prefix so that the default
2876 ;; configure file is found.
2877 (("/usr/local") out))
2878 ;; tuxpaint-import uses a bunch of programs from
2879 ;; netpbm, so make sure it knows where those are
2880 (wrap-program tpi
2881 `("PATH" ":" prefix
2882 (,(string-append net "/bin"))))))))))
2883 (native-search-paths
2884 (list (search-path-specification
2885 (variable "TUXPAINT_STAMPS_PATH")
2886 (files '("share/tuxpaint/stamps")))))
2887 (home-page "http://www.tuxpaint.org")
2888 (synopsis "Drawing software for children")
2889 (description
2890 "Tux Paint is a free drawing program designed for young children (kids
2891 ages 3 and up). It has a simple, easy-to-use interface; fun sound effects;
2892 and an encouraging cartoon mascot who helps guide children as they use the
2893 program. It provides a blank canvas and a variety of drawing tools to help
2894 your child be creative.")
2895 (license license:gpl2+)))
2896
2897 (define-public tuxpaint-stamps
2898 (package
2899 (name "tuxpaint-stamps")
2900 (version "2014.08.23")
2901 (source
2902 (origin
2903 (method url-fetch)
2904 (uri (string-append "mirror://sourceforge/tuxpaint/tuxpaint-stamps/"
2905 (string-map (λ (x) (if (eq? x #\.) #\- x)) version)
2906 "/tuxpaint-stamps-" version ".tar.gz"))
2907 (sha256
2908 (base32
2909 "0rhlwrjz44wp269v3rid4p8pi0i615pzifm1ym6va64gn1bms06q"))))
2910 (build-system trivial-build-system)
2911 (native-inputs
2912 `(("tar" ,tar)
2913 ("gzip" ,gzip)))
2914 (arguments
2915 `(#:modules ((guix build utils))
2916 #:builder (begin
2917 (use-modules (guix build utils))
2918 (setenv "PATH"
2919 (string-append
2920 (assoc-ref %build-inputs "tar") "/bin" ":"
2921 (assoc-ref %build-inputs "gzip") "/bin"))
2922 (system* "tar" "xvf" (assoc-ref %build-inputs "source"))
2923 (chdir (string-append ,name "-" ,version))
2924 (let ((dir (string-append %output "/share/tuxpaint/stamps")))
2925 (mkdir-p dir)
2926 (copy-recursively "stamps" dir)))))
2927 (home-page (package-home-page tuxpaint))
2928 (synopsis "Stamp images for Tux Paint")
2929 (description
2930 "This package contains a set of \"Rubber Stamp\" images which can be used
2931 with the \"Stamp\" tool within Tux Paint.")
2932 (license license:gpl2+)))
2933
2934 (define-public tuxpaint-config
2935 (package
2936 (name "tuxpaint-config")
2937 (version "0.0.13") ;keep VER_DATE below in sync
2938 (source
2939 (origin
2940 (method url-fetch)
2941 (uri (string-append "mirror://sourceforge/tuxpaint/tuxpaint-config/"
2942 version "/tuxpaint-config-" version ".tar.gz"))
2943 (sha256
2944 (base32
2945 "1z12s46mvy87qs3vgq9m0ki9pp21zqc52mmgphahpihw3s7haf6v"))))
2946 (build-system gnu-build-system)
2947 (native-inputs
2948 `(("gettext" ,gettext-minimal)))
2949 (inputs
2950 `(("fltk" ,fltk)
2951 ("libpaper" ,libpaper)
2952 ;; TODO: Should the following be propagated by fltk?
2953 ("libx11" ,libx11)
2954 ("libxft" ,libxft)
2955 ("mesa" ,mesa)))
2956 (arguments
2957 `(#:make-flags `("VER_DATE=2014-08-23"
2958 "CONFDIR=/etc/tuxpaint" ;don't write to store
2959 ,(string-append "PREFIX=" %output)
2960 "GNOME_PREFIX=$(PREFIX)")
2961 #:parallel-build? #f ;race conditions
2962 #:tests? #f ;no tests
2963 #:phases (modify-phases %standard-phases
2964 (delete 'configure) ;no configure phase
2965 (add-before 'install 'gzip-no-name
2966 (lambda* _
2967 (substitute* "Makefile"
2968 ;; tuxpaint-config compresses its own documentation;
2969 ;; make sure it uses flags for reproducibility.
2970 (("gzip") "gzip --no-name"))))
2971 (add-before 'install 'make-install-dirs
2972 (lambda* (#:key outputs #:allow-other-keys)
2973 (let ((out (assoc-ref outputs "out")))
2974 (mkdir-p (string-append out "/bin"))
2975 #t))))))
2976 (home-page (package-home-page tuxpaint))
2977 (synopsis "Configure Tux Paint")
2978 (description
2979 "Tux Paint Config is a graphical configuration editor for Tux Paint.")
2980 (license license:gpl2))) ;no "or later" present
2981
2982 (define-public supertux
2983 (package
2984 (name "supertux")
2985 (version "0.5.1")
2986 (source (origin
2987 (method url-fetch)
2988 (uri (string-append "https://github.com/SuperTux/supertux/"
2989 "releases/download/v" version "/SuperTux-v"
2990 version "-Source.tar.gz"))
2991 (sha256
2992 (base32
2993 "1i8avad7w7ikj870z519j383ldy29r6f956bs38cbr8wk513pp69"))))
2994 (arguments
2995 '(#:tests? #f
2996 #:configure-flags '("-DINSTALL_SUBDIR_BIN=bin"
2997 "-DENABLE_BOOST_STATIC_LIBS=OFF")))
2998 (build-system cmake-build-system)
2999 (inputs `(("sdl2" ,sdl2)
3000 ("sdl2-image" ,sdl2-image)
3001 ("sdl2-mixer" ,sdl2-mixer)
3002 ("openal" ,openal)
3003 ("mesa" ,mesa)
3004 ("glew" ,glew)
3005 ("libvorbis" ,libvorbis)
3006 ("libogg" ,libogg)
3007 ("physfs" ,physfs)
3008 ("curl" ,curl)
3009 ("boost" ,boost)))
3010 (native-inputs `(("pkg-config" ,pkg-config)))
3011 (synopsis "2D platformer game")
3012 (description "SuperTux is a free classic 2D jump'n run sidescroller game
3013 in a style similar to the original Super Mario games covered under
3014 the GNU GPL.")
3015 (home-page "https://supertuxproject.org/")
3016 (license license:gpl3+)))
3017
3018 (define-public tintin++
3019 (package
3020 (name "tintin++")
3021 (version "2.01.4")
3022 (source (origin
3023 (method url-fetch)
3024 (uri (string-append "mirror://sourceforge/tintin"
3025 "/TinTin++ Source Code/" version
3026 "/tintin" "-" version ".tar.gz"))
3027 (sha256
3028 (base32
3029 "1g7bh8xs1ml0iyraps3a3dzaycci922y7fk5j0wyr4ssyjzsy8nx"))))
3030 (inputs
3031 `(("gnutls" ,gnutls)
3032 ("pcre" ,pcre)
3033 ("readline" ,readline)
3034 ("zlib" ,zlib)))
3035 (arguments
3036 '(#:tests? #f ; no test suite
3037 #:phases
3038 (modify-phases %standard-phases
3039 ;; The source is in tt/src.
3040 (add-before 'configure 'chdir
3041 (lambda _
3042 (chdir "src")
3043 #t)))))
3044 (build-system gnu-build-system)
3045 (home-page "http://tintin.sourceforge.net/")
3046 (synopsis "MUD client")
3047 (description
3048 "TinTin++ is a MUD client which supports MCCP (Mud Client Compression Protocol),
3049 MMCP (Mud Master Chat Protocol), xterm 256 colors, most TELNET options used by MUDs,
3050 as well as those required to login via telnet on Linux / Mac OS X servers, and an
3051 auto mapper with a VT100 map display.")
3052 (license license:gpl2+)))
3053
3054 (define-public laby
3055 (package
3056 (name "laby")
3057 (version "0.6.4")
3058 (source
3059 (origin (method url-fetch)
3060 (uri (string-append
3061 "https://github.com/sgimenez/laby/archive/"
3062 name "-" version ".tar.gz"))
3063 (sha256
3064 (base32
3065 "0gyrfa95l1qka7gbjf7l6mk7mbfvph00l0c995ia272qdw7rjhyf"))
3066 (patches (search-patches "laby-make-install.patch"))))
3067 (build-system gnu-build-system)
3068 (inputs
3069 `(("lablgtk" ,lablgtk)
3070 ("ocaml" ,ocaml)
3071 ("ocaml-findlib" ,ocaml-findlib)))
3072 (arguments
3073 '(#:phases
3074 (modify-phases %standard-phases
3075 (delete 'configure)
3076 (add-before 'build 'setenv
3077 (lambda* (#:key inputs #:allow-other-keys)
3078 (let ((lablgtk (assoc-ref inputs "lablgtk")))
3079 (setenv "LD_LIBRARY_PATH"
3080 (string-append lablgtk "/lib/ocaml/stublibs"))))))
3081 #:tests? #f ; no 'check' target
3082 #:make-flags
3083 (list (string-append "PREFIX=" (assoc-ref %outputs "out")) "all")))
3084 (home-page "https://sgimenez.github.io/laby/")
3085 (synopsis "Programming game")
3086 (description "Learn programming, playing with ants and spider webs ;-)
3087 Your robot ant can be programmed in many languages: OCaml, Python, C, C++,
3088 Java, Ruby, Lua, JavaScript, Pascal, Perl, Scheme, Vala, Prolog. Experienced
3089 programmers may also add their own favorite language.")
3090 (license license:gpl3+)))
3091
3092 (define-public bambam
3093 (package
3094 (name "bambam")
3095 (version "0.5")
3096 (source
3097 (origin
3098 (method url-fetch)
3099 (uri (string-append "https://github.com/porridge/bambam/archive/"
3100 version ".tar.gz"))
3101 (file-name (string-append name "-" version ".tar.gz"))
3102 (sha256
3103 (base32
3104 "10w110mjdwbvddzihh9rganvvjr5jfiz8cs9n7w12zndwwcc3ria"))))
3105 (build-system python-build-system)
3106 (arguments
3107 `(#:python ,python-2
3108 #:tests? #f ; no tests
3109 #:phases
3110 (modify-phases %standard-phases
3111 (delete 'build)
3112 (add-before 'install 'patch-data-dir-location
3113 (lambda _
3114 (substitute* "bambam.py"
3115 (("'data'") "'../share/bambam/data'"))
3116 #t))
3117 (replace 'install
3118 (lambda* (#:key outputs #:allow-other-keys)
3119 (let* ((out (assoc-ref outputs "out"))
3120 (bin (string-append out "/bin"))
3121 (share (string-append out "/share")))
3122 (mkdir-p bin)
3123 (copy-file "bambam.py" (string-append bin "/bambam"))
3124 (install-file "bambam.6" (string-append share "/man/man6"))
3125 (copy-recursively "data" (string-append share "/bambam/data")))
3126 #t)))))
3127 (inputs
3128 `(("python-pygame" ,python-pygame)))
3129 (home-page "https://github.com/porridge/bambam")
3130 (synopsis "Keyboard mashing and doodling game for babies")
3131 (description "Bambam is a simple baby keyboard (and gamepad) masher
3132 application that locks the keyboard and mouse and instead displays bright
3133 colors, pictures, and sounds.")
3134 (license license:gpl3+)))
3135
3136 (define-public mrrescue
3137 (package
3138 (name "mrrescue")
3139 (version "1.02e")
3140 (source (origin
3141 (method url-fetch)
3142 (uri (string-append
3143 "https://github.com/SimonLarsen/mrrescue/releases/"
3144 "download/" version "/" name version ".love"))
3145 (file-name (string-append name "-" version ".love"))
3146 (sha256
3147 (base32
3148 "0jwzbwkgp1l5ia6c7s760gmdirbsncp6nfqp7vqdqsfb63la9gl2"))))
3149 (build-system trivial-build-system)
3150 (arguments
3151 '(#:modules ((guix build utils))
3152 #:builder
3153 (begin
3154 (use-modules (guix build utils))
3155 (let* ((out (assoc-ref %outputs "out"))
3156 (bindir (string-append out "/bin"))
3157 (prog (string-append bindir "/mrrescue"))
3158 (source (assoc-ref %build-inputs "source"))
3159 (bash (string-append (assoc-ref %build-inputs "bash")
3160 "/bin/bash"))
3161 (love (string-append (assoc-ref %build-inputs "love")
3162 "/bin/love")))
3163 (mkdir-p bindir)
3164 (with-output-to-file prog
3165 (lambda ()
3166 (format #t "#!~a~%" bash)
3167 (format #t "exec -a mrrescue \"~a\" \"~a\"~%" love source)))
3168 (chmod prog #o755)
3169 #t))))
3170 (inputs
3171 `(("bash" ,bash)
3172 ("love" ,love)))
3173 (home-page "http://tangramgames.dk/games/mrrescue")
3174 (synopsis "Arcade-style fire fighting game")
3175 (description
3176 "Mr. Rescue is an arcade styled 2d action game centered around evacuating
3177 civilians from burning buildings. The game features fast paced fire
3178 extinguishing action, intense boss battles, a catchy soundtrack and lots of
3179 throwing people around in pseudo-randomly generated buildings.")
3180 (license (list license:zlib ; for source code
3181 license:cc-by-sa3.0)))) ; for graphics and music assets
3182
3183 (define-public hyperrogue
3184 (package
3185 (name "hyperrogue")
3186 (version "10.0g")
3187 ;; When updating this package, be sure to update the "hyperrogue-data"
3188 ;; origin in native-inputs.
3189 (source (origin
3190 (method url-fetch)
3191 (uri (string-append
3192 "http://www.roguetemple.com/z/hyper/"
3193 name (string-join (string-split version #\.) "")
3194 "-src.tgz"))
3195 (sha256
3196 (base32
3197 "0f68pcnsgl406dhm91ckn3f364bar9m9i5njp9vrmvhvv9p2icy0"))))
3198 (build-system gnu-build-system)
3199 (arguments
3200 `(#:tests? #f ; no check target
3201 #:make-flags '("CXXFLAGS=-std=c++11")
3202 #:phases
3203 (modify-phases %standard-phases
3204 (add-after 'set-paths 'set-sdl-paths
3205 (lambda* (#:key inputs #:allow-other-keys)
3206 (setenv "CPATH"
3207 (string-append (assoc-ref inputs "sdl-union")
3208 "/include/SDL"))))
3209 ;; Fix font and music paths.
3210 (replace 'configure
3211 (lambda* (#:key inputs outputs #:allow-other-keys)
3212 (let* ((out (assoc-ref outputs "out"))
3213 (share-dir (string-append out "/share/hyperrogue"))
3214 (dejavu-dir (string-append
3215 (assoc-ref inputs "font-dejavu")
3216 "/share/fonts/truetype"))
3217 (dejavu-font "DejaVuSans-Bold.ttf")
3218 (music-file "hyperrogue-music.txt"))
3219 (substitute* "basegraph.cpp"
3220 ((dejavu-font)
3221 (string-append dejavu-dir "/" dejavu-font)))
3222 (substitute* "sound.cpp"
3223 (((string-append "\\./" music-file))
3224 (string-append share-dir "/" music-file))
3225 (("sounds/")
3226 (string-append share-dir "/sounds/")))
3227 (substitute* music-file
3228 (("\\*/")
3229 (string-append share-dir "/sounds/"))))
3230 #t))
3231 (replace 'install
3232 (lambda* (#:key inputs outputs #:allow-other-keys)
3233 (let* ((out (assoc-ref outputs "out"))
3234 (bin (string-append out "/bin"))
3235 (share-dir (string-append out "/share/hyperrogue")))
3236 (mkdir-p bin)
3237 (copy-file "hyper" (string-append bin "/hyperrogue"))
3238 (install-file "hyperrogue-music.txt" share-dir))
3239 #t))
3240 (add-after 'install 'install-data
3241 (lambda* (#:key inputs outputs #:allow-other-keys)
3242 (let* ((data (assoc-ref inputs "hyperrogue-data"))
3243 (out (assoc-ref outputs "out"))
3244 (sounds (string-append out "/share/hyperrogue/sounds"))
3245 (unzip (string-append (assoc-ref inputs "unzip") "/bin/unzip")))
3246 (and
3247 ;; Extract media license information into sounds directory.
3248 (zero?
3249 (system* unzip "-j" data
3250 (string-append
3251 "hyperrogue"
3252 (string-join (string-split ,version #\.) "")
3253 "/sounds/credits.txt") "-d" sounds))
3254 ;; Extract sounds and music into sounds directory.
3255 (zero?
3256 (system* "unzip" "-j" data
3257 (string-append
3258 "hyperrogue"
3259 (string-join (string-split ,version #\.) "")
3260 "/*.ogg") "-d" sounds)))))))))
3261 (native-inputs
3262 `(("hyperrogue-data"
3263 ,(origin
3264 (method url-fetch)
3265 (uri
3266 (string-append
3267 "http://www.roguetemple.com/z/hyper/" name
3268 (string-join (string-split version #\.) "")
3269 "-win.zip"))
3270 (sha256
3271 (base32
3272 "0bnp077qvlmxjlz1jjd6kpghlv9flxc19ac1xq3m3wyq1w9p3pab"))))
3273 ("unzip" ,unzip)))
3274 (inputs
3275 `(("font-dejavu" ,font-dejavu)
3276 ("glew" ,glew)
3277 ("libpng" ,libpng)
3278 ("sdl-union" ,(sdl-union (list sdl
3279 sdl-gfx
3280 sdl-mixer
3281 sdl-ttf)))))
3282 (home-page "http://www.roguetemple.com/z/hyper/")
3283 (synopsis "Non-euclidean graphical rogue-like game")
3284 (description
3285 "HyperRogue is a game in which the player collects treasures and fights
3286 monsters -- rogue-like but for the fact that it is played on the hyperbolic
3287 plane and not in euclidean space.
3288
3289 In HyperRogue, the player can move through different parts of the world, which
3290 are home to particular creatures and may be subject to their own rules of
3291 \"physics\".
3292
3293 While the game can use ASCII characters to display the the classical rogue
3294 symbols, it still needs graphics to render the non-euclidean world.")
3295 (license (list license:bsd-3 ; glew.c, mtrand.*
3296 license:cc-by-sa3.0 ; music
3297 license:cc-by-sa4.0 ; sounds
3298 license:cc0
3299 license:public-domain ; direntx.*, some sounds
3300 license:zlib ; savepng.*
3301 license:gpl2+)))) ; remaining files
3302
3303 (define-public kobodeluxe
3304 (package
3305 (name "kobodeluxe")
3306 (version "0.5.1")
3307 (source (origin
3308 (method url-fetch)
3309 (uri (string-append "http://olofson.net/kobodl/download/KoboDeluxe-"
3310 version ".tar.bz2"))
3311 (sha256
3312 (base32
3313 "0b2wvdpnmaibsy419c16dfwj5kvd3pccby2aaqvm964x74592yqg"))
3314 (patches (search-patches
3315 "kobodeluxe-const-charp-conversion.patch"
3316 "kobodeluxe-enemies-pipe-decl.patch"
3317 "kobodeluxe-graphics-window-signed-char.patch"
3318 "kobodeluxe-manpage-minus-not-hyphen.patch"
3319 "kobodeluxe-midicon-segmentation-fault.patch"
3320 "kobodeluxe-paths.patch"))))
3321 (build-system gnu-build-system)
3322 (arguments
3323 '(#:configure-flags
3324 (list (string-append "CPPFLAGS=-I"
3325 (assoc-ref %build-inputs "sdl-union")
3326 "/include/SDL"))))
3327 (inputs `(("sdl-union" ,(sdl-union (list sdl sdl-image)))))
3328 (synopsis "Shooter with space station destruction")
3329 (description
3330 "Kobo Deluxe is an enhanced version of Akira Higuchi's XKobo graphical game
3331 for Un*x systems with X11.")
3332 (home-page "http://olofson.net/kobodl/")
3333 (license license:gpl2+)))
3334
3335 (define-public freeciv
3336 (package
3337 (name "freeciv")
3338 (version "2.5.7")
3339 (source
3340 (origin
3341 (method url-fetch)
3342 (uri (list (string-append
3343 "http://files.freeciv.org/stable/freeciv-"
3344 version ".tar.bz2")
3345 (string-append
3346 "mirror://sourceforge/freeciv/Freeciv%20"
3347 (version-major+minor version) "/" version
3348 "/freeciv-" version ".tar.bz2")))
3349 (sha256
3350 (base32
3351 "1lmydnnqraa947l7gdz6xgm0bgks1ywsivp9h4v8jr3avcv6gqzz"))))
3352 (build-system gnu-build-system)
3353 (inputs
3354 `(("curl" ,curl)
3355 ("cyrus-sasl" ,cyrus-sasl)
3356 ("gtk+" ,gtk+)
3357 ("sdl-mixer" ,sdl-mixer)
3358 ("zlib" ,zlib)))
3359 (native-inputs
3360 `(("pkg-config" ,pkg-config)))
3361 (home-page "http://www.freeciv.org/")
3362 (synopsis "Turn based empire building strategy game")
3363 (description "Freeciv is a turn based empire building strategy game
3364 inspired by the history of human civilization. The game commences in
3365 prehistory and your mission is to lead your tribe from the Stone Age
3366 to the Space Age.")
3367 (license license:gpl2+)))
3368
3369 (define-public no-more-secrets
3370 (package
3371 (name "no-more-secrets")
3372 (version "0.3.3")
3373 (source
3374 (origin
3375 (method url-fetch)
3376 (uri (string-append "https://github.com/bartobri/no-more-secrets/"
3377 "archive/v" version ".tar.gz"))
3378 (file-name (string-append name "-" version ".tar.gz"))
3379 (sha256
3380 (base32
3381 "1kpx1rirc3i7fb4lymp0hx5rqr0s2ay4za261rw3bcy6d23l1kyg"))))
3382 (build-system gnu-build-system)
3383 (arguments
3384 `(#:tests? #f
3385 #:make-flags (list "CC=gcc" "all-ncurses"
3386 (string-append "prefix="
3387 (assoc-ref %outputs "out")))
3388 #:phases
3389 (modify-phases %standard-phases
3390 (delete 'configure))))
3391 (inputs
3392 `(("ncurses" ,ncurses)))
3393 (home-page "https://github.com/bartobri/no-more-secrets")
3394 (synopsis "Recreation of data decryption effect in \"Sneakers\"")
3395 (description
3396 "@code{No More Secrets} provides a command line tool called \"nms\"
3397 that recreates the famous data decryption effect seen on screen in the 1992
3398 movie \"Sneakers\".
3399
3400 This command works on piped data. Pipe any ASCII or UTF-8 text to nms, and
3401 it will apply the hollywood effect, initially showing encrypted data, then
3402 starting a decryption sequence to reveal the original plaintext characters.")
3403 (license license:expat)))
3404
3405 (define-public megaglest-data
3406 (package
3407 (name "megaglest-data")
3408 (version "3.13.0")
3409 (source
3410 (origin
3411 (method url-fetch)
3412 (uri (string-append
3413 "https://github.com/MegaGlest/megaglest-data"
3414 "/releases/download/" version "/megaglest-data-"
3415 version ".tar.xz"))
3416 (sha256
3417 (base32
3418 "0ipgza33z89fw3si32iafm981f3fvm0zldvbxj29whghd2k3rpj3"))))
3419 (build-system cmake-build-system)
3420 (arguments
3421 `(#:tests? #f))
3422 (home-page "https://megaglest.org/")
3423 (synopsis "Data files for MegaGlest")
3424 (description "This package contains the data files required for MegaGlest.")
3425 (license license:cc-by-sa3.0)))
3426
3427 (define-public megaglest
3428 (package
3429 (name "megaglest")
3430 (version "3.13.0")
3431 (source
3432 (origin
3433 (method url-fetch)
3434 (uri (string-append
3435 "https://github.com/MegaGlest/megaglest-source"
3436 "/releases/download/" version "/megaglest-source-"
3437 version ".tar.xz"))
3438 (sha256
3439 (base32
3440 "1ffck3ii1wp5k3nn5p0ga06jgp7pzk4zw0xln3xim2w7qrxzdzh9"))))
3441 (build-system cmake-build-system)
3442 (inputs
3443 `(("curl" ,curl)
3444 ("fontconfig" ,fontconfig)
3445 ("ftgl" ,ftgl)
3446 ("glew" ,glew)
3447 ("libjpeg-turbo" ,libjpeg-turbo)
3448 ("megaglest-data" ,megaglest-data)
3449 ("mesa" ,mesa)
3450 ("miniupnpc" ,miniupnpc)
3451 ("openal" ,openal)
3452 ("libircclient" ,libircclient)
3453 ("libpng" ,libpng)
3454 ("libvorbis" ,libvorbis)
3455 ("lua" ,lua)
3456 ("sdl2" ,sdl2)
3457 ("wxwidgets" ,wxwidgets)))
3458 (native-inputs
3459 `(("cppunit" ,cppunit)
3460 ("pkg-config" ,pkg-config)))
3461 (arguments
3462 `(#:configure-flags
3463 (list (string-append "-DCUSTOM_DATA_INSTALL_PATH="
3464 (assoc-ref %build-inputs "megaglest-data")
3465 "/share/megaglest")
3466 "-DBUILD_MEGAGLEST_TESTS=ON")
3467 #:phases
3468 (modify-phases %standard-phases
3469 (add-after 'unpack 'fix-ini-search-path
3470 (lambda* (#:key outputs #:allow-other-keys)
3471 (substitute* "source/glest_game/global/config.cpp"
3472 (("/usr/share/megaglest/")
3473 (string-append (assoc-ref outputs "out")
3474 "/share/megaglest/"))))))
3475 #:test-target "megaglest_tests"))
3476 (home-page "https://megaglest.org/")
3477 (synopsis "3D real-time strategy (RTS) game")
3478 (description "MegaGlest is a cross-platform 3D real-time strategy (RTS)
3479 game, where you control the armies of one of seven different factions: Tech,
3480 Magic, Egypt, Indians, Norsemen, Persian or Romans.")
3481 (license license:gpl2+)))
3482
3483 (define-public freegish
3484 (let ((commit "8795cd7adc95957883f2d3465eb9036a774667a7")
3485 (revision "1"))
3486 (package
3487 (name "freegish")
3488 (version (string-append "0-" revision "." (string-take commit 9)))
3489 (source (origin
3490 (method git-fetch)
3491 (uri (git-reference
3492 (url "https://github.com/freegish/freegish.git")
3493 (commit commit)))
3494 (file-name (git-file-name name version))
3495 (sha256
3496 (base32
3497 "1p1zf5qqagmcpi1db2bs02cnalpy3qiymp6yzan7k1bhmv859gsx"))
3498 (modules '((guix build utils)))
3499 ;; The audio files in the "music" directory are licensed under
3500 ;; CC-BY-NC, so we delete them.
3501 (snippet
3502 '(begin
3503 (delete-file-recursively "music")
3504 #t))))
3505 (build-system cmake-build-system)
3506 (arguments
3507 `(#:tests? #f ; no tests included
3508 #:configure-flags
3509 (list "-DCMAKE_INSTALL_FHS=ON")
3510 #:phases
3511 (modify-phases %standard-phases
3512 (add-after 'unpack 'set-DATAPATH
3513 (lambda* (#:key outputs #:allow-other-keys)
3514 (substitute* "CMakeLists.txt"
3515 (("^option\\(INSTALL_FHS" line)
3516 (string-append "add_definitions(-DDATAPATH=\""
3517 (assoc-ref outputs "out") "/share/freegish\")\n"
3518 line)))
3519 #t)))))
3520 (inputs
3521 `(("sdl-union" ,(sdl-union (list sdl sdl-mixer)))
3522 ("openal" ,openal)
3523 ("libvorbis" ,libvorbis)
3524 ("libogg" ,libogg)
3525 ("mesa" ,mesa)
3526 ("libpng" ,libpng)
3527 ("zlib" ,zlib)))
3528 (home-page "https://github.com/freegish/freegish")
3529 (synopsis "Side-scrolling physics platformer with a ball of tar")
3530 (description "In FreeGish you control Gish, a ball of tar who lives
3531 happily with his girlfriend Brea, until one day a mysterious dark creature
3532 emerges from a sewer hole and pulls her below ground.")
3533 ;; The textures are available under the Expat license. All other assets
3534 ;; (including levels) are covered under CC-BY-SA or public domain. The
3535 ;; source code is under GPLv2+.
3536 (license (list license:gpl2+
3537 license:expat
3538 license:public-domain
3539 license:cc-by-sa3.0)))))
3540
3541 (define-public cdogs-sdl
3542 (package
3543 (name "cdogs-sdl")
3544 (version "0.6.6")
3545 (source (origin
3546 (method url-fetch)
3547 (uri (string-append "https://github.com/cxong/cdogs-sdl/"
3548 "archive/" version ".tar.gz"))
3549 (file-name (string-append name "-" version ".tar.gz"))
3550 (sha256
3551 (base32
3552 "08gbx6vqqir48xs6qdfa4kv70gj4j96wzs90pg7qldfasxz34ljm"))))
3553 (build-system cmake-build-system)
3554 (arguments
3555 `(#:configure-flags
3556 (list (string-append "-DCDOGS_DATA_DIR="
3557 (assoc-ref %outputs "out")
3558 "/share/cdogs-sdl/"))))
3559 (inputs
3560 `(("mesa" ,mesa)
3561 ("sdl2" ,sdl2)
3562 ("sdl2-image" ,sdl2-image)
3563 ("sdl2-mixer" ,sdl2-mixer)))
3564 (home-page "https://cxong.github.io/cdogs-sdl/")
3565 (synopsis "Classic overhead run-and-gun game")
3566 (description "C-Dogs SDL is a classic overhead run-and-gun game,
3567 supporting up to 4 players in co-op and deathmatch modes. Customize your
3568 player, choose from many weapons, and blast, slide and slash your way through
3569 over 100 user-created campaigns.")
3570 ;; GPLv2+ for code (includes files under BSD-2 and BSD-3),
3571 ;; CC0/CC-BY/CC-BY-SA for assets.
3572 (license (list license:gpl2+
3573 license:bsd-2
3574 license:bsd-3
3575 license:cc0
3576 license:cc-by3.0
3577 license:cc-by-sa3.0))))
3578
3579 (define-public kiki
3580 (package
3581 (name "kiki")
3582 (version "1.0.2")
3583 (source (origin
3584 (method url-fetch)
3585 (uri (string-append "mirror://sourceforge/kiki/kiki-src/"
3586 version "/kiki-" version "-src.tgz"))
3587 (sha256
3588 (base32
3589 "0ihjdsxbn8z3cz0gpcprafiipcqaiskgdnh1rhmw4qff8dszalbn"))
3590 (modules '((guix build utils)))
3591 (snippet
3592 '(begin
3593 (for-each delete-file (find-files "." "\\.dll$"))
3594 #t))
3595 (patches
3596 (search-patches "kiki-level-selection-crash.patch"
3597 "kiki-makefile.patch"
3598 "kiki-missing-includes.patch"
3599 "kiki-portability-64bit.patch"))))
3600 (build-system gnu-build-system)
3601 (arguments
3602 `(#:tests? #f ; there are no tests
3603 #:make-flags '("CXX=g++")
3604 #:phases
3605 (modify-phases %standard-phases
3606 (replace 'configure
3607 (lambda* (#:key inputs outputs #:allow-other-keys)
3608 (setenv "CPLUS_INCLUDE_PATH"
3609 (string-append (assoc-ref inputs "sdl-union")
3610 "/include/SDL:"
3611 (assoc-ref inputs "python")
3612 "/include/python2.7:"
3613 (getenv "CPLUS_INCLUDE_PATH")))
3614 (substitute* "src/main/main.cpp"
3615 (("#include <SDL.h>" line)
3616 (string-append line "
3617 #define K_INCLUDE_GLUT
3618 #include \"KIncludeTools.h\""))
3619 (("// initialize SDL" line)
3620 (string-append "glutInit(&argc,argv);\n" line)))
3621 (substitute* "src/main/KikiController.cpp"
3622 (("getenv\\(\"KIKI_HOME\"\\)")
3623 (string-append "\"" (assoc-ref outputs "out") "/share/kiki/\"")))
3624 (substitute* "linux/Makefile"
3625 (("CXXOPTS =" line)
3626 (string-append line " -fpermissive"))
3627 (("PYTHON_VERSION=.*") "PYTHON_VERSION=2.7")
3628 (("PYTHONHOME =.*")
3629 (string-append "PYTHONHOME = "
3630 (assoc-ref inputs "python")
3631 "/lib/python2.7/"))
3632 (("\\$\\(GLLIBS\\)" line)
3633 (string-append line " -lm -lpython2.7")))
3634 (substitute* "src/main/KikiPythonWidget.h"
3635 (("#define __KikiPythonWidget" line)
3636 (string-append line "\n#include \"KikiPython.h\"")))
3637 #t))
3638 (add-before 'build 'build-kodilib
3639 (lambda* (#:key make-flags #:allow-other-keys)
3640 (with-directory-excursion "kodilib/linux"
3641 (zero? (apply system* "make" make-flags)))))
3642 (add-after 'build-kodilib 'chdir
3643 (lambda _ (chdir "linux") #t))
3644 (replace 'install
3645 (lambda* (#:key outputs #:allow-other-keys)
3646 (let* ((out (assoc-ref outputs "out"))
3647 (bin (string-append out "/bin"))
3648 (share (string-append out "/share/kiki")))
3649 (mkdir-p bin)
3650 (mkdir-p share)
3651 (install-file "kiki" bin)
3652 (copy-recursively "../py" (string-append share "/py"))
3653 (copy-recursively "../sound" (string-append share "/sound"))
3654 #t))))))
3655 (inputs
3656 `(("glu" ,glu)
3657 ;; Kiki builds fine with freeglut 3.0.0 but segfaults on start.
3658 ("freeglut" ,freeglut-2.8)
3659 ("sdl-union" ,(sdl-union (list sdl
3660 sdl-mixer
3661 sdl-image)))
3662 ("python" ,python-2)))
3663 (native-inputs
3664 `(("swig" ,swig)))
3665 (home-page "http://kiki.sourceforge.net/")
3666 (synopsis "3D puzzle game")
3667 (description "Kiki the nano bot is a 3D puzzle game. It is basically a
3668 mixture of the games Sokoban and Kula-World. Your task is to help Kiki, a
3669 small robot living in the nano world, repair its maker.")
3670 ;; See <http://metadata.ftp-master.debian.org/changelogs/main/k/
3671 ;; kiki-the-nano-bot/kiki-the-nano-bot_1.0.2+dfsg1-4_copyright>
3672 ;; for a statement from the author.
3673 (license license:public-domain)))
3674
3675 (define-public teeworlds
3676 (package
3677 (name "teeworlds")
3678 (version "0.6.4")
3679 (source (origin
3680 (method url-fetch)
3681 (uri (string-append "https://github.com/teeworlds/teeworlds/"
3682 "archive/" version "-release.tar.gz"))
3683 (file-name (string-append name "-" version ".tar.gz"))
3684 (sha256
3685 (base32
3686 "1mqhp6xjl75l49050cid36wxyjn1qr0vjx1c709dfg1lkvmgs6l3"))
3687 (modules '((guix build utils)))
3688 (snippet
3689 '(begin
3690 (for-each delete-file-recursively
3691 '("src/engine/external/wavpack/"
3692 "src/engine/external/zlib/"))
3693 #t))
3694 (patches
3695 (search-patches "teeworlds-use-latest-wavpack.patch"))))
3696 (build-system gnu-build-system)
3697 (arguments
3698 `(#:tests? #f ; no tests included
3699 #:phases
3700 (modify-phases %standard-phases
3701 (replace 'configure
3702 (lambda* (#:key outputs #:allow-other-keys)
3703 ;; Embed path to assets.
3704 (substitute* "src/engine/shared/storage.cpp"
3705 (("#define DATA_DIR.*")
3706 (string-append "#define DATA_DIR \""
3707 (assoc-ref outputs "out")
3708 "/share/teeworlds/data"
3709 "\"")))
3710
3711 ;; Bam expects all files to have a recent time stamp.
3712 (for-each (lambda (file)
3713 (utime file 1 1))
3714 (find-files "."))
3715
3716 ;; Do not use bundled libraries.
3717 (substitute* "bam.lua"
3718 (("if config.zlib.value == 1 then")
3719 "if true then")
3720 (("wavpack = .*")
3721 "wavpack = {}
3722 settings.link.libs:Add(\"wavpack\")\n"))
3723 (substitute* "src/engine/client/sound.cpp"
3724 (("#include <engine/external/wavpack/wavpack.h>")
3725 "#include <wavpack/wavpack.h>"))
3726 #t))
3727 (replace 'build
3728 (lambda _
3729 (zero? (system* "bam" "-a" "-v" "release"))))
3730 (replace 'install
3731 (lambda* (#:key outputs #:allow-other-keys)
3732 (let* ((out (assoc-ref outputs "out"))
3733 (bin (string-append out "/bin"))
3734 (data (string-append out "/share/teeworlds/data")))
3735 (mkdir-p bin)
3736 (mkdir-p data)
3737 (for-each (lambda (file)
3738 (install-file file bin))
3739 '("teeworlds" "teeworlds_srv"))
3740 (copy-recursively "data" data)
3741 #t))))))
3742 ;; FIXME: teeworlds bundles the sources of "pnglite", a two-file PNG
3743 ;; library without a build system.
3744 (inputs
3745 `(("freetype" ,freetype)
3746 ("glu" ,glu)
3747 ("mesa" ,mesa)
3748 ("sdl-union" ,(sdl-union (list sdl
3749 sdl-mixer
3750 sdl-image)))
3751 ("wavpack" ,wavpack)
3752 ("zlib" ,zlib)))
3753 (native-inputs
3754 `(("bam" ,bam)
3755 ("python" ,python-2)))
3756 (home-page "https://www.teeworlds.com")
3757 (synopsis "2D retro multiplayer shooter game")
3758 (description "Teeworlds is an online multiplayer game. Battle with up to
3759 16 players in a variety of game modes, including Team Deathmatch and Capture
3760 The Flag. You can even design your own maps!")
3761 (license license:bsd-3)))
3762
3763 (define-public enigma
3764 (package
3765 (name "enigma")
3766 (version "1.21")
3767 (source (origin
3768 (method url-fetch)
3769 (uri (string-append "mirror://sourceforge/enigma-game/"
3770 "Release%20" version "/enigma-"
3771 version ".tar.gz"))
3772 (sha256
3773 (base32
3774 "00ffh9pypj1948pg3q9sjp1nmiabh52p5c8wpg9n1dcfgl3cywnq"))))
3775 (build-system gnu-build-system)
3776 (arguments
3777 `(#:configure-flags
3778 (list "--with-system-enet")
3779 #:phases
3780 (modify-phases %standard-phases
3781 (add-after 'unpack 'find-sdl
3782 (lambda _
3783 (substitute* "configure"
3784 (("SDL_ttf.h") "SDL/SDL_ttf.h"))
3785 (substitute* '("tools/ttf2bmf.cc"
3786 "lib-src/enigma-core/ecl_font.cc"
3787 "lib-src/enigma-core/ecl_video.cc"
3788 "lib-src/enigma-core/ecl_buffer.hh"
3789 "src/SoundEngine.cc"
3790 "src/SoundEngine.hh"
3791 "src/MusicManager.cc"
3792 "src/MusicManager.hh"
3793 "src/d_models.cc"
3794 "src/main.cc"
3795 "src/network.cc")
3796 (("#include \"SDL_(image|ttf|mixer|types|syswm|mutex).h\"" line header)
3797 (string-append "#include \"SDL/SDL_" header ".h\"")))
3798 (substitute* "src/main.cc"
3799 (("#include <SDL_(image|ttf|mixer).h>" line header)
3800 (string-append "#include \"SDL/SDL_" header ".h\"")))
3801 #t)))))
3802 (inputs
3803 `(("xerces-c" ,xerces-c)
3804 ("sdl-union" ,(sdl-union (list sdl sdl-image sdl-mixer sdl-ttf)))
3805 ("curl" ,curl)
3806 ("enet" ,enet)))
3807 (native-inputs
3808 `(("pkg-config" ,pkg-config)
3809 ("imagemagick" ,imagemagick)))
3810 (home-page "https://www.nongnu.org/enigma")
3811 (synopsis "Puzzle game with a dexterity component")
3812 (description "Enigma is a puzzle game with 550 unique levels. The object
3813 of the game is to find and uncover pairs of identically colored ‘Oxyd’ stones.
3814 Simple? Yes. Easy? Certainly not! Hidden traps, vast mazes, laser beams,
3815 and most of all, countless hairy puzzles usually block your direct way to the
3816 Oxyd stones. Enigma’s game objects (and there are hundreds of them, lest you
3817 get bored) interact in many unexpected ways, and since many of them follow the
3818 laws of physics (Enigma’s special laws of physics, that is), controlling them
3819 with the mouse isn’t always trivial.")
3820 (license license:gpl2+)))
3821
3822 (define-public fillets-ng
3823 (package
3824 (name "fillets-ng")
3825 (version "1.0.1")
3826 (source (origin
3827 (method url-fetch)
3828 (uri (string-append "mirror://sourceforge/fillets/"
3829 "Fish%20Fillets%20-%20Next%20Generation/"
3830 version "/fillets-ng-" version ".tar.gz"))
3831 (sha256
3832 (base32
3833 "1nljp75aqqb35qq3x7abhs2kp69vjcj0h1vxcpdyn2yn2nalv6ij"))))
3834 (build-system gnu-build-system)
3835 (arguments
3836 `(#:configure-flags
3837 (list (string-append "--with-lua="
3838 (assoc-ref %build-inputs "lua")))
3839 #:make-flags
3840 (list (string-append "CFLAGS=-I"
3841 (assoc-ref %build-inputs "sdl-union")
3842 "/include/SDL")
3843 (string-append "CXXFLAGS=-I"
3844 (assoc-ref %build-inputs "sdl-union")
3845 "/include/SDL"))
3846 #:phases
3847 (modify-phases %standard-phases
3848 ;; Lua 5.1 does not provide it.
3849 (add-after 'unpack 'do-not-link-with-lualib
3850 (lambda _
3851 (substitute* "configure"
3852 (("-llualib") ""))
3853 #t))
3854 (add-after 'install 'install-data
3855 (lambda* (#:key inputs outputs #:allow-other-keys)
3856 (let ((data (string-append (assoc-ref outputs "out")
3857 "/share/games/fillets-ng")))
3858 (mkdir-p data)
3859 (zero? (system* "tar" "-xvf"
3860 (assoc-ref inputs "fillets-ng-data")
3861 "--strip-components=1"
3862 "-C" data))))))))
3863 (inputs
3864 `(("sdl-union" ,(sdl-union (list sdl
3865 sdl-mixer
3866 sdl-image
3867 sdl-ttf)))
3868 ("fribidi" ,fribidi)
3869 ("libx11" ,libx11)
3870 ("lua" ,lua-5.1)))
3871 (native-inputs
3872 `(("pkg-config" ,pkg-config)
3873 ("fillets-ng-data"
3874 ,(origin
3875 (method url-fetch)
3876 (uri (string-append "mirror://sourceforge/fillets/"
3877 "Fish%20Fillets%20-%20Next%20Generation/"
3878 version "/fillets-ng-data-" version ".tar.gz"))
3879 (sha256
3880 (base32
3881 "169p0yqh2gxvhdilvjc2ld8aap7lv2nhkhkg4i1hlmgc6pxpkjgh"))))))
3882 (home-page "http://fillets.sourceforge.net/")
3883 (synopsis "Puzzle game")
3884 (description "Fish Fillets NG is strictly a puzzle game. The goal in
3885 every of the seventy levels is always the same: find a safe way out. The fish
3886 utter witty remarks about their surroundings, the various inhabitants of their
3887 underwater realm quarrel among themselves or comment on the efforts of your
3888 fish. The whole game is accompanied by quiet, comforting music.")
3889 (license license:gpl2+)))
3890
3891 (define-public crawl
3892 (package
3893 (name "crawl")
3894 (version "0.21.0")
3895 (source
3896 (origin
3897 (method url-fetch)
3898 (uri (list
3899 ;; Older releases get moved into a versioned directory
3900 (string-append "http://crawl.develz.org/release/"
3901 (version-major+minor version) "/stone_soup-"
3902 version "-nodeps.tar.xz")
3903 ;; Only the latest release is in this directory
3904 (string-append "http://crawl.develz.org/release/stone_soup-"
3905 version "-nodeps.tar.xz")))
3906 (sha256
3907 (base32
3908 "0mmnkch8s9l7dh136yjvcyjr0vmyzv7z370rlcyir91qz6gg82n1"))
3909 (patches (search-patches "crawl-upgrade-saves.patch"))))
3910 (build-system gnu-build-system)
3911 (inputs
3912 `(("lua51" ,lua-5.1)
3913 ("ncurses" ,ncurses)
3914 ("sqlite" ,sqlite)
3915 ("zlib" ,zlib)))
3916 (native-inputs
3917 `(("bison" ,bison)
3918 ("flex" ,flex)
3919 ("perl" ,perl)
3920 ("pkg-config" ,pkg-config)))
3921 (arguments
3922 '(#:make-flags
3923 (let* ((sqlite (assoc-ref %build-inputs "sqlite"))
3924 (out (assoc-ref %outputs "out")))
3925 (list (string-append "SQLITE_INCLUDE_DIR=" sqlite "/include")
3926 (string-append "prefix=" out)
3927 "SAVEDIR=~/.crawl"
3928 ;; don't build any bundled dependencies
3929 "BUILD_LUA="
3930 "BUILD_SQLITE="
3931 "BUILD_ZLIB="
3932 "-Csource"))
3933 #:phases
3934 (modify-phases %standard-phases
3935 (delete 'configure)
3936 (delete 'check)
3937 ;; Test cases require the source to be rebuild with the -DDEBUG define.
3938 ;; Do 'check before 'build to avoid a 3rd build on make install.
3939 (add-before 'build 'check
3940 (lambda* (#:key inputs outputs make-flags #:allow-other-keys)
3941 (setenv "HOME" (getcwd))
3942 ;; Fake a terminal for the test cases.
3943 (setenv "TERM" "xterm-256color")
3944 (zero? (apply system* "make" "debug" "test"
3945 (format #f "-j~d" (parallel-job-count))
3946 ;; Force command line build for test cases.
3947 (append make-flags '("GAME=crawl" "TILES=")))))))))
3948 (synopsis "Roguelike dungeon crawler game")
3949 (description "Dungeon Crawl Stone Soup is a roguelike adventure through
3950 dungeons filled with dangerous monsters in a quest to find the mystifyingly
3951 fabulous Orb of Zot.")
3952 (home-page "https://crawl.develz.org")
3953 (license (list license:gpl2+
3954 license:bsd-2
3955 license:bsd-3
3956 license:cc0
3957 license:expat
3958 license:zlib
3959 license:asl2.0))))
3960
3961 ;; The linter here claims that patch file names should start with the package
3962 ;; name. But, in this case, the patches are inherited from crawl with the
3963 ;; "crawl-" prefix instead of "crawl-tiles-".
3964 (define-public crawl-tiles
3965 (package
3966 (inherit crawl)
3967 (name "crawl-tiles")
3968 (arguments
3969 (substitute-keyword-arguments
3970 (package-arguments crawl)
3971 ((#:make-flags flags)
3972 `(let ((dejavu (assoc-ref %build-inputs "font-dejavu")))
3973 (cons*
3974 (string-append "PROPORTIONAL_FONT=" dejavu
3975 "/share/fonts/truetype/DejaVuSans.ttf")
3976 (string-append "MONOSPACED_FONT=" dejavu
3977 "/share/fonts/truetype/DejaVuSansMono.ttf")
3978 "TILES=y"
3979 ;; Rename the executable to allow parallel installation with crawl.
3980 "GAME=crawl-tiles"
3981 ,flags)))))
3982 (inputs
3983 `(,@(package-inputs crawl)
3984 ("font-dejavu" ,font-dejavu)
3985 ("freetype6" ,freetype)
3986 ("glu" ,glu)
3987 ("libpng" ,libpng)
3988 ("sdl2" ,sdl2)
3989 ("sdl2-image" ,sdl2-image)
3990 ("sdl2-mixer" ,sdl2-mixer)))
3991 (native-inputs
3992 `(,@(package-native-inputs crawl)
3993 ("pngcrush" ,pngcrush)
3994 ("which" ,which)))
3995 (synopsis "Graphical roguelike dungeon crawler game")))
3996
3997 (define-public lugaru
3998 (package
3999 (name "lugaru")
4000 (version "1.2")
4001 (source (origin
4002 (method url-fetch)
4003 (uri (string-append "https://bitbucket.org/osslugaru/lugaru/downloads/"
4004 name "-" version ".tar.xz"))
4005 (sha256
4006 (base32
4007 "15zgcshy22q51rm72zi6y9z7qlgnz5iw3gczjdlir4bqmxy4gspk"))))
4008 (build-system cmake-build-system)
4009 (arguments
4010 `(#:configure-flags
4011 (list "-DSYSTEM_INSTALL=ON")
4012 ;; no test target
4013 #:tests? #f))
4014 (native-inputs
4015 `(("pkg-config" ,pkg-config)))
4016 (inputs
4017 `(("sdl2" ,sdl2)
4018 ("glu" ,glu)
4019 ("libjpeg" ,libjpeg-turbo)
4020 ("libpng" ,libpng)
4021 ("openal" ,openal)
4022 ("vorbis" ,libvorbis)
4023 ("zlib" ,zlib)))
4024 (home-page "https://osslugaru.gitlab.io")
4025 (synopsis "Cross-platform third-person action game")
4026 (description "Lugaru is a third-person action game. The main character,
4027 Turner, is an anthropomorphic rebel bunny rabbit with impressive combat skills.
4028 In his quest to find those responsible for slaughtering his village, he uncovers
4029 a far-reaching conspiracy involving the corrupt leaders of the rabbit republic
4030 and the starving wolves from a nearby den. Turner takes it upon himself to
4031 fight against their plot and save his fellow rabbits from slavery.")
4032 (license (list license:gpl2+ ; code
4033 ;; assets:
4034 license:cc-by-sa3.0
4035 license:cc-by-sa4.0))))
4036
4037 (define-public 0ad-data
4038 (package
4039 (name "0ad-data")
4040 (version "0.0.22-alpha")
4041 (source
4042 (origin
4043 (method url-fetch)
4044 (uri (string-append "http://releases.wildfiregames.com/0ad-"
4045 version "-unix-data.tar.xz"))
4046 (file-name (string-append name "-" version ".tar.xz"))
4047 (sha256
4048 (base32
4049 "0vknk9ay9h2p34r7mym2g066f3s3c5d5vmap0ckcs5b86h5cscjc"))
4050 (modules '((guix build utils)))
4051 (snippet
4052 #~(begin
4053 (for-each
4054 (lambda (name)
4055 (let* ((dir (string-append "binaries/data/mods/" name))
4056 (file (string-append dir "/" name ".zip"))
4057 (unzip #$(file-append unzip "/bin/unzip")))
4058 (system* unzip "-d" dir file)
4059 (delete-file file)))
4060 '("mod" "public"))
4061 #t))))
4062 (build-system trivial-build-system)
4063 (native-inputs `(("tar" ,tar)
4064 ("xz" ,xz)))
4065 (arguments
4066 `(#:modules ((guix build utils))
4067 #:builder
4068 (begin
4069 (use-modules (guix build utils))
4070 (let ((out (assoc-ref %outputs "out"))
4071 (source (assoc-ref %build-inputs "source"))
4072 (tar (string-append (assoc-ref %build-inputs "tar") "/bin/tar"))
4073 (xz-path (string-append (assoc-ref %build-inputs "xz") "/bin")))
4074 (setenv "PATH" xz-path)
4075 (mkdir out)
4076 (zero? (system* tar "xvf" source "-C" out "--strip=3"))))))
4077 (synopsis "Data files for 0ad")
4078 (description "0ad-data provides the data files required by the game 0ad.")
4079 (home-page "https://play0ad.com")
4080 (license (list (license:fsdg-compatible
4081 "http://tavmjong.free.fr/FONTS/ArevCopyright.txt"
4082 (license:license-comment
4083 (package-license font-bitstream-vera)))
4084 (package-license font-bitstream-vera)
4085 license:cc-by-sa3.0
4086 license:expat
4087 license:gfl1.0
4088 license:gpl2+
4089 license:gpl3+))))
4090
4091 (define-public 0ad
4092 (package
4093 (name "0ad")
4094 (version "0.0.22-alpha")
4095 (source
4096 (origin
4097 (method url-fetch)
4098 (uri (string-append "http://releases.wildfiregames.com/0ad-"
4099 version "-unix-build.tar.xz"))
4100 (file-name (string-append name "-" version ".tar.xz"))
4101 (sha256
4102 (base32
4103 "1cgmr4g5g9wv36v7ylbrvqhsjwgcsdgbqwc8zlqmnayk9zgkdpgx"))
4104 ;; A snippet here would cause a build failure because of timestamps
4105 ;; reset. See https://bugs.gnu.org/26734.
4106 ))
4107 (inputs
4108 `(("0ad-data" ,0ad-data)
4109 ("curl" ,curl)
4110 ("enet" ,enet)
4111 ("gloox" ,gloox)
4112 ("icu4c" ,icu4c)
4113 ("libpng" ,libpng)
4114 ("libvorbis" ,libvorbis)
4115 ("libxcursor" ,libxcursor)
4116 ("libxml2" ,libxml2)
4117 ("miniupnpc" ,miniupnpc)
4118 ("mozjs-38" ,mozjs-38)
4119 ("openal" ,openal)
4120 ("sdl2" ,sdl2)
4121 ("wxwidgets" ,wxwidgets)
4122 ("zlib" ,zlib)))
4123 (native-inputs
4124 `(("boost" ,boost)
4125 ("cmake" ,cmake)
4126 ("mesa" ,mesa)
4127 ("pkg-config" ,pkg-config)
4128 ("python-2" ,python-2)))
4129 (build-system gnu-build-system)
4130 (arguments
4131 `(#:make-flags '("config=release" "verbose=1" "-C" "build/workspaces/gcc")
4132 #:phases
4133 (modify-phases %standard-phases
4134 (add-after 'unpack 'delete-bundles
4135 (lambda _
4136 (delete-file-recursively "libraries/source/spidermonkey")
4137 #t))
4138 (add-after 'unpack 'fix-x11-includes
4139 (lambda _
4140 (substitute* "source/lib/sysdep/os/unix/x/x.cpp"
4141 (("<Xlib.h>") "<X11/Xlib.h>"))
4142 (substitute* "source/lib/sysdep/os/unix/x/x.cpp"
4143 (("<Xatom.h>") "<X11/Xatom.h>"))
4144 (substitute* "source/lib/sysdep/os/unix/x/x.cpp"
4145 (("<Xcursor/Xcursor.h>") "<X11/Xcursor/Xcursor.h>"))
4146 #t))
4147 (replace 'configure
4148 (lambda* (#:key inputs outputs #:allow-other-keys)
4149 (let* ((jobs (number->string (parallel-job-count)))
4150 (out (assoc-ref outputs "out"))
4151 (lib (string-append out "/lib"))
4152 (data (string-append out "/share/0ad")))
4153 (setenv "JOBS" (string-append "-j" jobs))
4154 (setenv "CC" "gcc")
4155 (with-directory-excursion "build/workspaces"
4156 (zero? (system* "./update-workspaces.sh"
4157 (string-append "--libdir=" lib)
4158 (string-append "--datadir=" data)
4159 ;; TODO: "--with-system-nvtt"
4160 "--with-system-mozjs38"))))))
4161 (delete 'check)
4162 (replace 'install
4163 (lambda* (#:key inputs outputs #:allow-other-keys)
4164 (chdir "binaries")
4165 (let* ((out (assoc-ref outputs "out"))
4166 (bin (string-append out "/bin"))
4167 (lib (string-append out "/lib"))
4168 (data (string-append out "/share/0ad"))
4169 (applications (string-append out "/share/applications"))
4170 (pixmaps (string-append out "/share/pixmaps"))
4171 (0ad-data (assoc-ref inputs "0ad-data")))
4172 ;; data
4173 (copy-recursively "data" data)
4174 (for-each (lambda (file)
4175 (symlink (string-append 0ad-data "/" file)
4176 (string-append data "/" file)))
4177 '("config" "mods/mod" "mods/public" "tools"))
4178 ;; libraries
4179 (for-each (lambda (file)
4180 (install-file file lib))
4181 (find-files "system" "\\.so$"))
4182 ;; binaries
4183 (install-file "system/pyrogenesis" bin)
4184 (with-directory-excursion bin
4185 (symlink "pyrogenesis" "0ad"))
4186 ;; resources
4187 (with-directory-excursion "../build/resources"
4188 (install-file "0ad.desktop" applications)
4189 (install-file "0ad.png" pixmaps))
4190 #t)))
4191 (add-after 'install 'check
4192 (lambda _
4193 (with-directory-excursion "system"
4194 (zero? (system* "./test"))))))))
4195 (home-page "https://play0ad.com")
4196 (synopsis "3D real-time strategy game of ancient warfare")
4197 (description "0 A.D. is a real-time strategy (RTS) game of ancient
4198 warfare. It's a historically-based war/economy game that allows players to
4199 relive or rewrite the history of twelve ancient civilizations, each depicted
4200 at their peak of economic growth and military prowess.
4201
4202 0ad needs a window manager that supports 'Extended Window Manager Hints'.")
4203 (license (list license:bsd-2
4204 license:bsd-3
4205 license:expat
4206 license:gpl2+
4207 license:ibmpl1.0
4208 license:isc
4209 license:lgpl2.1
4210 license:lgpl3
4211 license:mpl2.0
4212 license:zlib))))
4213
4214 ;; There have been no official releases.
4215 (define-public open-adventure
4216 (let* ((commit "d43854f0f6bb8e9eea7fbce80348150e7e7fc34d")
4217 (revision "2"))
4218 (package
4219 (name "open-adventure")
4220 (version (string-append "2.5-" revision "." (string-take commit 7)))
4221 (source (origin
4222 (method git-fetch)
4223 (uri (git-reference
4224 (url "https://gitlab.com/esr/open-adventure")
4225 (commit commit)))
4226 (file-name (string-append name "-" version "-checkout"))
4227 (sha256
4228 (base32
4229 "08bwrvf4axb1rsfd6ia1fddsky9pc1p350vjskhaakg2czc6dsk0"))))
4230 (build-system gnu-build-system)
4231 (arguments
4232 `(#:make-flags (list "CC=gcc")
4233 #:parallel-build? #f ; not supported
4234 #:phases
4235 (modify-phases %standard-phases
4236 (replace 'configure
4237 (lambda* (#:key inputs outputs #:allow-other-keys)
4238 ;; Linenoise is meant to be included, so we have to
4239 ;; copy it into the working directory.
4240 (let* ((linenoise (assoc-ref inputs "linenoise"))
4241 (noisepath (string-append linenoise "/include/linenoise"))
4242 (out (assoc-ref outputs "out")))
4243 (copy-recursively noisepath "linenoise"))
4244 #t))
4245 (add-before 'build 'use-echo
4246 (lambda _
4247 (substitute* "tests/Makefile"
4248 (("/bin/echo") (which "echo")))
4249 #t))
4250 (add-after 'build 'build-manpage
4251 (lambda _
4252 ;; This target is missing a dependency
4253 (substitute* "Makefile"
4254 ((".adoc.6:" line)
4255 (string-append line " advent.adoc")))
4256 (zero? (system* "make" ".adoc.6"))))
4257 ;; There is no install target
4258 (replace 'install
4259 (lambda* (#:key outputs #:allow-other-keys)
4260 (let* ((out (assoc-ref outputs "out"))
4261 (bin (string-append out "/bin"))
4262 (man (string-append out "/share/man/man6")))
4263 (install-file "advent" bin)
4264 (install-file "advent.6" man))
4265 #t)))))
4266 (native-inputs
4267 `(("asciidoc" ,asciidoc)
4268 ("linenoise" ,linenoise)
4269 ("python" ,python)
4270 ("python-pyyaml" ,python-pyyaml)))
4271 (home-page "https://gitlab.com/esr/open-adventure")
4272 (synopsis "Colossal Cave Adventure")
4273 (description "The original Colossal Cave Adventure from 1976 was the
4274 origin of all text adventures, dungeon-crawl (computer) games, and
4275 computer-hosted roleplaying games. This is the last version released by
4276 Crowther & Woods, its original authors, in 1995. It has been known as
4277 \"adventure 2.5\" and \"430-point adventure\".")
4278 (license license:bsd-2))))
4279
4280 (define-public tome4
4281 (package
4282 (name "tome4")
4283 (version "1.5.5")
4284 (synopsis "Single-player, RPG roguelike game set in the world of Eyal")
4285 (source
4286 (origin
4287 (method url-fetch)
4288 (uri (string-append "https://te4.org/dl/t-engine/t-engine4-src-"
4289 version ".tar.bz2"))
4290 (sha256
4291 (base32
4292 "0v2qgdfpvdzd1bcbp9v8pfahj1bgczsq2d4xfhh5wg11jgjcwz03"))
4293 (modules '((guix build utils)))
4294 (snippet
4295 '(substitute* '("src/music.h" "src/tSDL.h")
4296 (("#elif defined(__FreeBSD__)" line)
4297 (string-append
4298 line " || defined(__GNUC__)"))))))
4299 (build-system gnu-build-system)
4300 (native-inputs
4301 `(("unzip" ,unzip)))
4302 (inputs
4303 `(("sdl-union" ,(sdl-union (list sdl2 sdl2-image sdl2-mixer sdl2-ttf)))
4304 ("glu" ,glu)
4305 ("premake4" ,premake4)
4306 ("openal" ,openal)
4307 ("vorbis" ,libvorbis)
4308 ("luajit" ,luajit)))
4309 (arguments
4310 `(#:make-flags '("CC=gcc" "config=release")
4311 #:phases (modify-phases %standard-phases
4312 (replace 'configure
4313 (lambda _
4314 (zero? (system* "premake4" "gmake"))
4315 #t))
4316 (add-after 'set-paths 'set-sdl-paths
4317 (lambda* (#:key inputs #:allow-other-keys)
4318 (setenv "CPATH"
4319 (string-append (assoc-ref inputs "sdl-union")
4320 "/include/SDL2"))
4321 #t))
4322 (delete 'check)
4323 ;; premake doesn't provide install target
4324 (replace 'install
4325 (lambda* (#:key inputs outputs #:allow-other-keys)
4326 (let* ((out (assoc-ref outputs "out"))
4327 (usr (string-append out "/usr"))
4328 (bin (string-append out "/bin"))
4329 (licenses (string-append out "/share/licenses"))
4330 (documents (string-append out "/share/doc"))
4331 (pixmaps (string-append out "/share/pixmaps"))
4332 (icon "te4-icon.png")
4333 (data (string-append out "/share/" ,name))
4334 (applications (string-append
4335 out "/share/applications"))
4336 (unzip (string-append
4337 (assoc-ref inputs "unzip") "/bin/unzip"))
4338 (wrapper (string-append bin "/" ,name)))
4339 ;; icon
4340 (mkdir-p pixmaps)
4341 (system* unzip "-j"
4342 (string-append
4343 "game/engines/te4-" ,version ".teae")
4344 (string-append
4345 "data/gfx/" icon) "-d" pixmaps)
4346 ;; game executable
4347 (install-file "t-engine" data)
4348 (mkdir-p bin)
4349 (with-output-to-file wrapper
4350 (lambda ()
4351 (display
4352 (string-append
4353 "#!/bin/sh\n"
4354 ;; No bootstrap code found,
4355 ;; defaulting to working directory
4356 ;; for engine code!
4357 "cd " data "\n"
4358 "exec -a tome4 ./t-engine \"$@\"\n"))))
4359 (chmod wrapper #o555)
4360 ;; licenses
4361 (for-each (lambda (file)
4362 (install-file file licenses))
4363 '("COPYING" "COPYING-MEDIA"))
4364 ;; documents
4365 (for-each (lambda (file)
4366 (install-file file documents))
4367 '("CONTRIBUTING" "CREDITS"))
4368 ;; data
4369 (copy-recursively "bootstrap" (string-append
4370 data "/bootstrap"))
4371 (copy-recursively "game" (string-append data "/game"))
4372 ;; launcher
4373 (mkdir-p applications)
4374 (with-output-to-file (string-append applications "/"
4375 ,name ".desktop")
4376 (lambda ()
4377 (display
4378 (string-append
4379 "[Desktop Entry]
4380 Name=ToME4
4381 Comment=" ,synopsis "\n"
4382 "Exec=" ,name "\n"
4383 "Icon=" icon "\n"
4384 "Terminal=false
4385 Type=Application
4386 Categories=Game;RolePlaying;\n")))))
4387 #t)))))
4388 (home-page "https://te4.org")
4389 (description "Tales of Maj’Eyal (ToME) RPG, featuring tactical turn-based
4390 combat and advanced character building. Play as one of many unique races and
4391 classes in the lore-filled world of Eyal, exploring random dungeons, facing
4392 challenging battles, and developing characters with your own tailored mix of
4393 abilities and powers. With a modern graphical and customisable interface,
4394 intuitive mouse control, streamlined mechanics and deep, challenging combat,
4395 Tales of Maj’Eyal offers engaging roguelike gameplay for the 21st century.")
4396 (license license:gpl3+)))
4397
4398 (define-public quakespasm
4399 (package
4400 (name "quakespasm")
4401 (version "0.93.0")
4402 (source
4403 (origin
4404 (method url-fetch)
4405 (uri (string-append "mirror://sourceforge/quakespasm/Source/quakespasm-"
4406 version ".tgz"))
4407 (sha256
4408 (base32
4409 "0b2nz7w4za32pc34r62ql270z692qcjs2pm0i3svkxkvfammhdfq"))))
4410 (arguments
4411 `(#:tests? #f
4412 #:make-flags '("CC=gcc"
4413 "MP3LIB=mpg123"
4414 "USE_CODEC_FLAC=1"
4415 "USE_CODEC_MIKMOD=1"
4416 "USE_SDL2=1"
4417 "-CQuake")
4418 #:phases (modify-phases %standard-phases
4419 (delete 'configure)
4420 (add-after 'unpack 'fix-makefile-paths
4421 (lambda* (#:key outputs #:allow-other-keys)
4422 (let ((out (assoc-ref outputs "out")))
4423 (mkdir-p (string-append out "/bin"))
4424 (substitute* "Quake/Makefile"
4425 (("/usr/local/games")
4426 (string-append out "/bin")))
4427 #t))))))
4428 (build-system gnu-build-system)
4429 (inputs `(("libmikmod" ,libmikmod)
4430 ("libvorbis" ,libvorbis)
4431 ("flac" ,flac)
4432 ("mesa" ,mesa)
4433 ("mpg123" ,mpg123)
4434 ("sdl2" ,sdl2)))
4435 (synopsis "First person shooter engine for Quake 1")
4436 (description "Quakespasm is a modern engine for id software's Quake 1.
4437 It includes support for 64 bit CPUs, custom music playback, a new sound driver,
4438 some graphical niceities, and numerous bug-fixes and other improvements.")
4439 (home-page "http://quakespasm.sourceforge.net/")
4440 (license license:gpl2+)))
4441
4442 (define-public vkquake
4443 (package
4444 (inherit quakespasm)
4445 (name "vkquake")
4446 (version "0.97.3")
4447 (source
4448 (origin
4449 (method url-fetch)
4450 (uri (string-append "https://github.com/Novum/vkQuake/archive/"
4451 version ".tar.gz"))
4452 (file-name (string-append name "-" version ".tar.gz"))
4453 (sha256
4454 (base32
4455 "1p0nh2v2ilylw62fxc5qpfcmyhs0s64w8sgh036nc6kn21kbjc0d"))))
4456 (arguments
4457 `(#:make-flags
4458 (let ((vulkanlib (string-append (assoc-ref %build-inputs
4459 "vulkan-icd-loader") "/lib")))
4460 (list "CC=gcc"
4461 "MP3LIB=mpg123"
4462 "USE_CODEC_FLAC=1"
4463 "USE_CODEC_MIKMOD=1"
4464 "USE_SDL2=1"
4465 (string-append "LDFLAGS=-Wl,-rpath=" vulkanlib)
4466 "-CQuake"))
4467 #:phases (modify-phases %standard-phases
4468 (delete 'configure)
4469 (add-after 'unpack 'fix-makefile-paths
4470 (lambda* (#:key outputs #:allow-other-keys)
4471 (let ((vulkan (assoc-ref %build-inputs
4472 "vulkan-icd-loader"))
4473 (out (assoc-ref outputs "out")))
4474 (mkdir-p (string-append out "/bin"))
4475 (substitute* "Quake/Makefile" ((" /usr")
4476 (string-append " " out)))
4477 (substitute* "Quake/Makefile" (("/games")
4478 (string-append "/bin")))
4479 (substitute* "Quake/Makefile" (("..VULKAN_SDK.") vulkan))
4480 #t))))
4481 ,@(strip-keyword-arguments '(#:make-flags #:phases)
4482 (package-arguments quakespasm))))
4483 (inputs `(("vulkan-icd-loader" ,vulkan-icd-loader)
4484 ,@(package-inputs quakespasm)))
4485 (description "vkquake is a modern engine for id software's Quake 1.
4486 It includes support for 64 bit CPUs, custom music playback, a new sound driver,
4487 some graphical niceities, and numerous bug-fixes and other improvements.")
4488 (home-page "https://github.com/Novum/vkQuake")))
4489
4490 (define-public yamagi-quake2
4491 (package
4492 (name "yamagi-quake2")
4493 (version "7.10")
4494 (source
4495 (origin
4496 (method url-fetch)
4497 (uri (string-append "https://deponie.yamagi.org/quake2/quake2-"
4498 version ".tar.xz"))
4499 (sha256
4500 (base32
4501 "0psinbg25mysd58k99s1n34w31w5hj1vppb39gdjb0zqi6sl6cps"))))
4502 (build-system gnu-build-system)
4503 (arguments
4504 `(#:tests? #f
4505 #:make-flags
4506 (list "CC=gcc"
4507 ;; link openAL instead of using dlopen at runtime
4508 "DLOPEN_OPENAL=\"no\""
4509 ;; an optional directory where it will look for quake2 data files
4510 ;; in addition to the current working directory
4511 "WITH_SYSTEMWIDE=yes"
4512 "WITH_SYSTEMDIR=\"/opt/quake2\"")
4513 #:phases
4514 (modify-phases %standard-phases
4515 (delete 'configure)
4516 (replace 'install
4517 (lambda* (#:key outputs #:allow-other-keys)
4518 (let ((out (assoc-ref outputs "out")))
4519 (mkdir-p (string-append out "/lib"))
4520 (mkdir-p (string-append out "/bin"))
4521 ;; The yamagi-quake2 binary must be in the same directory
4522 ;; as it's engine libraries, but symlinking it to /bin is okay
4523 ;; https://github.com/yquake2/yquake2/blob/master/stuff/packaging.md
4524 (copy-recursively "release"
4525 (string-append out "/lib/yamagi-quake2"))
4526 (symlink (string-append out "/lib/yamagi-quake2/quake2")
4527 (string-append out "/bin/yamagi-quake2"))
4528 (symlink (string-append out "/lib/yamagi-quake2/q2ded")
4529 (string-append out "/bin/yamagi-q2ded"))))))))
4530 (inputs `(("sdl2" ,sdl2)
4531 ("mesa" ,mesa)
4532 ("libvorbis" ,libvorbis)
4533 ("zlib" ,zlib)
4534 ("openal" ,openal)))
4535 (native-inputs `(("pkg-config" ,pkg-config)))
4536 (synopsis "First person shooter engine based on quake2")
4537 (description "Yamagi Quake II is an enhanced client for id Software's Quake II.
4538 The main focus is an unchanged single player experience like back in 1997,
4539 thus the gameplay and the graphics are unaltered. However the user may use one
4540 of the unofficial retexturing packs. In comparison with the official client,
4541 over 1000 bugs were fixed and an extensive code audit done,
4542 making Yamagi Quake II one of the most solid Quake II implementations available.")
4543 (home-page "https://www.yamagi.org/quake2/")
4544 (license (list license:gpl2+ ; game and server
4545 (license:non-copyleft ; info-zip
4546 "file://LICENSE"
4547 "See Info-Zip section.")
4548 license:public-domain)))) ; stb
4549
4550 (define-public the-butterfly-effect
4551 (package
4552 (name "the-butterfly-effect")
4553 (version "0.9.3.1")
4554 (source
4555 (origin
4556 (method url-fetch)
4557 (uri (string-append
4558 "https://github.com/the-butterfly-effect/tbe/archive/"
4559 "v" version ".tar.gz"))
4560 (file-name (string-append name "-" version ".tar.gz"))
4561 (sha256
4562 (base32
4563 "18qkp7fgdvyl3haqqa693mgyic7afsznsxgz98z9wn4csaqxsnby"))))
4564 (build-system gnu-build-system)
4565 (arguments
4566 `(#:phases
4567 (modify-phases %standard-phases
4568 (delete 'configure)
4569 ;; There is no "install" phase. By default, tbe is installed
4570 ;; in the build directory. Provide our own installation.
4571 (replace 'install
4572 (lambda* (#:key outputs #:allow-other-keys)
4573 (let* ((out (assoc-ref outputs "out"))
4574 (bin (string-append out "/bin"))
4575 (share (string-append out "/share")))
4576 (install-file "usr/games/tbe" bin)
4577 (mkdir-p share)
4578 (copy-recursively "usr/share" share)
4579 #t))))
4580 ;; Test suite requires a running Xorg server. Even when
4581 ;; provided, it fails with "D-Bus library appears to be
4582 ;; incorrectly set up; failed to read machine uuid: Failed to
4583 ;; open "/etc/machine-id": No such file or directory" along
4584 ;; with multiple "QPainter:: ... Painter not active" warnings.
4585 #:tests? #f))
4586 (inputs
4587 `(("qtbase" ,qtbase)
4588 ("qtsvg" ,qtsvg)))
4589 (native-inputs
4590 `(("cmake" ,cmake)
4591 ("gettext-minimal" ,gettext-minimal)
4592 ("qttools" ,qttools)))
4593 (synopsis "Realistic physics puzzle game")
4594 (description "The Butterfly Effect (tbe) is a game that uses
4595 realistic physics simulations to combine lots of simple mechanical
4596 elements to achieve a simple goal in the most complex way possible.")
4597 (home-page "http://the-butterfly-effect.org/")
4598 ;; Main license is GPL2-only. However, artwork is distributed
4599 ;; under various licenses, listed here.
4600 (license (list license:gpl2 license:public-domain license:expat
4601 license:cc-by-sa3.0 license:gpl3+ license:wtfpl2))))
4602
4603 (define-public pioneer
4604 (package
4605 (name "pioneer")
4606 (version "20171001")
4607 (source (origin
4608 (method url-fetch)
4609 (uri (string-append "https://github.com/pioneerspacesim/pioneer/"
4610 "archive/" version ".tar.gz"))
4611 (file-name (string-append name "-" version ".tar.gz"))
4612 (sha256
4613 (base32
4614 "1nxhx22swfqq6lfvcnpfm31wig3sjv5pp0rslj79nbxc7nyihh8m"))))
4615 (build-system gnu-build-system)
4616 (native-inputs
4617 `(("autoconf" ,autoconf)
4618 ("automake" ,automake)
4619 ("pkg-config" ,pkg-config)))
4620 (inputs
4621 `(("assimp" ,assimp)
4622 ("curl" ,curl)
4623 ("freetype" ,freetype)
4624 ("glu" ,glu)
4625 ("libpng" ,libpng)
4626 ("libsigc++" ,libsigc++)
4627 ("libvorbis" ,libvorbis)
4628 ("lua" ,lua-5.2) ;not compatible with 5.3
4629 ("mesa" ,mesa)
4630 ("sdl" ,(sdl-union (list sdl2 sdl2-image)))))
4631 (arguments
4632 `(#:tests? #f ;tests are broken
4633 #:configure-flags (list "--with-external-liblua"
4634 (string-append "PIONEER_DATA_DIR="
4635 %output "/share/games/pioneer"))
4636 #:phases (modify-phases %standard-phases
4637 (add-after 'unpack 'bootstrap
4638 (lambda _ (zero? (system* "sh" "bootstrap"))))
4639 (add-before 'bootstrap 'fix-lua-check
4640 (lambda _
4641 (substitute* "configure.ac"
4642 (("lua5.2")
4643 (string-append "lua-" ,(version-major+minor
4644 (package-version lua-5.2))))))))))
4645 (home-page "http://pioneerspacesim.net")
4646 (synopsis "Game of lonely space adventure")
4647 (description
4648 "Pioneer is a space adventure game set in our galaxy at the turn of the
4649 31st century. The game is open-ended, and you are free to eke out whatever
4650 kind of space-faring existence you can think of. Look for fame or fortune by
4651 exploring the millions of star systems. Turn to a life of crime as a pirate,
4652 smuggler or bounty hunter. Forge and break alliances with the various
4653 factions fighting for power, freedom or self-determination. The universe is
4654 whatever you make of it.")
4655 (license license:gpl3)))
4656
4657 (define-public badass
4658 (let ((commit "3c3cd669b4fc8f73a102e3702788f7b28dc47dbb")
4659 (revision "0"))
4660 (package
4661 (name "badass")
4662 (version (git-version "0.0" revision commit))
4663 (source (origin
4664 (method git-fetch)
4665 (uri (git-reference
4666 (url "https://github.com/umayr/badass.git")
4667 (commit commit)))
4668 (file-name (git-file-name name version))
4669 (sha256
4670 (base32
4671 "05c9vdcb5ym3z0n5ll3v39mw4yl9jcjnlydmn0yl89ai9pv71zb6"))))
4672 (build-system go-build-system)
4673 (arguments
4674 '(#:import-path "github.com/umayr/badass"))
4675 (synopsis "Hacking contribution graphs in git")
4676 (description
4677 "Badass generates false commits for a range of dates, essentially
4678 hacking the gamification of contribution graphs on platforms such as
4679 Github or Gitlab.")
4680 (home-page "https://github.com/umayr/badass")
4681 (license license:expat))))
4682
4683 (define-public colobot
4684 (package
4685 (name "colobot")
4686 (version "0.1.11-alpha")
4687 (source
4688 (origin
4689 (method url-fetch)
4690 (uri (string-append "https://github.com/colobot/colobot/archive/"
4691 "colobot-gold-" version ".tar.gz"))
4692 (sha256
4693 (base32
4694 "160rq9fp5vd0qaqr3jvzvzrcxk9cac532y8vx4cvq0a8hgylrbad"))))
4695 (build-system cmake-build-system)
4696 (arguments
4697 `(#:tests? #f ;no test
4698 #:phases
4699 (modify-phases %standard-phases
4700 (add-after 'unpack 'unpack-data
4701 (lambda* (#:key inputs #:allow-other-keys)
4702 (let ((data (assoc-ref inputs "colobot-data")))
4703 (invoke "tar" "-xvf" data "-Cdata" "--strip-components=1")
4704 #t)))
4705 (add-after 'unpack-data 'install-music
4706 (lambda* (#:key inputs #:allow-other-keys)
4707 ;; Installation process tries to download music files using
4708 ;; "wget" if not already present. Since we are going to install
4709 ;; them, skip "wget" command check.
4710 (substitute* "data/music/CMakeLists.txt"
4711 (("find_program\\(WGET wget\\)") ""))
4712 ;; Effectively install music.
4713 (let ((data (assoc-ref inputs "colobot-music")))
4714 (invoke "tar" "-xvf" data "-Cdata/music")
4715 #t)))
4716 (add-after 'install 'fix-install-directory
4717 ;; Move binary from "games/" to "bin/".
4718 (lambda* (#:key outputs #:allow-other-keys)
4719 (let ((out (assoc-ref outputs "out")))
4720 (rename-file (string-append out "/games")
4721 (string-append out "/bin"))
4722 #t))))))
4723 (native-inputs
4724 `(("colobot-data"
4725 ,(origin
4726 (method url-fetch)
4727 (uri (string-append
4728 "https://github.com/colobot/colobot-data/archive/"
4729 "colobot-gold-" version ".tar.gz"))
4730 (sha256
4731 (base32
4732 "1pdpsyr41g7xmk03k2g76l214f53ahk04qnkzmsv1fdbbaq7p109"))))
4733 ("colobot-music"
4734 ,(origin
4735 (method url-fetch)
4736 (uri (string-append "https://colobot.info/files/music/"
4737 "colobot-music_ogg_" version ".tar.gz"))
4738 (sha256
4739 (base32
4740 "1s86cd36rwkff329mb1ay1wi5qqyi35564ppgr3f4qqz9wj9vs2m"))))
4741 ("gettext" ,gettext-minimal)
4742 ("librsvg" ,librsvg)
4743 ("po4a" ,po4a)
4744 ("python" ,python-wrapper)))
4745 (inputs
4746 `(("boost" ,boost)
4747 ("glew" ,glew)
4748 ("libogg" ,libogg)
4749 ("libpng" ,libpng)
4750 ("libsndfile" ,libsndfile)
4751 ("libvorbis" ,libvorbis)
4752 ("openal" ,openal)
4753 ("physfs" ,physfs)
4754 ("sdl" ,(sdl-union (list sdl2 sdl2-image sdl2-ttf)))))
4755 (synopsis "Educational programming strategy game")
4756 (description "Colobot: Gold Edition is a real-time strategy game, where
4757 you can program your units (bots) in a language called CBOT, which is similar
4758 to C++ and Java. Your mission is to find a new planet to live and survive.
4759 You can save humanity and get programming skills!")
4760 (home-page "https://colobot.info")
4761 (license license:gpl3+)))
4762
4763 (define-public gzdoom
4764 (package
4765 (name "gzdoom")
4766 (version "3.2.5")
4767 (source (origin
4768 (method url-fetch)
4769 (uri
4770 (string-append "https://zdoom.org/files/gzdoom/src/gzdoom-g"
4771 version ".zip"))
4772 (sha256
4773 (base32
4774 "1164d1zf5in98gp4j981ml3hwmks3q7vzfanlqpjlx2c09jmlv0q"))
4775 (patches (search-patches "gzdoom-search-in-installed-share.patch"))
4776 (modules '((guix build utils)))
4777 (snippet
4778 '(begin
4779 (delete-file-recursively "bzip2")
4780 (delete-file-recursively "game-music-emu")
4781 (delete-file-recursively "jpeg-6b")
4782 (delete-file-recursively "zlib")))))
4783 (arguments
4784 '(#:tests? #f
4785 #:configure-flags
4786 (let ((out (assoc-ref %outputs "out")))
4787 (list
4788 (string-append
4789 "-DCMAKE_CXX_FLAGS:="
4790 "-DSHARE_DIR=\\\"" out "/share/\\\" "
4791 "-DGUIX_OUT_PK3=\\\"" out "/share/games/doom\\\"")
4792 ;; look for libraries at buildtime instead of
4793 ;; dynamically finding them at runtime
4794 "-DDYN_OPENAL=OFF"
4795 "-DDYN_FLUIDSYNTH=OFF"
4796 "-DDYN_GTK=OFF"
4797 "-DDYN_MPG123=OFF"
4798 "-DDYN_SNDFILE=OFF"))
4799 #:phases
4800 (modify-phases %standard-phases
4801 (add-before 'configure 'fix-referenced-paths
4802 (lambda* (#:key inputs outputs #:allow-other-keys)
4803 (let ((fluid-3 (assoc-ref inputs "fluid-3"))
4804 (timidity++ (assoc-ref inputs "timidity++"))
4805 (out (assoc-ref outputs "out")))
4806
4807 (substitute*
4808 "src/CMakeLists.txt"
4809 (("COMMAND /bin/sh")
4810 (string-append "COMMAND " (which "sh"))))
4811
4812 (substitute*
4813 "src/sound/mididevices/music_fluidsynth_mididevice.cpp"
4814 (("/usr/share/sounds/sf2/FluidR3_GM.sf2")
4815 (string-append fluid-3 "/share/soundfonts/FluidR3Mono_GM.sf3")))
4816
4817 (substitute*
4818 "src/sound/mididevices/music_timiditypp_mididevice.cpp"
4819 (("exename = \"timidity\"")
4820 (string-append "exename = \"" timidity++ "/bin/timidity\"")))
4821 #t))))))
4822 (build-system cmake-build-system)
4823 (inputs `(("bzip2" ,bzip2)
4824 ("fluid-3" ,fluid-3)
4825 ("fluidsynth" ,fluidsynth)
4826 ("gtk+3" ,gtk+)
4827 ("libgme" ,libgme)
4828 ("libjpeg" ,libjpeg)
4829 ("libsndfile" ,libsndfile)
4830 ("mesa" ,mesa)
4831 ("mpg123" ,mpg123)
4832 ("openal" ,openal)
4833 ("sdl2" ,sdl2)
4834 ("timidity++" ,timidity++)
4835 ("zlib" ,zlib)))
4836 (native-inputs `(("pkg-config" ,pkg-config)
4837 ("unzip" ,unzip)))
4838 (synopsis "Modern Doom 2 source port")
4839 (description "GZdoom is a port of the Doom 2 game engine, with a modern
4840 renderer. It improves modding support with ZDoom's advanced mapping features
4841 and the new ZScript language. In addition to Doom, it supports Heretic, Hexen,
4842 Strife, Chex Quest, and fan-created games like Harmony, Hacx and Freedoom.")
4843 (home-page "https://zdoom.org/index")
4844 (license (list license:gpl3+ ; gzdoom game
4845 license:lgpl3+ ; gzdoom renderer
4846 license:expat ; gdtoa
4847 (license:non-copyleft ; modified dumb
4848 "file://dumb/licence.txt"
4849 "Dumb license, explicitly GPL compatible.")))))