gnu: python-pyjwt: Update to 1.5.2 [fixes CVE-2017-11424].
[jackhill/guix/guix.git] / gnu / packages / game-development.scm
CommitLineData
6cb89466
1;;; GNU Guix --- Functional package management for GNU
2;;; Copyright © 2014 Tomáš Čech <sleep_walker@suse.cz>
f586c877 3;;; Copyright © 2015 Mark H Weaver <mhw@netris.org>
c24fff61 4;;; Copyright © 2015 Ludovic Courtès <ludo@gnu.org>
0f6139b1 5;;; Copyright © 2015 Alex Kost <alezost@gmail.com>
68c6110c 6;;; Copyright © 2015, 2016, 2017 David Thompson <davet@gnu.org>
82654d95 7;;; Copyright © 2016, 2017 Efraim Flashner <efraim@flashner.co.il>
3c8ba11a 8;;; Copyright © 2016, 2017 Kei Kebreau <kkebreau@posteo.net>
19d311b4 9;;; Copyright © 2016 Ricardo Wurmus <rekado@elephly.net>
a812aff9 10;;; Copyright © 2016, 2017 Julian Graham <joolean@gmail.com>
167f0e82 11;;; Copyright © 2017 Tobias Geerinckx-Rice <me@tobias.gr>
42d0d13d 12;;; Copyright © 2017 Manolis Fragkiskos Ragkousis <manolis837@gmail.com>
6cb89466
13;;;
14;;; This file is part of GNU Guix.
15;;;
16;;; GNU Guix is free software; you can redistribute it and/or modify it
17;;; under the terms of the GNU General Public License as published by
18;;; the Free Software Foundation; either version 3 of the License, or (at
19;;; your option) any later version.
20;;;
21;;; GNU Guix is distributed in the hope that it will be useful, but
22;;; WITHOUT ANY WARRANTY; without even the implied warranty of
23;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
24;;; GNU General Public License for more details.
25;;;
26;;; You should have received a copy of the GNU General Public License
27;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
28
29(define-module (gnu packages game-development)
b0910aad 30 #:use-module ((guix licenses) #:prefix license:)
6cb89466
31 #:use-module (guix packages)
32 #:use-module (guix download)
2a068aec 33 #:use-module (guix git-download)
be4d26f5 34 #:use-module (guix utils)
6cb89466 35 #:use-module (guix build-system cmake)
b0910aad 36 #:use-module (guix build-system gnu)
4bc37bf0 37 #:use-module (guix build-system python)
b0910aad 38 #:use-module (gnu packages)
c608fe8c 39 #:use-module (gnu packages autotools)
94a66dd9 40 #:use-module (gnu packages boost)
2a068aec 41 #:use-module (gnu packages curl)
c24fff61 42 #:use-module (gnu packages databases)
99828fa7 43 #:use-module (gnu packages documentation)
42d0d13d 44 #:use-module (gnu packages fonts)
d2cc38b7 45 #:use-module (gnu packages fontutils)
324b0040 46 #:use-module (gnu packages freedesktop)
d2cc38b7 47 #:use-module (gnu packages fribidi)
c24fff61
JG
48 #:use-module (gnu packages glib)
49 #:use-module (gnu packages gnunet)
42d0d13d
MR
50 #:use-module (gnu packages graphics)
51 #:use-module (gnu packages graphviz)
c24fff61 52 #:use-module (gnu packages guile)
c608fe8c 53 #:use-module (gnu packages m4)
c24fff61 54 #:use-module (gnu packages multiprecision)
4bc37bf0 55 #:use-module (gnu packages music)
c24fff61 56 #:use-module (gnu packages ncurses)
4bc37bf0 57 #:use-module (gnu packages python)
b0910aad 58 #:use-module (gnu packages qt)
4bc37bf0 59 #:use-module (gnu packages video)
5809ffcc 60 #:use-module (gnu packages compression)
5809ffcc
DT
61 #:use-module (gnu packages gl)
62 #:use-module (gnu packages linux)
63 #:use-module (gnu packages xorg)
2a068aec 64 #:use-module (gnu packages xdisorg)
5809ffcc
DT
65 #:use-module (gnu packages fontutils)
66 #:use-module (gnu packages image)
67 #:use-module (gnu packages audio)
d620ea88
DT
68 #:use-module (gnu packages pulseaudio)
69 #:use-module (gnu packages gnome)
70 #:use-module (gnu packages gtk)
71 #:use-module (gnu packages sdl)
240f2785 72 #:use-module (gnu packages pkg-config)
83a4a70b
DT
73 #:use-module (gnu packages xiph)
74 #:use-module (gnu packages lua)
2a068aec
DT
75 #:use-module (gnu packages mp3)
76 #:use-module (gnu packages xml))
6cb89466
77
78(define-public bullet
79 (package
80 (name "bullet")
fd22791e 81 (version "2.86.1")
6cb89466
82 (source (origin
83 (method url-fetch)
937bc2d1
EF
84 (uri (string-append "https://github.com/bulletphysics/bullet3/"
85 "archive/" version ".tar.gz"))
86 (file-name (string-append name "-" version ".tar.gz"))
6cb89466
87 (sha256
88 (base32
fd22791e 89 "0nghzcl84p8di215p7xj0gy1hyy072hw2xk9cnmav9hv6bjb4n60"))))
6cb89466 90 (build-system cmake-build-system)
937bc2d1
EF
91 (arguments
92 '(#:configure-flags (list (string-append
93 "-DBUILD_SHARED_LIBS=ON "
94 "-DCMAKE_CXX_FLAGS=-fPIC "
95 (or (getenv "CXXFLAGS") "")))))
96 (inputs
97 `(("glu" ,glu)
98 ("libx11" ,libx11)
99 ("mesa" ,mesa)))
6cb89466
100 (home-page "http://bulletphysics.org/")
101 (synopsis "3D physics engine library")
102 (description
103 "Bullet is a physics engine library usable for collision detection. It
104is used in some video games and movies.")
b0910aad
DT
105 (license license:zlib)))
106
1a0c4437
KK
107(define-public deutex
108 (package
109 (name "deutex")
f7b60fdc 110 (version "5.0.0")
1a0c4437
KK
111 (source (origin
112 (method url-fetch)
113 (uri (string-append "https://github.com/Doom-Utils/" name
f7b60fdc
KK
114 "/releases/download/v" version "/"
115 name "-" version ".tar.xz"))
1a0c4437
KK
116 (sha256
117 (base32
f7b60fdc 118 "1jvffcpq64hk3jysz4q6zi9hqkksy151ci9553h8q7wrrkbw0i9z"))))
1a0c4437 119 (build-system gnu-build-system)
f7b60fdc 120 (native-inputs `(("asciidoc" ,asciidoc)))
1a0c4437
KK
121 (home-page "https://github.com/Doom-Utils/deutex")
122 (synopsis "WAD file composer for Doom and related games")
123 (description
124 "DeuTex is a wad composer for Doom, Heretic, Hexen and Strife. It can be
125used to extract the lumps of a wad and save them as individual files.
126Conversely, it can also build a wad from separate files. When extracting a
127lump to a file, it does not just copy the raw data, it converts it to an
128appropriate format (such as PPM for graphics, Sun audio for samples, etc.).
129Conversely, when it reads files for inclusion in pwads, it does the necessary
130conversions (for example, from PPM to Doom picture format). In addition,
131DeuTex has functions such as merging wads, etc.")
132 (license license:gpl2+)))
133
94a66dd9
KK
134(define-public grfcodec
135 (package
136 (name "grfcodec")
137 (version "6.0.6")
138 (source (origin
139 (method url-fetch)
140 (uri (string-append "http://binaries.openttd.org/extra/"
141 name "/" version "/" name "-" version
142 "-source.tar.xz"))
143 (sha256
144 (base32
145 "08admgnpqcsifpicbm56apgv360fxapqpbbsp10qyk8i22w1ivsk"))))
146 (build-system gnu-build-system)
147 (arguments
148 '(#:tests? #f ; no check target
149 #:phases
150 (modify-phases %standard-phases
151 (delete 'configure) ; no configure script
152 (replace 'install ; no install target
153 (lambda* (#:key outputs #:allow-other-keys)
154 (let* ((out (assoc-ref outputs "out"))
155 (bin (string-append out "/bin"))
156 (doc (string-append out "/share/doc"))
157 (man (string-append out "/share/man/man1")))
158 (for-each (lambda (file)
159 (install-file file bin))
160 '("grfcodec" "grfid" "grfstrip" "nforenum"))
161 (install-file "COPYING" doc)
162 (with-directory-excursion "docs"
163 (for-each (lambda (file)
164 (install-file (string-append file ".txt") doc))
165 '("auto_correct" "commands" "grf" "grfcodec" "grftut"
166 "readme" "readme.rpn"))
167 (for-each (lambda (file)
168 (install-file file man))
169 (find-files "." "\\.1"))))
170 #t)))))
171 (inputs
172 `(("boost" ,boost)
173 ("libpng" ,libpng)
174 ("zlib" ,zlib)))
175 (synopsis "GRF development tools")
176 (description
3d77785a 177 "The @dfn{Graphics Resource File} (GRF) development tools are a set of
94a66dd9
KK
178tools for developing (New)GRFs. It includes a number of smaller programs, each
179with a specific task:
180@enumerate
181@item @code{grfcodec} decodes and encodes GRF files for OpenTTD.
182@item @code{grfid} extracts the so-called \"GRF ID\" from a GRF.
183@item @code{grfstrip} strips all sprites from a GRF.
184@item @code{nforenum} checks NFO code for errors, making corrections when
185necessary.
186@end enumerate")
187 (home-page "http://dev.openttdcoop.org/projects/grfcodec")
188 ;; GRFCodec, GRFID, and GRFStrip are exclusively under the GPL2.
189 ;; NFORenum is under the GPL2+.
190 ;; The MD5 implementation contained in GRFID is under the zlib license.
191 (license (list license:gpl2 license:gpl2+ license:zlib))))
192
c24fff61
JG
193(define-public gzochi
194 (package
195 (name "gzochi")
a812aff9 196 (version "0.11.1")
c24fff61
JG
197 (source (origin
198 (method url-fetch)
199 (uri (string-append "mirror://savannah/gzochi/gzochi-"
200 version ".tar.gz"))
201 (sha256
202 (base32
a812aff9 203 "13j1m92zhxwkaaja3lg5x0h0b28mrrawdzk9d3hd19031akfxwb3"))))
c24fff61 204 (build-system gnu-build-system)
c24fff61
JG
205 (native-inputs `(("pkgconfig" ,pkg-config)))
206 (inputs `(("bdb" ,bdb)
207 ("glib" ,glib)
c24fff61
JG
208 ("guile" ,guile-2.0)
209 ("libmicrohttpd" ,libmicrohttpd)
210 ("ncurses" ,ncurses)
211 ("sdl" ,sdl)
212 ("zlib" ,zlib)))
213 (home-page "http://www.nongnu.org/gzochi/")
214 (synopsis "Scalable middleware for multiplayer games")
215 (description
216 "gzochi is a framework for developing massively multiplayer online games.
217A server container provides services to deployed games, which are written in
218Guile Scheme, that abstract and simplify some of the most challenging and
219error-prone aspects of online game development: Concurrency, data persistence,
220and network communications. A very thin client library can be embedded to
221provide connectivity for client applications written in any language.")
222 (license license:gpl3+)))
223
7357fcf2
KK
224(define-public nml
225 (package
226 (name "nml")
227 (version "0.4.4")
228 (source
229 (origin
230 (method url-fetch)
231 (uri (string-append "http://bundles.openttdcoop.org/nml/releases/"
232 version "/nml-" version ".tar.gz"))
233 (sha256
234 (base32
235 "0wk9ls5qyjwkra54rkj1gg94xbwzi7b84a5fh1ma1q7pbimi8rmg"))))
236 (build-system python-build-system)
237 (propagated-inputs
238 `(("python-pillow" ,python-pillow)
239 ("python-ply" ,python-ply)))
240 (home-page "http://dev.openttdcoop.org/projects/nml")
241 (synopsis "NML compiler")
242 (description
a7cbe727 243 "@dfn{NewGRF Meta Language} (NML) is a python-based compiler, capable of
7357fcf2
KK
244compiling NML files (along with their associated language, sound and graphic
245files) into @file{.grf} and/or @file{.nfo} files.")
246 (license license:gpl2+)))
247
45f8e7f7
KK
248(define-public python-sge-pygame
249 (package
250 (name "python-sge-pygame")
81353514 251 (version "1.5")
45f8e7f7
KK
252 (source
253 (origin
254 (method url-fetch)
255 (uri (pypi-uri "sge-pygame" version))
256 (sha256
257 (base32
81353514 258 "0g0n722md6nfayiqzadwf0dh821hzqv0alp4by0vjfwr1xzv49mc"))))
45f8e7f7
KK
259 (build-system python-build-system)
260 (propagated-inputs
261 `(("python-pygame" ,python-pygame)
81353514
KK
262 ("python-six" ,python-six)
263 ("python-uniseg" ,python-uniseg)))
45f8e7f7
KK
264 (home-page "http://stellarengine.nongnu.org")
265 (synopsis "2D game engine for Python")
266 (description
267 "The SGE Game Engine (\"SGE\", pronounced like \"Sage\") is a
268general-purpose 2D game engine. It takes care of several details fro you so
269you can focus on the game itself. This makes more rapid game development
270possible, and it also makes the SGE easy to learn.")
271 (license license:lgpl3+)))
272
273(define-public python2-sge-pygame
274 (package-with-python2 python-sge-pygame))
275
1b775fd1
KK
276(define-public python-tmx
277 (package
278 (name "python-tmx")
279 (version "1.9.1")
280 (source
281 (origin
282 (method url-fetch)
be4d26f5
KK
283 (uri (string-append "mirror://savannah/python-tmx/"
284 (version-major+minor version) "/tmx-"
1b775fd1
KK
285 version ".tar.gz"))
286 (sha256
287 (base32
288 "1is107sx3lr09dqjiyn10xqhyv5x54c2ryhys9mb9j3mxjbm227l"))))
289 (build-system python-build-system)
290 (propagated-inputs
291 `(("python-six" ,python-six)))
292 (home-page "http://python-tmx.nongnu.org")
293 (synopsis "Python library for the @code{Tiled} TMX format")
294 (description
295 "Python TMX reads and writes the @code{Tiled} TMX format in a simple way.
296This is useful for map editors or generic level editors, and it's also useful
297for using a map editor or generic level editor like Tiled to edit your game's
298levels.")
299 (license (list license:asl2.0
300 ;; Documentation (only available in the source tarball) is
301 ;; under the CC0 license.
302 license:cc0))))
303
304(define-public python2-tmx
305 (let ((python2-tmx (package-with-python2 python-tmx)))
306 (package
307 (inherit python2-tmx)
308 (propagated-inputs
309 `(("python2-pathlib" ,python2-pathlib)
310 ,@(package-propagated-inputs python2-tmx))))))
311
e99039b5
KK
312(define-public python-xsge
313 (package
314 (name "python-xsge")
cde208da 315 (version "2017.06.09")
e99039b5
KK
316 (source (origin
317 (method url-fetch)
795f3a00 318 (uri (string-append "mirror://savannah/xsge/xsge/xsge-"
e99039b5
KK
319 version ".tar.gz"))
320 (sha256
321 (base32
cde208da 322 "1vy7c2y7ihvmggs93zgfv2h3049s384wid8a5snzrrba8bhbb89p"))))
e99039b5
KK
323 (build-system python-build-system)
324 (arguments
325 '(#:phases
326 (modify-phases %standard-phases
327 ;; xSGE's setup.py script does not support one of the Python build
328 ;; system's default flags, "--single-version-externally-managed".
329 (replace 'install
330 (lambda* (#:key outputs #:allow-other-keys)
331 (zero?
332 (system* "python" "setup.py" "install"
333 (string-append "--prefix=" (assoc-ref outputs "out"))
334 "--root=/")))))
335 #:tests? #f)) ; no check target
336 (propagated-inputs
337 `(("python-sge-pygame" ,python-sge-pygame)
338 ("python-pygame" ,python-pygame)
339 ("python-six" ,python-six)
340 ("python-tmx" ,python-tmx)))
341 (home-page "http://xsge.nongnu.org")
342 (synopsis "Extensions for the SGE Game Engine")
343 (description
344 "xSGE is a collection of modules that make doing certain tasks with the SGE
345Game Engine easier. In addition to SGE's conveniences, the user has access to a
346GUI toolkit, lighting and physics frameworks and @code{Tiled} TMX format
347support.")
348 (license license:gpl3+)))
349
350(define-public python2-xsge
351 (package-with-python2 python-xsge))
352
b0910aad
DT
353(define-public tiled
354 (package
355 (name "tiled")
d3f0e098 356 (version "1.0.3")
b0910aad
DT
357 (source (origin
358 (method url-fetch)
359 (uri (string-append "https://github.com/bjorn/tiled/archive/v"
360 version ".tar.gz"))
f586c877 361 (file-name (string-append name "-" version ".tar.gz"))
b0910aad
DT
362 (sha256
363 (base32
d3f0e098 364 "1qj7l34y5zv2iazmwbix8wdpp88zv7fswbc4arqpp1wak2yna1ix"))))
b0910aad 365 (build-system gnu-build-system)
864cc7ef
RW
366 (inputs
367 `(("qtbase" ,qtbase)
368 ("qtsvg" ,qtsvg)
369 ("zlib" ,zlib)))
370 (native-inputs
371 `(("qttools" ,qttools)))
b0910aad
DT
372 (arguments
373 '(#:phases
d06fc008
EF
374 (modify-phases %standard-phases
375 (replace 'configure
864cc7ef
RW
376 (lambda* (#:key inputs outputs #:allow-other-keys)
377 (substitute* "translations/translations.pro"
378 (("LRELEASE =.*")
379 (string-append "LRELEASE = "
380 (assoc-ref inputs "qttools")
381 "/bin/lrelease\n")))
d06fc008
EF
382 (let ((out (assoc-ref outputs "out")))
383 (system* "qmake"
384 (string-append "PREFIX=" out))))))))
b0910aad
DT
385 (home-page "http://www.mapeditor.org/")
386 (synopsis "Tile map editor")
387 (description
388 "Tiled is a general purpose tile map editor. It is meant to be used for
389editing maps of any tile-based game, be it an RPG, a platformer or a Breakout
390clone.")
391
392 ;; As noted in 'COPYING', part of it is under GPLv2+, while the rest is
393 ;; under BSD-2.
394 (license license:gpl2+)))
5809ffcc
DT
395
396(define-public sfml
397 (package
398 (name "sfml")
7d1b5022 399 (version "2.3.2")
5809ffcc
DT
400 (source (origin
401 (method url-fetch)
7d1b5022
RW
402 ;; Do not fetch the archives from
403 ;; http://mirror0.sfml-dev.org/files/ because files there seem
404 ;; to be changed in place.
405 (uri (string-append "https://github.com/SFML/SFML/archive/"
406 version ".tar.gz"))
407 (file-name (string-append name "-" version ".tar.gz"))
5809ffcc
DT
408 (sha256
409 (base32
7d1b5022 410 "0k2fl5xk3ni2q8bsxl0551inx26ww3w6cp6hssvww0wfjdjcirsm"))))
5809ffcc
DT
411 (build-system cmake-build-system)
412 (arguments
a6e25a50
RW
413 '(#:configure-flags
414 (list "-DSFML_INSTALL_PKGCONFIG_FILES=TRUE")
415 #:tests? #f)) ; no tests
5809ffcc
DT
416 (inputs
417 `(("mesa" ,mesa)
418 ("glew" ,glew)
240f2785
RW
419 ("flac" ,flac)
420 ("libvorbis" ,libvorbis)
5809ffcc 421 ("libx11" ,libx11)
240f2785 422 ("xcb-util-image" ,xcb-util-image)
5809ffcc
DT
423 ("libxrandr" ,libxrandr)
424 ("eudev" ,eudev)
425 ("freetype" ,freetype)
426 ("libjpeg" ,libjpeg)
427 ("libsndfile" ,libsndfile)
428 ("openal" ,openal)))
167f0e82 429 (home-page "https://www.sfml-dev.org")
5809ffcc
DT
430 (synopsis "Simple and Fast Multimedia Library")
431 (description
432 "SFML provides a simple interface to the various computer components,
433to ease the development of games and multimedia applications. It is composed
434of five modules: system, window, graphics, audio and network.")
435 (license license:zlib)))
d620ea88
DT
436
437(define-public sfxr
438 (package
439 (name "sfxr")
440 (version "1.2.1")
441 (source (origin
442 (method url-fetch)
443 (uri (string-append "http://www.drpetter.se/files/sfxr-sdl-1.2.1.tar.gz"))
444 (sha256
445 (base32
446 "0dfqgid6wzzyyhc0ha94prxax59wx79hqr25r6if6by9cj4vx4ya"))))
447 (build-system gnu-build-system)
448 (arguments
449 `(#:phases (modify-phases %standard-phases
450 (delete 'configure) ; no configure script
451 (add-before 'build 'patch-makefile
452 (lambda* (#:key outputs #:allow-other-keys)
453 (let ((out (assoc-ref outputs "out")))
454 (substitute* "Makefile"
455 (("\\$\\(DESTDIR\\)/usr") out))
456 (substitute* "main.cpp"
457 (("/usr/share")
458 (string-append out "/share")))
459 #t))))
460 #:tests? #f)) ; no tests
461 (native-inputs
462 `(("pkg-config" ,pkg-config)
463 ("desktop-file-utils" ,desktop-file-utils)))
464 (inputs
465 `(("sdl" ,sdl)
466 ("gtk+" ,gtk+)))
467 (synopsis "Simple sound effect generator")
468 (description "Sfxr is a tool for quickly generating simple sound effects.
469Originally created for use in video game prototypes, it can generate random
470sounds from presets such as \"explosion\" or \"powerup\".")
471 (home-page "http://www.drpetter.se/project_sfxr.html")
472 (license license:expat)))
0f6139b1
AK
473
474(define-public physfs
475 (package
476 (name "physfs")
477 (version "2.0.3")
478 (source (origin
479 (method url-fetch)
480 (uri (string-append
167f0e82 481 "https://icculus.org/physfs/downloads/physfs-"
0f6139b1
AK
482 version ".tar.bz2"))
483 (file-name (string-append name "-" version ".tar.gz"))
484 (sha256
485 (base32
486 "0sbbyqzqhyf0g68fcvvv20n3928j0x6ik1njmhn1yigvq2bj11na"))))
487 (build-system cmake-build-system)
488 (arguments
489 '(#:tests? #f)) ; no check target
490 (inputs
491 `(("zlib" ,zlib)))
492 (native-inputs
493 `(("doxygen" ,doxygen)))
167f0e82 494 (home-page "https://icculus.org/physfs")
0f6139b1
AK
495 (synopsis "File system abstraction library")
496 (description
497 "PhysicsFS is a library to provide abstract access to various archives.
498It is intended for use in video games. For security, no file writing done
499through the PhysicsFS API can leave a defined @emph{write directory}. For
500file reading, a @emph{search path} with archives and directories is defined,
501and it becomes a single, transparent hierarchical file system. So archive
502files can be accessed in the same way as you access files directly on a disk,
503and it makes it easy to ship a new archive that will override a previous
504archive on a per-file basis.")
505 (license license:zlib)))
83a4a70b
DT
506
507(define-public love
508 (package
509 (name "love")
2c1d46b2 510 (version "0.10.2")
83a4a70b
DT
511 (source (origin
512 (method url-fetch)
513 (uri (string-append "https://bitbucket.org/rude/love/downloads/"
514 "love-" version "-linux-src.tar.gz"))
515 (sha256
516 (base32
2c1d46b2 517 "11x346pw0gqad8nmkmywzx4xpcbfc3dslbrdw5x94n1i25mk0sxj"))))
83a4a70b
DT
518 (build-system gnu-build-system)
519 (native-inputs
520 `(("pkg-config" ,pkg-config)))
521 (inputs
522 `(("devil" ,devil)
523 ("freetype" ,freetype)
524 ("libmodplug" ,libmodplug)
05d48c52 525 ("libtheora" ,libtheora)
83a4a70b
DT
526 ("libvorbis" ,libvorbis)
527 ("luajit" ,luajit)
528 ("mesa" ,mesa)
529 ("mpg123" ,mpg123)
530 ("openal" ,openal)
531 ("physfs" ,physfs)
532 ("sdl2" ,sdl2)
533 ("zlib" ,zlib)))
534 (synopsis "2D game framework for Lua")
535 (description "LÖVE is a framework for making 2D games in the Lua
536programming language.")
537 (home-page "https://love2d.org/")
538 (license license:zlib)))
154f6156
DT
539
540(define-public allegro-4
541 (package
542 (name "allegro")
543 (version "4.4.2")
544 (source (origin
545 (method url-fetch)
3a12e21c
EF
546 (uri (string-append "https://github.com/liballeg/allegro5/"
547 "releases/download/" version "/allegro-"
548 version ".tar.gz"))
154f6156
DT
549 (sha256
550 (base32
551 "1p0ghkmpc4kwij1z9rzxfv7adnpy4ayi0ifahlns1bdzgmbyf88v"))))
552 (build-system cmake-build-system)
553 (arguments
554 '(#:phases
555 (modify-phases %standard-phases
556 (add-after 'unpack 'patch-build-system
557 (lambda _
558 ;; Build addons as shared libraries. Trying to set ADDON_LINKAGE
559 ;; via a command line option doesn't work because it is
560 ;; unconditionally clobbered in the build script.
561 (substitute* '("CMakeLists.txt")
562 (("ADDON_LINKAGE STATIC")
563 "ADDON_LINKAGE SHARED"))
564 #t)))))
565 (inputs
566 `(("glu" ,glu)
567 ("libpng" ,libpng)
568 ("libvorbis" ,libvorbis)
569 ("mesa" ,mesa)
570 ("zlib" ,zlib)))
571 (synopsis "Game programming library")
572 (description "Allegro is a library mainly aimed at video game and
573multimedia programming. It handles common, low-level tasks such as creating
574windows, accepting user input, loading data, drawing images, playing sounds,
575etc.")
576 (home-page "http://liballeg.org")
577 (license license:giftware)))
2a068aec 578
19d311b4
RW
579(define-public allegro
580 (package
581 (name "allegro")
8d2832e3 582 (version "5.2.2.0")
19d311b4
RW
583 (source (origin
584 (method url-fetch)
3a12e21c
EF
585 (uri (string-append "https://github.com/liballeg/allegro5/releases"
586 "/download/" version "/allegro-"
587 (if (equal? "0" (string-take-right version 1))
588 (string-drop-right version 2)
589 version)
590 ".tar.gz"))
19d311b4
RW
591 (sha256
592 (base32
8d2832e3 593 "1z4lrrlmn471wb7vzbd9iw7g379vj0k964vy1s64hcvv5bhvk1g2"))))
19d311b4
RW
594 (build-system cmake-build-system)
595 (arguments `(#:tests? #f)) ; there are no tests
596 (inputs
597 ;; FIXME: Add the following optional inputs: xinput2, opensl, dumb
598 `(("flac" ,flac)
599 ("freetype" ,freetype)
600 ("glu" ,glu)
601 ("gtk" ,gtk+-2)
602 ("libjpeg" ,libjpeg)
603 ("libpng" ,libpng)
604 ("libtheora" ,libtheora)
605 ("libvorbis" ,libvorbis)
606 ("libxcursor" ,libxcursor)
607 ("libxinerama" ,libxinerama)
608 ("libxrandr" ,libxrandr)
609 ("mesa" ,mesa)
610 ("openal" ,openal)
611 ("physfs" ,physfs)
612 ("zlib" ,zlib)))
613 (native-inputs
614 `(("pkg-config" ,pkg-config)))
615 (synopsis "Game programming library")
616 (description "Allegro is a library mainly aimed at video game and
617multimedia programming. It handles common, low-level tasks such as creating
618windows, accepting user input, loading data, drawing images, playing sounds,
619etc.")
620 (home-page "http://liballeg.org")
621 (license license:bsd-3)))
622
cdf8f391
RW
623(define-public allegro-5.0
624 (package (inherit allegro)
625 (name "allegro")
626 (version "5.0.11")
627 (source (origin
628 (method url-fetch)
3a12e21c
EF
629 (uri (string-append "https://github.com/liballeg/allegro5/releases"
630 "/download/" version "/allegro-"
631 (if (equal? "0" (string-take-right version 1))
632 (string-drop-right version 2)
633 version)
634 ".tar.gz"))
cdf8f391
RW
635 (sha256
636 (base32
637 "0cd51qrh97jrr0xdmnivqgwljpmizg8pixsgvc4blqqlaz4i9zj9"))))))
638
2a068aec
DT
639(define-public aseprite
640 (package
641 (name "aseprite")
82654d95 642 (version "1.1.7") ; After 1.1.7 the source is no longer distributed under the GPL.
ff4dc16e 643 ;; TODO: Unbundle third party software.
2a068aec 644 (source (origin
ff4dc16e
MB
645 (method url-fetch/zipbomb)
646 (uri (string-append "https://github.com/aseprite/aseprite"
647 "/releases/download/v" version
648 "/Aseprite-v" version "-Source.zip"))
2a068aec
DT
649 (sha256
650 (base32
82654d95 651 "1plss4i1lfxcznv9p0pip1bkhj7ipw7jlhsh5avd6dzw079l4nvv"))))
2a068aec
DT
652 (build-system cmake-build-system)
653 (arguments
654 '(#:configure-flags
655 ;; Use shared libraries instead of building bundled source.
656 (list "-DWITH_WEBP_SUPPORT=1"
657 "-DUSE_SHARED_CURL=1"
658 "-DUSE_SHARED_GIFLIB=1"
659 "-DUSE_SHARED_JPEGLIB=1"
660 "-DUSE_SHARED_ZLIB=1"
661 "-DUSE_SHARED_LIBPNG=1"
662 "-DUSE_SHARED_LIBLOADPNG=1"
663 "-DUSE_SHARED_LIBWEBP=1"
664 "-DUSE_SHARED_TINYXML=1"
665 "-DUSE_SHARED_PIXMAN=1"
666 "-DUSE_SHARED_FREETYPE=1"
667 "-DUSE_SHARED_ALLEGRO4=1"
668 "-DENABLE_UPDATER=0" ; no auto-updates
669 (string-append "-DFREETYPE_INCLUDE_DIR="
670 (assoc-ref %build-inputs "freetype")
de1d68a2 671 "/include/freetype2"))))
2a068aec
DT
672 (native-inputs
673 `(("pkg-config" ,pkg-config)))
674 ;; TODO: Use a patched Allegro 4 that supports window resizing. This
675 ;; patched version is bundled with Aseprite, but the patches should be
676 ;; extracted and applied on top of a standalone Allegro 4 package.
677 (inputs
678 `(("allegro" ,allegro-4)
679 ("curl" ,curl)
680 ("freetype" ,freetype)
681 ("giflib" ,giflib)
682 ("libjpeg" ,libjpeg)
683 ("libpng" ,libpng)
684 ("libwebp" ,libwebp)
685 ("libx11" ,libx11)
686 ("libxext" ,libxext)
687 ("libxxf86vm" ,libxxf86vm)
688 ("pixman" ,pixman)
689 ("tinyxml" ,tinyxml)
690 ("zlib" ,zlib)))
691 (synopsis "Animated sprite editor and pixel art tool")
692 (description "Aseprite is a tool for creating 2D pixel art for video
693games. In addition to basic pixel editing features, Aseprite can assist in
694the creation of animations, tiled graphics, texture atlases, and more.")
167f0e82 695 (home-page "https://www.aseprite.org/")
2a068aec 696 (license license:gpl2+)))
966dff3b
KY
697
698(define-public qqwing
699 (package
700 (name "qqwing")
701 (version "1.3.4")
702 (source (origin
703 (method url-fetch)
704 (uri (string-append
705 "https://qqwing.com/"
706 name "-" version ".tar.gz"))
707 (sha256
708 (base32
709 "0bw0papyqjg22z6irf36gs54y8236wa37b6gyn2h1spy65n76lqp"))))
710 (build-system gnu-build-system)
711 (native-inputs
712 `(("pkg-config" ,pkg-config)))
713 (home-page "https://qqwing.com/")
714 (synopsis "Sudoku puzzle solver and generator")
715 (description
716 "QQWing is a Sudoku puzzle generator and solver.
717It offers the following features:
718@enumerate
719@item Can solve 1000 puzzles in 1 second and generate 1000 puzzles in 25 seconds.
720@item Uses logic. Uses as many solve techniques as possible when solving
721 puzzles rather than guessing.
722@item Rates puzzles. Most generators don't give an indication of the difficulty
723 of a Sudoku puzzle. QQwing does.
724@item Can print solve instructions for any puzzle.
725@item Customizable output style, including a CSV style that is easy to
726 import into a database.
727@end enumerate")
728 (license license:gpl2+)))
d2cc38b7
KK
729
730(define-public quesoglc
731 (package
732 (name "quesoglc")
733 (version "0.7.2")
734 (source (origin
735 (method url-fetch)
736 (uri (string-append "mirror://sourceforge/" name "/" version "/"
737 name "-" version "-free.tar.bz2"))
738 (sha256
739 (base32
740 "08ddhywdy2qg17m592ng3yr0p1ih96irg8wg729g75hsxxq9ipks"))))
741 (build-system gnu-build-system)
742 (native-inputs `(("pkg-config" ,pkg-config)))
743 (inputs `(("fontconfig" ,fontconfig)
744 ("freeglute" ,freeglut)
745 ("fribidi" ,fribidi)
746 ("glew" ,glew)))
747 (home-page "http://quesoglc.sourceforge.net")
748 (synopsis "Implementation of the OpenGL Character Renderer (GLC)")
749 (description
750 "The OpenGL Character Renderer (GLC) is a state machine that provides
751OpenGL programs with character rendering services via an application programming
752interface (API).")
753 (license (list license:expat license:lgpl2.1+))))
4bc37bf0
KK
754
755(define-public python-pygame
756 (package
757 (name "python-pygame")
052f75da 758 (version "1.9.3")
4bc37bf0
KK
759 (source (origin
760 (method url-fetch)
052f75da 761 (uri (pypi-uri "pygame" version))
4bc37bf0
KK
762 (sha256
763 (base32
052f75da 764 "1hlydiyygl444bq5m5g8n3jsxsgrdyxlm42ipmfbw36wkf0j243m"))))
4bc37bf0
KK
765 (build-system python-build-system)
766 (arguments
052f75da 767 `(#:tests? #f ; Tests require pygame to be installed first.
4bc37bf0
KK
768 #:phases
769 (modify-phases %standard-phases
770 ;; Set the paths to the dependencies manually because
771 ;; the configure script does not allow passing them as
772 ;; parameters. This also means we can skip the configure
773 ;; phase.
774 (add-before 'build 'set-library-paths
775 (lambda* (#:key inputs outputs #:allow-other-keys)
776 (let ((sdl-ref (assoc-ref inputs "sdl"))
777 (font-ref (assoc-ref inputs "sdl-ttf"))
778 (image-ref (assoc-ref inputs "sdl-image"))
779 (mixer-ref (assoc-ref inputs "sdl-mixer"))
780 (smpeg-ref (assoc-ref inputs "libsmpeg"))
781 (png-ref (assoc-ref inputs "libpng"))
782 (jpeg-ref (assoc-ref inputs "libjpeg"))
052f75da 783 (freetype-ref (assoc-ref inputs "freetype"))
4bc37bf0
KK
784 (v4l-ref (assoc-ref inputs "v4l-utils"))
785 (out-ref (assoc-ref outputs "out")))
786 (substitute* "Setup.in"
787 (("SDL = -I/usr/include/SDL")
788 (string-append "SDL = -I" sdl-ref "/include/SDL -I.")))
789 (substitute* "Setup.in"
790 (("FONT = -lSDL_ttf")
791 (string-append "FONT = -I" font-ref "/include/SDL -L"
792 font-ref "/lib -lSDL_ttf")))
793 (substitute* "Setup.in"
794 (("IMAGE = -lSDL_image")
795 (string-append "IMAGE = -I" image-ref "/include/SDL -L"
796 image-ref "/lib -lSDL_image")))
797 (substitute* "Setup.in"
798 (("MIXER = -lSDL_mixer")
799 (string-append "MIXER = -I" mixer-ref "/include/SDL -L"
800 mixer-ref "/lib -lSDL_mixer")))
801 (substitute* "Setup.in"
802 (("SMPEG = -lsmpeg")
803 (string-append "SMPEG = -I" smpeg-ref "/include/smpeg -L"
804 smpeg-ref "/lib -lsmpeg")))
805 (substitute* "Setup.in"
806 (("PNG = -lpng")
807 (string-append "PNG = -I" png-ref "/include -L"
808 png-ref "/lib -lpng")))
809 (substitute* "Setup.in"
810 (("JPEG = -ljpeg")
811 (string-append "JPEG = -I" jpeg-ref "/include -L"
812 jpeg-ref "/lib -ljpeg")))
052f75da
DM
813
814 (substitute* "Setup.in"
815 (("FREETYPE = -lfreetype")
816 (string-append "FREETYPE = -I" freetype-ref "/include/freetype2 -L"
817 freetype-ref "/lib -lfreetype")))
818
4bc37bf0
KK
819 (substitute* "Setup.in"
820 (("^pypm") "#pypm"))
4bc37bf0
KK
821 ;; Create a path to a header file provided by v4l-utils.
822 (system* "mkdir" "linux")
823 (system* "ln" "--symbolic"
824 (string-append v4l-ref "/include/libv4l1-videodev.h")
825 "linux/videodev.h")
826 (system* "ln" "--symbolic" "Setup.in" "Setup")))))))
4bc37bf0 827 (inputs
052f75da
DM
828 `(("freetype" ,freetype)
829 ("sdl" ,sdl)
4bc37bf0
KK
830 ("sdl-image" ,sdl-image)
831 ("sdl-mixer" ,sdl-mixer)
832 ("sdl-ttf" ,sdl-ttf)
833 ("sdl-gfx" ,sdl-gfx)
834 ("libjpeg" ,libjpeg)
835 ("libpng" ,libpng)
836 ("libX11" ,libx11)
837 ("libsmpeg" ,libsmpeg)
838 ("portmidi" ,portmidi)
839 ("v4l-utils" ,v4l-utils)))
167f0e82 840 (home-page "https://www.pygame.org")
4bc37bf0
KK
841 (synopsis "SDL wrapper for Python")
842 (description "Pygame is a set of Python modules designed for writing games.
843Pygame adds functionality on top of the excellent SDL library. This allows you
844to create fully featured games and multimedia programs in the python language.")
845 (license (list license:bsd-2
846 ;; python numeric license as listed by Debian looks like
847 ;; an Expat-style license with a warranty disclaimer for
848 ;; the U.S. government and the University of California.
849 license:expat
850 license:lgpl2.0+
851 license:lgpl2.1+
852 license:gpl3+
853 license:psfl
854 license:public-domain
855 license:lgpl2.1+))))
052f75da
DM
856
857(define-public python2-pygame
858 (package-with-python2 python-pygame))
68c6110c
DT
859
860(define-public grafx2
861 (package
862 (name "grafx2")
863 (version "2.4")
864 (source (origin
865 (method url-fetch)
866 ;; XXX: There is no URL that contains the version. :(
867 (uri "http://pulkomandy.tk/projects/GrafX2/downloads/21")
868 (sha256
869 (base32
870 "0svsy6rqmdj11b400c242i2ixihyz0hds0dgicqz6g6dcgmcl62q"))))
871 (build-system gnu-build-system)
872 (arguments
873 '(#:phases
874 (modify-phases %standard-phases
875 (delete 'configure) ; no configure script
876 (add-before 'build 'change-to-src-directory
877 (lambda _
878 (chdir "src")
879 #t)))
880 #:make-flags
881 ;; SDL header files are referenced without the preceeding "SDL/".
882 (list (string-append "CFLAGS=-I"
883 (assoc-ref %build-inputs "sdl-union")
884 "/include/SDL")
885 (string-append "prefix="
886 (assoc-ref %outputs "out")))
887 #:tests? #f)) ; no check target
888 (native-inputs
889 `(("pkg-config" ,pkg-config)))
890 (inputs
891 `(("libpng" ,libpng)
892 ("lua" ,lua-5.1)
893 ("sdl-union" ,(sdl-union (list sdl sdl-image sdl-ttf)))))
894 (synopsis "Bitmap paint program")
895 (description "GrafX2 is a bitmap paint program inspired by the Amiga
7432d3ae 896programs Deluxe Paint and Brilliance. Specializing in 256-color drawing, it
68c6110c
DT
897includes a very large number of tools and effects that make it particularly
898suitable for pixel art, game graphics, and generally any detailed graphics
899painted with a mouse.")
900 (home-page "http://pulkomandy.tk/projects/GrafX2")
901 (license license:gpl2))) ; GPLv2 only
c608fe8c
MR
902
903(define-public ois
904 (package
905 (name "ois")
906 (version "1.3")
907 (source
908 (origin
909 ;; Development has moved to github and there are no recent tarball
910 ;; releases.
911 (method git-fetch)
912 (uri (git-reference
913 (url "https://github.com/wgois/OIS.git")
914 (commit "bb75ccc1aabc1c547195579963601ff6080ca2f2")))
915 (file-name (string-append name "-" version))
916 (sha256
917 (base32
918 "0w0pamjc3vj0jr718hysrw8x076fq6n9rd6wcb36sn2jd0lqvi98"))))
919 (build-system gnu-build-system)
920 (arguments
921 `(#:phases
922 (modify-phases %standard-phases
923 (add-after 'unpack 'bootstrap
924 (lambda _ (zero? (system* "sh" "bootstrap")))))))
925 (native-inputs
926 `(("autoconf" ,autoconf)
927 ("automake" ,automake)
928 ("libtool" ,libtool)
929 ("m4" ,m4)
930 ("pkg-config" ,pkg-config)))
931 (inputs
932 `(("libxaw" ,libxaw)))
933 (synopsis "Object Oriented Input System")
934 (description
935 "Cross Platform Object Oriented Input Lib System is a cross platform,
936simple solution for using all kinds of Input Devices (Keyboards, Mice,
937Joysticks, etc) and feedback devices (e.g. force feedback). Meant to be very
938robust and compatible with many systems and operating systems.")
939 (home-page "https://github.com/wgois/OIS")
940 (license license:zlib)))
42d0d13d
MR
941
942(define-public mygui
943 (package
944 (name "mygui")
945 (version "3.2.2")
946 (source
947 (origin
948 (method url-fetch)
949 (uri
950 (string-append "https://github.com/MyGUI/" name
951 "/archive/MyGUI" version ".tar.gz"))
952 (sha256
953 (base32
954 "13x7cydmj7gjmsg702sqjbfi53z265iv6j7binv3r6a7ibndfa0a"))))
955 (build-system cmake-build-system)
956 (arguments
957 '(#:tests? #f ; No test target
958 #:configure-flags
959 (list "-DMYGUI_INSTALL_DOCS=TRUE"
960 (string-append "-DOGRE_INCLUDE_DIR="
961 (assoc-ref %build-inputs "ogre")
962 "/include/OGRE"))))
963 (native-inputs
964 `(("boost" ,boost)
965 ("doxygen" ,doxygen)
966 ("pkg-config" ,pkg-config)))
967 (inputs
968 `(("font-dejavu" ,font-dejavu)
969 ("freetype" ,freetype)
970 ("graphviz" ,graphviz)
971 ("libx11" ,libx11)
972 ("ogre" ,ogre)
973 ("ois" ,ois)))
974 (synopsis "Fast, flexible and simple GUI")
975 (description
976 "MyGUI is a library for creating Graphical User Interfaces (GUIs) for games
977and 3D applications. The main goals of mygui are: speed, flexibility and ease
978of use.")
979 (home-page "http://mygui.info/")
980 (license license:expat)))
e9a599cd
MR
981
982(define-public openmw
983 (package
984 (name "openmw")
985 (version "0.42.0")
986 (source
987 (origin
988 (method url-fetch)
989 (uri
990 (string-append "https://github.com/OpenMW/openmw/archive/"
991 name "-" version ".tar.gz"))
992 (sha256
993 (base32
994 "1pla8016lpbg8cgm9kia318a860f26dmiayc72p3zl35mqrc7g7w"))))
995 (build-system cmake-build-system)
996 (arguments
997 `(#:tests? #f ; No test target
998 #:configure-flags
999 (list "-DDESIRED_QT_VERSION=5")))
1000 (native-inputs
1001 `(("boost" ,boost)
1002 ("doxygen" ,doxygen)
1003 ("pkg-config" ,pkg-config)))
1004 (inputs
1005 `(("bullet" ,bullet)
1006 ("ffmpeg" ,ffmpeg)
1007 ("libxt" ,libxt)
1008 ("mygui" ,mygui)
1009 ("openal" ,openal)
1010 ("openscenegraph" ,openscenegraph)
1011 ("qtbase" ,qtbase)
1012 ("sdl" ,sdl2)
1013 ("unshield" ,unshield)))
1014 (synopsis "Free software re-implementation of the RPG Morrowind engine")
1015 (description
1016 "OpenMW is a free, open source and modern engine which reimplements and
1017extends the one that runs the 2002 open-world RPG Morrowind. The engine comes
1018with its own editor, called OpenMW-CS which allows the user to edit or create
1019their own original games.")
1020 (home-page "https://openmw.org")
1021 (license license:gpl3)))