Merge branch 'staging'
[jackhill/guix/guix.git] / gnu / packages / graphics.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2015, 2016 Ludovic Courtès <ludo@gnu.org>
3 ;;; Copyright © 2015 Tomáš Čech <sleep_walker@gnu.org>
4 ;;; Copyright © 2016, 2019 Leo Famulari <leo@famulari.name>
5 ;;; Copyright © 2016, 2017, 2019 Ricardo Wurmus <rekado@elephly.net>
6 ;;; Copyright © 2016, 2018 Efraim Flashner <efraim@flashner.co.il>
7 ;;; Copyright © 2016 Andreas Enge <andreas@enge.fr>
8 ;;; Copyright © 2017 Manolis Fragkiskos Ragkousis <manolis837@gmail.com>
9 ;;; Copyright © 2017, 2018 Ben Woodcroft <donttrustben@gmail.com>
10 ;;; Copyright © 2017–2021 Tobias Geerinckx-Rice <me@tobias.gr>
11 ;;; Copyright © 2018 Mathieu Othacehe <m.othacehe@gmail.com>
12 ;;; Copyright © 2018 Alex Kost <alezost@gmail.com>
13 ;;; Copyright © 2018 Kei Kebreau <kkebreau@posteo.net>
14 ;;; Copyright © 2019, 2020 Mark H Weaver <mhw@netris.org>
15 ;;; Copyright © 2019 Carlo Zancanaro <carlo@zancanaro.id.au>
16 ;;; Copyright © 2019 Steve Sprang <scs@stevesprang.com>
17 ;;; Copyright © 2019 John Soo <jsoo1@asu.edu>
18 ;;; Copyright © 2019 Pierre Neidhardt <mail@ambrevar.xyz>
19 ;;; Copyright © 2019, 2020 Marius Bakke <mbakke@fastmail.com>
20 ;;; Copyright © 2019 Tanguy Le Carrour <tanguy@bioneland.org>
21 ;;; Copyright © 2020 Jakub Kądziołka <kuba@kadziolka.net>
22 ;;; Copyright © 2020, 2021 Nicolas Goaziou <mail@nicolasgoaziou.fr>
23 ;;; Copyright © 2020 Raghav Gururajan <raghavgururajan@disroot.org>
24 ;;; Copyright © 2020 Maxim Cournoyer <maxim.cournoyer@gmail.com>
25 ;;; Copyright © 2020 Gabriel Arazas <foo.dogsquared@gmail.com>
26 ;;; Copyright © 2021 Antoine Côté <antoine.cote@posteo.net>
27 ;;;
28 ;;; This file is part of GNU Guix.
29 ;;;
30 ;;; GNU Guix is free software; you can redistribute it and/or modify it
31 ;;; under the terms of the GNU General Public License as published by
32 ;;; the Free Software Foundation; either version 3 of the License, or (at
33 ;;; your option) any later version.
34 ;;;
35 ;;; GNU Guix is distributed in the hope that it will be useful, but
36 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
37 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
38 ;;; GNU General Public License for more details.
39 ;;;
40 ;;; You should have received a copy of the GNU General Public License
41 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
42
43 (define-module (gnu packages graphics)
44 #:use-module (gnu packages)
45 #:use-module (gnu packages algebra)
46 #:use-module (gnu packages audio)
47 #:use-module (gnu packages autotools)
48 #:use-module (gnu packages base)
49 #:use-module (gnu packages bash)
50 #:use-module (gnu packages bison)
51 #:use-module (gnu packages boost)
52 #:use-module (gnu packages cdrom)
53 #:use-module (gnu packages check)
54 #:use-module (gnu packages compression)
55 #:use-module (gnu packages crypto)
56 #:use-module (gnu packages datastructures)
57 #:use-module (gnu packages documentation)
58 #:use-module (gnu packages flex)
59 #:use-module (gnu packages fonts)
60 #:use-module (gnu packages fontutils)
61 #:use-module (gnu packages freedesktop)
62 #:use-module (gnu packages gettext)
63 #:use-module (gnu packages ghostscript)
64 #:use-module (gnu packages gl)
65 #:use-module (gnu packages glib)
66 #:use-module (gnu packages gnome)
67 #:use-module (gnu packages gnunet)
68 #:use-module (gnu packages graphviz)
69 #:use-module (gnu packages gstreamer)
70 #:use-module (gnu packages gtk)
71 #:use-module (gnu packages haskell-xyz)
72 #:use-module (gnu packages image)
73 #:use-module (gnu packages image-processing)
74 #:use-module (gnu packages imagemagick)
75 #:use-module (gnu packages jemalloc)
76 #:use-module (gnu packages kde-frameworks)
77 #:use-module (gnu packages linux)
78 #:use-module (gnu packages lua)
79 #:use-module (gnu packages maths)
80 #:use-module (gnu packages mp3)
81 #:use-module (gnu packages multiprecision)
82 #:use-module (gnu packages pdf)
83 #:use-module (gnu packages perl)
84 #:use-module (gnu packages photo)
85 #:use-module (gnu packages pkg-config)
86 #:use-module (gnu packages plotutils)
87 #:use-module (gnu packages pretty-print)
88 #:use-module (gnu packages pth)
89 #:use-module (gnu packages pulseaudio) ; libsndfile, libsamplerate
90 #:use-module (gnu packages python)
91 #:use-module (gnu packages python-xyz)
92 #:use-module (gnu packages qt)
93 #:use-module (gnu packages readline)
94 #:use-module (gnu packages sdl)
95 #:use-module (gnu packages stb)
96 #:use-module (gnu packages swig)
97 #:use-module (gnu packages tbb)
98 #:use-module (gnu packages upnp)
99 #:use-module (gnu packages video)
100 #:use-module (gnu packages xiph)
101 #:use-module (gnu packages xml)
102 #:use-module (gnu packages xorg)
103 #:use-module (gnu packages xdisorg)
104 #:use-module (guix build-system copy)
105 #:use-module (guix build-system cmake)
106 #:use-module (guix build-system gnu)
107 #:use-module (guix build-system meson)
108 #:use-module (guix build-system python)
109 #:use-module (guix build-system qt)
110 #:use-module (guix download)
111 #:use-module (guix git-download)
112 #:use-module (guix hg-download)
113 #:use-module ((guix licenses) #:prefix license:)
114 #:use-module (guix packages)
115 #:use-module (guix utils))
116
117 (define-public eglexternalplatform
118 (package
119 (name "eglexternalplatform")
120 (version "1.1")
121 (source
122 (origin
123 (method git-fetch)
124 (uri
125 (git-reference
126 (url "https://github.com/NVIDIA/eglexternalplatform")
127 (commit version)))
128 (file-name
129 (git-file-name name version))
130 (sha256
131 (base32 "0lr5s2xa1zn220ghmbsiwgmx77l156wk54c7hybia0xpr9yr2nhb"))))
132 (build-system copy-build-system)
133 (arguments
134 `(#:phases
135 (modify-phases %standard-phases
136 (add-after 'unpack 'patch-pkgconfig
137 (lambda* (#:key outputs #:allow-other-keys)
138 (substitute* "eglexternalplatform.pc"
139 (("/usr")
140 (assoc-ref outputs "out")))
141 #t))
142 (add-after 'install 'revise
143 (lambda* (#:key outputs #:allow-other-keys)
144 (let* ((out (assoc-ref outputs "out")))
145 (mkdir-p (string-append out "/include/EGL"))
146 (rename-file
147 (string-append out "/interface")
148 (string-append out "/include/EGL"))
149 (mkdir-p (string-append out "/share/pkgconfig"))
150 (rename-file
151 (string-append out "/eglexternalplatform.pc")
152 (string-append out "/share/pkgconfig/eglexternalplatform.pc"))
153 (for-each delete-file-recursively
154 (list
155 (string-append out "/samples")
156 (string-append out "/COPYING")
157 (string-append out "/README.md"))))
158 #t)))))
159 (synopsis "EGL External Platform interface")
160 (description "EGLExternalPlatform is an specification of the EGL External
161 Platform interface for writing EGL platforms and their interactions with modern
162 window systems on top of existing low-level EGL platform implementations. This
163 keeps window system implementation specifics out of EGL drivers by using
164 application-facing EGL functions.")
165 (home-page "https://github.com/NVIDIA/eglexternalplatform")
166 (license license:expat)))
167
168 (define-public egl-wayland
169 (package
170 (name "egl-wayland")
171 (version "1.1.6")
172 (source
173 (origin
174 (method git-fetch)
175 (uri
176 (git-reference
177 (url "https://github.com/NVIDIA/egl-wayland")
178 (commit version)))
179 (file-name
180 (git-file-name name version))
181 (sha256
182 (base32 "1n9lg8hpjgxlf7dpddkjhbslsfd0symla2wk6jjmnl9n9jv2gmzk"))))
183 (build-system meson-build-system)
184 (native-inputs
185 `(("pkg-config" ,pkg-config)))
186 (inputs
187 `(("mesa" ,mesa)
188 ("wayland" ,wayland)))
189 (propagated-inputs
190 `(("eglexternalplatform" ,eglexternalplatform)))
191 (synopsis "EGLStream-based Wayland external platform")
192 (description "EGL-Wayland is an implementation of a EGL External Platform
193 library to add client-side Wayland support to EGL on top of EGLDevice and
194 EGLStream families of extensions.")
195 (home-page "https://github.com/NVIDIA/egl-wayland")
196 (license license:expat)))
197
198 (define-public mmm
199 (package
200 (name "mmm")
201 (version "0.1.1")
202 (source
203 (origin
204 (method git-fetch)
205 (uri
206 (git-reference
207 (url "https://github.com/hodefoting/mmm")
208 (commit version)))
209 (file-name
210 (git-file-name name version))
211 (sha256
212 (base32 "1xmcv6rwinqsbr863rgl9005h2jlmd7k2qrwsc1h4fb8r61ykpjl"))))
213 (build-system meson-build-system)
214 (native-inputs
215 `(("luajit" ,luajit)
216 ("pkg-config" ,pkg-config)))
217 (inputs
218 `(("alsa" ,alsa-lib)
219 ("sdl" ,sdl)
220 ("sdl2" ,sdl2)))
221 (synopsis "Memory Mapped Machine")
222 (description "MMM is a shared memory protocol for virtualising access to
223 framebuffer graphics, audio output and input event.")
224 (home-page "https://github.com/hodefoting/mrg")
225 (license license:isc)))
226
227 (define-public directfb
228 (package
229 (name "directfb")
230 (version "1.7.7")
231 (source
232 (origin
233 (method git-fetch)
234 (uri
235 (git-reference
236 (url "https://github.com/deniskropp/DirectFB")
237 (commit "DIRECTFB_1_7_7")))
238 (file-name (git-file-name name version))
239 (sha256
240 (base32 "0bs3yzb7hy3mgydrj8ycg7pllrd2b6j0gxj596inyr7ihssr3i0y"))))
241 (build-system gnu-build-system)
242 (arguments
243 `(#:phases
244 (modify-phases %standard-phases
245 (add-after 'unpack 'disable-configure-during-bootstrap
246 (lambda _
247 (substitute* "autogen.sh"
248 (("^.*\\$srcdir/configure.*") ""))
249 #t)))))
250 (native-inputs
251 `(("autoconf" ,autoconf)
252 ("automake" ,automake)
253 ("libtool" ,libtool)
254 ("perl" ,perl)
255 ("pkg-config" ,pkg-config)))
256 (inputs
257 `(("alsa" ,alsa-lib)
258 ("ffmpeg" ,ffmpeg)
259 ("freetype" ,freetype)
260 ("glu" ,glu)
261 ("gstreamer" ,gstreamer)
262 ("imlib2" ,imlib2)
263 ("jasper" ,jasper)
264 ("jpeg" ,libjpeg-turbo)
265 ("libcddb" ,libcddb)
266 ("libdrm" ,libdrm)
267 ("libtimidity" ,libtimidity)
268 ("linux-headers" ,linux-libre-headers)
269 ("mad" ,libmad)
270 ("mng" ,libmng)
271 ("mpeg2" ,libmpeg2)
272 ("mpeg3" ,libmpeg3)
273 ("opengl" ,mesa)
274 ("png" ,libpng)
275 ("sdl" ,sdl)
276 ("svg" ,librsvg)
277 ("tiff" ,libtiff)
278 ("tslib" ,tslib)
279 ("vdpau" ,libvdpau)
280 ("vorbisfile" ,libvorbis)
281 ("wayland" ,wayland)
282 ("webp" ,libwebp)
283 ("x11" ,libx11)
284 ("xcomposite" ,libxcomposite)
285 ("xext" ,libxext)
286 ("xproto" ,xorgproto)
287 ("zlib" ,zlib)))
288 (propagated-inputs
289 `(("flux" ,flux)))
290 (synopsis "DFB Graphics Library")
291 (description "DirectFB is a graphics library which was designed with embedded
292 systems in mind. It offers maximum hardware accelerated performance at a
293 minimum of resource usage and overhead.")
294 (home-page "https://github.com/deniskropp/DirectFB")
295 (license license:lgpl2.1+)))
296
297 (define-public flux
298 (package
299 (name "flux")
300 (version "1.4.4")
301 (source
302 (origin
303 (method git-fetch)
304 (uri
305 (git-reference
306 (url "https://github.com/deniskropp/flux")
307 (commit "e45758a")))
308 (file-name (git-file-name name version))
309 (sha256
310 (base32 "11f3ypg0sdq5kj69zgz6kih1yrzgm48r16spyvzwvlswng147410"))))
311 (build-system gnu-build-system)
312 (native-inputs
313 `(("autoconf" ,autoconf)
314 ("automake" ,automake)
315 ("libtool" ,libtool)
316 ("pkg-config" ,pkg-config)))
317 (synopsis "Interface description language")
318 (description "Flux is an interface description language used by DirectFB.
319 Fluxcomp compiles .flux files to .cpp or .c files.")
320 (home-page "http://www.directfb.org/")
321 (license license:lgpl2.1+))) ; Same as DirectFB
322
323 (define-public fox
324 (package
325 (name "fox")
326 (version "1.6.57")
327 (source
328 (origin
329 (method url-fetch)
330 (uri
331 (string-append "https://fox-toolkit.org/ftp/fox-" version ".tar.gz"))
332 (sha256
333 (base32 "08w98m6wjadraw1pi13igzagly4b2nfa57kdqdnkjfhgkvg1bvv5"))))
334 (build-system gnu-build-system)
335 (arguments
336 `(#:phases
337 (modify-phases %standard-phases
338 (add-after 'unpack 'patch
339 (lambda _
340 (substitute* "configure"
341 (("-I/usr/include/freetype2")
342 (string-append "-I"
343 (string-append
344 (assoc-ref %build-inputs "freetype")
345 "/include/freetype2"))))
346 #t)))))
347 (native-inputs
348 `(("doxygen" ,doxygen)))
349 (inputs
350 `(("bzip2" ,lbzip2)
351 ("freetype" ,freetype)
352 ("gl" ,mesa)
353 ("glu" ,glu)
354 ("jpeg" ,libjpeg-turbo)
355 ("png" ,libpng)
356 ("tiff" ,libtiff)
357 ("x11" ,libx11)
358 ("xcursor" ,libxcursor)
359 ("xext" ,libxext)
360 ("xfixes" ,libxfixes)
361 ("xft" ,libxft)
362 ("xinput" ,libxi)
363 ("xrandr" ,libxrandr)
364 ("xrender" ,libxrender)
365 ("xshm" ,libxshmfence)
366 ("zlib" ,zlib)))
367 (synopsis "Widget Toolkit for building GUI")
368 (description"FOX (Free Objects for X) is a C++ based Toolkit for developing
369 Graphical User Interfaces easily and effectively. It offers a wide, and
370 growing, collection of Controls, and provides state of the art facilities such
371 as drag and drop, selection, as well as OpenGL widgets for 3D graphical
372 manipulation. FOX also implements icons, images, and user-convenience features
373 such as status line help, and tooltips. Tooltips may even be used for 3D
374 objects!")
375 (home-page "http://www.fox-toolkit.org")
376 (license license:lgpl2.1+)))
377
378 (define-public autotrace
379 (let ((commit "travis-20190624.59")
380 (version-base "0.40.0"))
381 (package
382 (name "autotrace")
383 (version (string-append version-base "-"
384 (if (string-prefix? "travis-" commit)
385 (string-drop commit 7)
386 commit)))
387 (source (origin
388 (method git-fetch)
389 (uri (git-reference
390 (url "https://github.com/autotrace/autotrace")
391 (commit commit)))
392 (file-name (git-file-name name version))
393 (sha256
394 (base32
395 "0mk4yavy42dj0pszr1ggnggpvmzs4ds46caa9wr55cqsypn7bq6s"))))
396 (build-system gnu-build-system)
397 (arguments
398 `(#:phases (modify-phases %standard-phases
399 ;; See: https://github.com/autotrace/autotrace/issues/27.
400 (add-after 'unpack 'include-spline.h-header
401 (lambda _
402 (substitute* "Makefile.am"
403 ((".*src/types.h.*" all)
404 (string-append all "\t\tsrc/spline.h \\\n")))
405 #t))
406 ;; See: https://github.com/autotrace/autotrace/issues/26.
407 (replace 'check
408 (lambda _
409 (invoke "sh" "tests/runtests.sh"))))))
410 (native-inputs
411 `(("which" ,which)
412 ("pkg-config" ,pkg-config)
413 ("autoconf" ,autoconf)
414 ("automake" ,automake)
415 ("intltool" ,intltool)
416 ("libtool" ,libtool)
417 ("gettext" ,gettext-minimal)))
418 (inputs
419 `(("glib" ,glib)
420 ("libjpeg" ,libjpeg-turbo)
421 ("libpng" ,libpng)
422 ("imagemagick" ,imagemagick)
423 ("pstoedit" ,pstoedit)))
424 (home-page "https://github.com/autotrace/autotrace")
425 (synopsis "Bitmap to vector graphics converter")
426 (description "AutoTrace is a utility for converting bitmap into vector
427 graphics. It can trace outlines and midlines, effect color reduction or
428 despeckling and has support for many input and output formats. It can be used
429 with the @command{autotrace} utility or as a C library, @code{libautotrace}.")
430 (license (list license:gpl2+ ;for the utility itself
431 license:lgpl2.1+))))) ;for use as a library
432
433 (define-public embree
434 (package
435 (name "embree")
436 (version "3.12.1")
437 (source (origin
438 (method git-fetch)
439 (uri (git-reference
440 (url "https://github.com/embree/embree")
441 (commit (string-append "v" version))))
442 (file-name (git-file-name name version))
443 (sha256
444 (base32
445 "0aznd16n7h8g3f6jcahzfp1dq4r7wayqvn03wsaskiq2dvsi4srd"))))
446 (build-system cmake-build-system)
447 (arguments
448 `(#:tests? #f ; no tests (apparently)
449 #:configure-flags
450 (list
451 "-DEMBREE_ISPC_SUPPORT=OFF")))
452 (inputs
453 `(("tbb" ,tbb)
454 ("glfw" ,glfw)))
455 (home-page "https://www.embree.org/")
456 (synopsis "High performance ray tracing kernels")
457 (description
458 "Embree is a collection of high-performance ray tracing kernels.
459 Embree is meant to increase performance of photo-realistic rendering
460 applications.")
461 (license license:asl2.0)))
462
463 (define-public blender
464 (package
465 (name "blender")
466 (version "2.91.0")
467 (source (origin
468 (method url-fetch)
469 (uri (string-append "https://download.blender.org/source/"
470 "blender-" version ".tar.xz"))
471 (sha256
472 (base32
473 "0x396lgmk0dq9115yrc36s8zwxzmjr490sr5n2y6w27y17yllyjm"))))
474 (build-system cmake-build-system)
475 (arguments
476 (let ((python-version (version-major+minor (package-version python))))
477 `(;; Test files are very large and not included in the release tarball.
478 #:tests? #f
479 #:configure-flags
480 (list "-DWITH_CODEC_FFMPEG=ON"
481 "-DWITH_CODEC_SNDFILE=ON"
482 "-DWITH_CYCLES=ON"
483 "-DWITH_DOC_MANPAGE=ON"
484 "-DWITH_FFTW3=ON"
485 "-DWITH_IMAGE_OPENJPEG=ON"
486 "-DWITH_INPUT_NDOF=ON"
487 "-DWITH_INSTALL_PORTABLE=OFF"
488 "-DWITH_JACK=ON"
489 "-DWITH_MOD_OCEANSIM=ON"
490 "-DWITH_OPENSUBDIV=ON"
491 "-DWITH_PYTHON_INSTALL=OFF"
492 (string-append "-DPYTHON_LIBRARY=python" ,python-version)
493 (string-append "-DPYTHON_LIBPATH=" (assoc-ref %build-inputs "python")
494 "/lib")
495 (string-append "-DPYTHON_INCLUDE_DIR=" (assoc-ref %build-inputs "python")
496 "/include/python" ,python-version)
497 (string-append "-DPYTHON_VERSION=" ,python-version)
498 (string-append "-DPYTHON_NUMPY_PATH="
499 (assoc-ref %build-inputs "python-numpy")
500 "/lib/python" ,python-version "/site-packages/"))
501 #:phases
502 (modify-phases %standard-phases
503 ;; XXX This file doesn't exist in the Git sources but will probably
504 ;; exist in the eventual 2.80 source tarball.
505 (add-after 'unpack 'fix-broken-import
506 (lambda _
507 (substitute* "release/scripts/addons/io_scene_fbx/json2fbx.py"
508 (("import encode_bin") "from . import encode_bin"))
509 #t))
510 (add-after 'set-paths 'add-ilmbase-include-path
511 (lambda* (#:key inputs #:allow-other-keys)
512 ;; OpenEXR propagates ilmbase, but its include files do not appear
513 ;; in the CPATH, so we need to add "$ilmbase/include/OpenEXR/" to
514 ;; the CPATH to satisfy the dependency on "half.h".
515 (setenv "CPATH"
516 (string-append (assoc-ref inputs "ilmbase")
517 "/include/OpenEXR"
518 ":" (or (getenv "CPATH") "")))
519 #t))))))
520 (inputs
521 `(("boost" ,boost)
522 ("jemalloc" ,jemalloc)
523 ("libx11" ,libx11)
524 ("libxi" ,libxi)
525 ("libxrender" ,libxrender)
526 ("opencolorio" ,opencolorio)
527 ("openimageio" ,openimageio)
528 ("openexr" ,openexr)
529 ("opensubdiv" ,opensubdiv)
530 ("ilmbase" ,ilmbase)
531 ("openjpeg" ,openjpeg)
532 ("libjpeg" ,libjpeg-turbo)
533 ("libpng" ,libpng)
534 ("libtiff" ,libtiff)
535 ("ffmpeg" ,ffmpeg)
536 ("fftw" ,fftw)
537 ("jack" ,jack-1)
538 ("libsndfile" ,libsndfile)
539 ("freetype" ,freetype)
540 ("glew" ,glew)
541 ("openal" ,openal)
542 ("pugixml" ,pugixml)
543 ("python" ,python)
544 ("python-numpy" ,python-numpy)
545 ("tbb" ,tbb)
546 ("zlib" ,zlib)
547 ("embree" ,embree)))
548 (home-page "https://blender.org/")
549 (synopsis "3D graphics creation suite")
550 (description
551 "Blender is a 3D graphics creation suite. It supports the entirety of
552 the 3D pipeline—modeling, rigging, animation, simulation, rendering,
553 compositing and motion tracking, even video editing and game creation. The
554 application can be customized via its API for Python scripting.")
555 (license license:gpl2+)))
556
557 (define-public blender-2.79
558 (package
559 (name "blender")
560 (version "2.79b")
561 (source (origin
562 (method url-fetch)
563 (uri (string-append "https://download.blender.org/source/"
564 "blender-" version ".tar.gz"))
565 (sha256
566 (base32
567 "1g4kcdqmf67srzhi3hkdnr4z1ph4h9sza1pahz38mrj998q4r52c"))
568 (patches (search-patches "blender-2.79-newer-ffmpeg.patch"
569 "blender-2.79-oiio2.patch"
570 ;; The following patches may be
571 ;; needed when the default GCC is
572 ;; updated:
573 ;; "blender-2.79-gcc8.patch"
574 ;; "blender-2.79-gcc9.patch"
575 "blender-2.79-python-3.7-fix.patch"
576 "blender-2.79-python-3.8-fix.patch"))))
577 (build-system cmake-build-system)
578 (arguments
579 (let ((python-version (version-major+minor (package-version python))))
580 `(;; Test files are very large and not included in the release tarball.
581 #:tests? #f
582 #:configure-flags
583 (list "-DWITH_CODEC_FFMPEG=ON"
584 "-DWITH_CODEC_SNDFILE=ON"
585 "-DWITH_CYCLES=ON"
586 "-DWITH_DOC_MANPAGE=ON"
587 "-DWITH_FFTW3=ON"
588 "-DWITH_GAMEENGINE=ON"
589 "-DWITH_IMAGE_OPENJPEG=ON"
590 "-DWITH_INPUT_NDOF=ON"
591 "-DWITH_INSTALL_PORTABLE=OFF"
592 "-DWITH_JACK=ON"
593 "-DWITH_MOD_OCEANSIM=ON"
594 "-DWITH_PLAYER=ON"
595 "-DWITH_PYTHON_INSTALL=OFF"
596 "-DWITH_PYTHON_INSTALL=OFF"
597 "-DWITH_SYSTEM_OPENJPEG=ON"
598 (string-append "-DPYTHON_LIBRARY=python" ,python-version)
599 (string-append "-DPYTHON_LIBPATH=" (assoc-ref %build-inputs "python")
600 "/lib")
601 (string-append "-DPYTHON_INCLUDE_DIR=" (assoc-ref %build-inputs "python")
602 "/include/python" ,python-version)
603 (string-append "-DPYTHON_VERSION=" ,python-version))
604 #:phases
605 (modify-phases %standard-phases
606 (add-after 'unpack 'fix-broken-import
607 (lambda _
608 (substitute* "release/scripts/addons/io_scene_fbx/json2fbx.py"
609 (("import encode_bin") "from . import encode_bin"))
610 #t))
611 (add-after 'set-paths 'add-ilmbase-include-path
612 (lambda* (#:key inputs #:allow-other-keys)
613 ;; OpenEXR propagates ilmbase, but its include files do not appear
614 ;; in the CPATH, so we need to add "$ilmbase/include/OpenEXR/" to
615 ;; the CPATH to satisfy the dependency on "half.h".
616 (setenv "CPATH"
617 (string-append (assoc-ref inputs "ilmbase")
618 "/include/OpenEXR"
619 ":" (or (getenv "CPATH") "")))
620 #t))))))
621 (inputs
622 `(("boost" ,boost)
623 ("jemalloc" ,jemalloc)
624 ("libx11" ,libx11)
625 ("opencolorio" ,opencolorio)
626 ("openimageio" ,openimageio)
627 ("openexr" ,openexr)
628 ("ilmbase" ,ilmbase)
629 ("openjpeg" ,openjpeg)
630 ("libjpeg" ,libjpeg-turbo)
631 ("libpng" ,libpng)
632 ("libtiff" ,libtiff)
633 ("ffmpeg" ,ffmpeg)
634 ("fftw" ,fftw)
635 ("jack" ,jack-1)
636 ("libsndfile" ,libsndfile)
637 ("freetype" ,freetype)
638 ("glew" ,glew)
639 ("openal" ,openal)
640 ("pugixml" ,pugixml)
641 ("python" ,python)
642 ("zlib" ,zlib)))
643 (home-page "https://blender.org/")
644 (synopsis "3D graphics creation suite")
645 (description
646 "Blender is a 3D graphics creation suite. It supports the entirety of
647 the 3D pipeline—modeling, rigging, animation, simulation, rendering,
648 compositing and motion tracking, even video editing and game creation. The
649 application can be customized via its API for Python scripting.
650
651 NOTE: This older version of Blender is the last release that does not require
652 OpenGL 3. It is retained for use with older computers.")
653 (license license:gpl2+)))
654
655 (define-public goxel
656 (package
657 (name "goxel")
658 (version "0.10.7")
659 (source (origin
660 (method git-fetch)
661 (uri (git-reference
662 (url "https://github.com/guillaumechereau/goxel")
663 (commit (string-append "v" version))))
664 (file-name (git-file-name name version))
665 (sha256
666 (base32
667 "1v6m6nhl1if8ik5bmblhq46bip6y2qz18a04s8a9awb4yh9ls039"))))
668 (build-system gnu-build-system)
669 (arguments
670 '(#:tests? #f
671 #:phases (modify-phases %standard-phases (delete 'configure))
672 #:make-flags (list (string-append "PREFIX=" (assoc-ref %outputs "out"))
673 "release")))
674 (native-inputs
675 `(("pkg-config" ,pkg-config)))
676 (inputs
677 `(("gtk3" ,gtk+)
678 ("glfw" ,glfw)
679 ("scons" ,scons)))
680 (home-page "https://goxel.xyz/")
681 (synopsis "Voxel editor")
682 (description
683 "Goxel is a voxel editor that features unlimited scene size, unlimited
684 history buffer, 24-bit RGB colors, layers, procedural rendering, ray tracing,
685 and export to various formats including the format used by Magicavoxel.")
686 (license license:gpl3+)))
687
688 (define-public assimp
689 (package
690 (name "assimp")
691 (version "4.1.0")
692 (source (origin
693 (method git-fetch)
694 (uri (git-reference
695 (url "https://github.com/assimp/assimp")
696 (commit (string-append "v" version))))
697 (file-name (git-file-name name version))
698 (sha256
699 (base32
700 "1rhyqfhzifdj7yibyanph3rh13ykw3i98dnn8mz65j780472hw28"))))
701 (build-system cmake-build-system)
702 (inputs
703 `(("zlib" ,zlib)))
704 (home-page "http://www.assimp.org/")
705 (synopsis "Asset import library")
706 (description
707 "The Open Asset Import Library loads more than 40 3D file formats into
708 one unified data structure. Additionally, assimp features various mesh post
709 processing tools: normals and tangent space generation, triangulation, vertex
710 cache locality optimization, removal of degenerate primitives and duplicate
711 vertices, sorting by primitive type, merging of redundant materials and many
712 more.")
713 (license license:bsd-3)))
714
715 (define-public cgal
716 (package
717 (name "cgal")
718 (version "4.14.2")
719 (source (origin
720 (method url-fetch)
721 (uri (string-append
722 "https://github.com/CGAL/cgal/releases/download/releases/"
723 "CGAL-" version "/CGAL-" version ".tar.xz"))
724 (sha256
725 (base32
726 "08lrp3hfwdypggz4138bnkh6bjxn441zg2y9xnq5mrjfc5ini6w1"))))
727 (build-system cmake-build-system)
728 (arguments
729 '(#:tests? #f)) ; no test target
730 (inputs
731 `(("mpfr" ,mpfr)
732 ("gmp" ,gmp)
733 ("boost" ,boost)))
734 (home-page "https://www.cgal.org/")
735 (synopsis "Computational geometry algorithms library")
736 (description
737 "CGAL provides easy access to efficient and reliable geometric algorithms
738 in the form of a C++ library. CGAL is used in various areas needing geometric
739 computation, such as: computer graphics, scientific visualization, computer
740 aided design and modeling, geographic information systems, molecular biology,
741 medical imaging, robotics and motion planning, mesh generation, numerical
742 methods, etc. It provides data structures and algorithms such as
743 triangulations, Voronoi diagrams, polygons, polyhedra, mesh generation, and
744 many more.")
745
746 ;; The 'LICENSE' file explains that a subset is available under more
747 ;; permissive licenses.
748 (license license:gpl3+)))
749
750 (define-public ilmbase
751 (package
752 (name "ilmbase")
753 (version "2.5.2")
754 (source (origin
755 (method git-fetch)
756 (uri (git-reference
757 (url "https://github.com/openexr/openexr")
758 (commit (string-append "v" version))))
759 (file-name (git-file-name "ilmbase" version))
760 (sha256
761 (base32
762 "1vf8bqld2bpcdi99jbr043y6vp01cp3fvbiasrn66xn91mf6imbn"))
763 (patches (search-patches "ilmbase-fix-tests.patch"))))
764 (build-system cmake-build-system)
765 (arguments
766 `(#:phases (modify-phases %standard-phases
767 (add-after 'unpack 'change-directory
768 (lambda _
769 (chdir "IlmBase")
770 #t)))))
771 (home-page "https://www.openexr.com/")
772 (synopsis "Utility C++ libraries for threads, maths, and exceptions")
773 (description
774 "IlmBase provides several utility libraries for C++. Half is a class
775 that encapsulates ILM's 16-bit floating-point format. IlmThread is a thread
776 abstraction. Imath implements 2D and 3D vectors, 3x3 and 4x4 matrices,
777 quaternions and other useful 2D and 3D math functions. Iex is an
778 exception-handling library.")
779 (license license:bsd-3)))
780
781 (define-public lib2geom
782 ;; Use the latest master commit, as the 1.0 release suffer build problems.
783 (let ((revision "3")
784 (commit "17e0d21f0afc8489656f9184bff7ad024a42394a"))
785 (package
786 (name "lib2geom")
787 (version (git-version "1.0" revision commit))
788 (source (origin
789 (method git-fetch)
790 (uri (git-reference
791 (url "https://gitlab.com/inkscape/lib2geom.git")
792 (commit commit)))
793 (file-name (git-file-name name version))
794 (sha256
795 (base32
796 "0waskrmdrrdjw8pr5cvlkrxywgf376viggpc2jzdqxxpy2k78fpr"))
797 (patches
798 ;; Patch submitted to upstream (see:
799 ;; https://gitlab.com/inkscape/lib2geom/-/merge_requests/32).
800 (search-patches "lib2geom-fix-tests.patch"))
801 (modules '((guix build utils)))
802 (snippet
803 '(begin
804 ;; Fix py2geom module initialization (see:
805 ;; https://gitlab.com/inkscape/lib2geom/merge_requests/18).
806 (substitute* "src/py2geom/__init__.py"
807 (("_py2geom") "py2geom._py2geom"))
808 #t))))
809 (build-system cmake-build-system)
810 (arguments
811 `(#:imported-modules ((guix build python-build-system)
812 ,@%cmake-build-system-modules)
813 #:configure-flags '("-D2GEOM_BUILD_SHARED=ON"
814 "-D2GEOM_BOOST_PYTHON=ON"
815 ;; Compiling the Cython bindings fail (see:
816 ;; https://gitlab.com/inkscape/lib2geom/issues/21).
817 "-D2GEOM_CYTHON_BINDINGS=OFF")
818 #:phases
819 (modify-phases %standard-phases
820 (add-after 'unpack 'patch-python-lib-install-path
821 (lambda* (#:key inputs outputs #:allow-other-keys)
822 (let* ((python-version (@ (guix build python-build-system)
823 python-version))
824 (python-maj-min-version (python-version
825 (assoc-ref inputs "python")))
826 (site-package (string-append
827 (assoc-ref outputs "out")
828 "/lib/python" python-maj-min-version
829 "/site-packages")))
830 (substitute* '("src/cython/CMakeLists.txt"
831 "src/py2geom/CMakeLists.txt")
832 (("PYTHON_LIB_INSTALL \"[^\"]*\"")
833 (format #f "PYTHON_LIB_INSTALL ~s" site-package))))
834 #t)))))
835 (native-inputs `(("python" ,python-wrapper)
836 ("googletest" ,googletest)
837 ("pkg-config" ,pkg-config)))
838 (inputs `(("cairo" ,cairo)
839 ("pycairo" ,python-pycairo)
840 ("double-conversion" ,double-conversion)
841 ("glib" ,glib)
842 ("gsl" ,gsl)))
843 (propagated-inputs
844 `(("boost" ,boost))) ;referred to in 2geom/pathvector.h.
845 (home-page "https://gitlab.com/inkscape/lib2geom/")
846 (synopsis "C++ 2D graphics library")
847 (description "2geom is a C++ library of mathematics for paths, curves,
848 and other geometric calculations. Designed for vector graphics, it tackles
849 Bézier curves, conic sections, paths, intersections, transformations, and
850 basic geometries.")
851 ;; Because the library is linked with the GNU Scientific Library
852 ;; (GPLv3+), the combined work must be licensed as GPLv3+ (see:
853 ;; https://gitlab.com/inkscape/inkscape/issues/784).
854 (license license:gpl3+))))
855
856 (define-public pstoedit
857 (package
858 (name "pstoedit")
859 (version "3.75")
860 (source (origin
861 (method url-fetch)
862 (uri (string-append "mirror://sourceforge/pstoedit/pstoedit/"
863 version "/pstoedit-" version ".tar.gz"))
864 (sha256
865 (base32
866 "1kv46g2wsvsvcngkavxl5gnw3l6g5xqnh4kmyx4b39a01d8xiddp"))))
867 (build-system gnu-build-system)
868 (native-inputs
869 `(("pkg-config" ,pkg-config)))
870 (inputs
871 `(("ghostscript" ,ghostscript)
872 ("imagemagick" ,imagemagick)
873 ("libplot" ,plotutils)
874 ("libjpeg" ,libjpeg-turbo)
875 ("zlib" ,zlib))) ;else libp2edrvmagick++.so fails to link
876 (home-page "http://www.pstoedit.net/")
877 (synopsis "Converter for PostScript and PDF graphics")
878 (description "The @code{pstoedit} utility allows translating graphics
879 in the PostScript or PDF (Portable Document Format) formats to various
880 other vector formats such as:
881 @itemize
882 @item Tgif (.obj)
883 @item gnuplot
884 @item xfig (.fig)
885 @item Flattened PostScript
886 @item DXF, a CAD (Computed-Aided Design) exchange format
887 @item PIC (for troff/groff)
888 @item MetaPost (for usage with TeX/LaTeX)
889 @item LaTeX2e picture
890 @item GNU Metafile (for use with plotutils/libplot)
891 @item Any format supported by ImageMagick
892 @end itemize")
893 (license license:gpl2+)))
894
895 (define-public dear-imgui
896 (package
897 (name "dear-imgui")
898 (version "1.79")
899 (source
900 (origin
901 (method git-fetch)
902 (uri (git-reference
903 (url "https://github.com/ocornut/imgui")
904 (commit (string-append "v" version))))
905 (file-name (git-file-name name version))
906 (sha256
907 (base32 "0x26igynxp6rlpp2wfc5dr7x6yh583ajb7p23pgycn9vqikn318q"))))
908 (build-system gnu-build-system)
909 (arguments
910 `(#:make-flags
911 (list (string-append "CC=" ,(cc-for-target))
912 (string-append "PREFIX=" (assoc-ref %outputs "out"))
913 (string-append "VERSION=" ,version))
914 #:tests? #f ; no test suite
915 #:phases
916 (modify-phases %standard-phases
917 (add-after 'unpack 'unpack-debian-files
918 (lambda* (#:key inputs #:allow-other-keys)
919 (invoke "tar" "xvf" (assoc-ref inputs "debian-files"))
920 (apply invoke "patch" "-Np1" "-i"
921 (find-files "debian/patches" "\\.patch$"))
922 (substitute* "Makefile"
923 (("<stb/") "<") ; Guix doesn't use this subdirectory
924 ;; Don't build or install the static library.
925 (("^all: .*") "all: $(SHLIB) $(PCFILE)"))
926 (substitute* (list "imgui.pc.in"
927 "Makefile")
928 ;; Don't link against a non-existent library.
929 (("-lstb") ""))
930 #t))
931 (delete 'configure) ; no configure script
932 (replace 'install
933 ;; The default ‘install’ target installs the static library. Don't.
934 (lambda* (#:key make-flags #:allow-other-keys)
935 (apply invoke "make" "install-shared" "install-header"
936 make-flags))))))
937 (native-inputs
938 `(("debian-files"
939 ;; Upstream doesn't provide a build system. Use Debian's.
940 ,(origin
941 (method url-fetch)
942 (uri (string-append "mirror://debian/pool/main/i/imgui/imgui_"
943 version "+ds-1.debian.tar.xz"))
944 (sha256
945 (base32 "1xhk34pzpha6k5l2j150capq66y8czhmsi04ib09wvb34ahqxpby"))))
946 ("pkg-config" ,pkg-config)))
947 (inputs
948 `(("freetype" ,freetype)
949 ("stb-rect-pack" ,stb-rect-pack)
950 ("stb-truetype" ,stb-truetype)))
951 (home-page "https://github.com/ocornut/imgui")
952 (synopsis "Immediate-mode C++ GUI library with minimal dependencies")
953 (description
954 "Dear ImGui is a @acronym{GUI, graphical user interface} library for C++.
955 It creates optimized vertex buffers that you can render anytime in your
956 3D-pipeline-enabled application. It's portable, renderer-agnostic, and
957 self-contained, without external dependencies.
958
959 Dear ImGui is aimed at content creation, visualization, and debugging tools as
960 opposed to average end-user interfaces. Hence it favors simplicity and
961 productivity but lacks certain features often found in higher-level libraries.
962 It is particularly suited to integration in game engine tooling, real-time 3D
963 applications, full-screen applications, and embedded platforms without standard
964 operating system features.")
965 (license license:expat))) ; some examples/ use the zlib licence
966
967 (define-public ogre
968 (package
969 (name "ogre")
970 (version "1.12.9")
971 (source
972 (origin
973 (method git-fetch)
974 (uri (git-reference
975 (url "https://github.com/OGRECave/ogre")
976 (commit (string-append "v" version))))
977 (file-name (git-file-name name version))
978 (sha256
979 (base32 "0b0pwh31nykrfhka6jqwclfx1pxzhj11vkl91951d63kwr5bbzms"))))
980 (build-system cmake-build-system)
981 (arguments
982 '(#:phases
983 (modify-phases %standard-phases
984 (add-before 'configure 'unpack-dear-imgui
985 (lambda* (#:key inputs #:allow-other-keys)
986 (copy-recursively (assoc-ref inputs "dear-imgui-source")
987 "../dear-imgui-source")
988 #t))
989 (add-before 'configure 'pre-configure
990 ;; CMakeLists.txt forces a CMAKE_INSTALL_RPATH value. As
991 ;; a consequence, we cannot suggest ours in configure flags. Fix
992 ;; it.
993 (lambda* (#:key inputs outputs #:allow-other-keys)
994 (substitute* "CMakeLists.txt"
995 (("set\\(CMAKE_INSTALL_RPATH .*") ""))
996 #t)))
997 #:configure-flags
998 (let* ((out (assoc-ref %outputs "out"))
999 (runpath
1000 (string-join (list (string-append out "/lib")
1001 (string-append out "/lib/OGRE"))
1002 ";")))
1003 (list (string-append "-DCMAKE_INSTALL_RPATH=" runpath)
1004 "-DIMGUI_DIR=../dear-imgui-source"
1005 "-DOGRE_BUILD_DEPENDENCIES=OFF"
1006 "-DOGRE_BUILD_TESTS=TRUE"
1007 "-DOGRE_INSTALL_DOCS=TRUE"
1008 "-DOGRE_INSTALL_SAMPLES=TRUE"
1009 "-DOGRE_INSTALL_SAMPLES_SOURCE=TRUE"))))
1010 (native-inputs
1011 `(("boost" ,boost)
1012 ("dear-imgui-source" ,(package-source dear-imgui))
1013 ("doxygen" ,doxygen)
1014 ("googletest" ,googletest-1.8)
1015 ("pkg-config" ,pkg-config)))
1016 (inputs
1017 `(("font-dejavu" ,font-dejavu)
1018 ("freeimage" ,freeimage)
1019 ("freetype" ,freetype)
1020 ("glu" ,glu)
1021 ("libxaw" ,libxaw)
1022 ("libxrandr" ,libxrandr)
1023 ("pugixml" ,pugixml)
1024 ("sdl2" ,sdl2)
1025 ("tinyxml" ,tinyxml)
1026 ("zziplib" ,zziplib)))
1027 (synopsis "Scene-oriented, flexible 3D engine written in C++")
1028 (description
1029 "OGRE (Object-Oriented Graphics Rendering Engine) is a scene-oriented,
1030 flexible 3D engine written in C++ designed to make it easier and more intuitive
1031 for developers to produce applications utilising hardware-accelerated 3D
1032 graphics.")
1033 (home-page "https://www.ogre3d.org/")
1034 (license license:expat)))
1035
1036 (define-public openexr
1037 (package
1038 (name "openexr")
1039 (version (package-version ilmbase))
1040 (source (origin
1041 (inherit (package-source ilmbase))
1042 (file-name (git-file-name "openexr" version))
1043 (modules '((guix build utils)))
1044 (snippet
1045 '(begin
1046 (substitute* (find-files "OpenEXR" "tmpDir\\.h")
1047 (("\"/var/tmp/\"")
1048 "\"/tmp/\""))
1049 #t))))
1050 (build-system cmake-build-system)
1051 (arguments
1052 `(#:phases
1053 (modify-phases %standard-phases
1054 (add-after 'unpack 'change-directory
1055 (lambda _
1056 (chdir "OpenEXR")
1057 #t))
1058 (add-after 'change-directory 'increase-test-timeout
1059 (lambda _
1060 ;; On armhf-linux, we need to override the CTest default
1061 ;; timeout of 1500 seconds for the OpenEXR.IlmImf test.
1062 (substitute* "IlmImfTest/CMakeLists.txt"
1063 (("add_test\\(NAME OpenEXR\\.IlmImf.*" all)
1064 (string-append
1065 all
1066 "set_tests_properties(OpenEXR.IlmImf PROPERTIES TIMEOUT 2000)")))
1067 #t))
1068 ,@(if (not (target-64bit?))
1069 `((add-after 'change-directory 'disable-broken-test
1070 ;; This test fails on i686. Upstream developers suggest that
1071 ;; this test is broken on i686 and can be safely disabled:
1072 ;; https://github.com/openexr/openexr/issues/67#issuecomment-21169748
1073 (lambda _
1074 (substitute* "IlmImfTest/main.cpp"
1075 ((".*testOptimizedInterleavePatterns.*") ""))
1076 #t)))
1077 '()))))
1078 (native-inputs
1079 `(("pkg-config" ,pkg-config)))
1080 (propagated-inputs
1081 `(("ilmbase" ,ilmbase) ;used in public headers
1082 ("zlib" ,zlib))) ;OpenEXR.pc reads "-lz"
1083 (home-page "https://www.openexr.com/")
1084 (synopsis "High-dynamic range file format library")
1085 (description
1086 "OpenEXR is a high dynamic-range (HDR) image file format developed for
1087 use in computer imaging applications. The IlmImf C++ libraries support
1088 storage of the \"EXR\" file format for storing 16-bit floating-point images.")
1089 (license license:bsd-3)))
1090
1091 (define-public openimageio
1092 (package
1093 (name "openimageio")
1094 (version "2.2.10.1")
1095 (source (origin
1096 (method git-fetch)
1097 (uri (git-reference
1098 (url "https://github.com/OpenImageIO/oiio")
1099 (commit (string-append "Release-" version))))
1100 (file-name (git-file-name name version))
1101 (sha256
1102 (base32
1103 "0wzh5n527l7ia1754cf9xmbvv4ya6hj34dy6cbq9xk9372h8gd9q"))))
1104 (build-system cmake-build-system)
1105 ;; FIXME: To run all tests successfully, test image sets from multiple
1106 ;; third party sources have to be present. For details see
1107 ;; <https://github.com/OpenImageIO/oiio/blob/master/INSTALL.md>
1108 (arguments
1109 `(#:tests? #f
1110 #:configure-flags (list "-DUSE_EXTERNAL_PUGIXML=1")))
1111 (native-inputs
1112 `(("pkg-config" ,pkg-config)))
1113 (inputs
1114 `(("boost" ,boost)
1115 ("fmt" ,fmt)
1116 ("libpng" ,libpng)
1117 ("libjpeg" ,libjpeg-turbo)
1118 ("libtiff" ,libtiff)
1119 ("giflib" ,giflib)
1120 ("openexr" ,openexr)
1121 ("ilmbase" ,ilmbase)
1122 ("pugixml" ,pugixml)
1123 ("python" ,python-wrapper)
1124 ("pybind11" ,pybind11)
1125 ("robin-map" ,robin-map)
1126 ("zlib" ,zlib)))
1127 (synopsis "C++ library for reading and writing images")
1128 (description
1129 "OpenImageIO is a library for reading and writing images, and a bunch of
1130 related classes, utilities, and applications. There is a particular emphasis
1131 on formats and functionality used in professional, large-scale animation and
1132 visual effects work for film.")
1133 (home-page "https://www.openimageio.org")
1134 (license license:bsd-3)))
1135
1136 (define-public openscenegraph
1137 (package
1138 (name "openscenegraph")
1139 (version "3.6.5")
1140 (source
1141 (origin
1142 (method git-fetch)
1143 (uri (git-reference
1144 (url "https://github.com/openscenegraph/OpenSceneGraph")
1145 (commit (string-append "OpenSceneGraph-" version))))
1146 (sha256
1147 (base32 "00i14h82qg3xzcyd8p02wrarnmby3aiwmz0z43l50byc9f8i05n1"))
1148 (file-name (git-file-name name version))))
1149 (properties
1150 `((upstream-name . "OpenSceneGraph")))
1151 (build-system cmake-build-system)
1152 (arguments
1153 `(#:tests? #f ; no test target available
1154 ;; Without this flag, 'rd' will be added to the name of the
1155 ;; library binaries and break linking with other programs.
1156 #:build-type "Release"
1157 #:configure-flags
1158 (list (string-append "-DCMAKE_INSTALL_RPATH="
1159 (assoc-ref %outputs "out") "/lib:"
1160 (assoc-ref %outputs "out") "/lib64"))))
1161 (native-inputs
1162 `(("pkg-config" ,pkg-config)
1163 ("unzip" ,unzip)))
1164 (inputs
1165 `(("giflib" ,giflib)
1166 ("libjpeg" ,libjpeg-turbo) ; required for the JPEG texture plugin.
1167 ("jasper" ,jasper)
1168 ("librsvg" ,librsvg)
1169 ("libxrandr" ,libxrandr)
1170 ("ffmpeg" ,ffmpeg)
1171 ("mesa" ,mesa)))
1172 (synopsis "High-performance real-time graphics toolkit")
1173 (description
1174 "The OpenSceneGraph is a high-performance 3D graphics toolkit
1175 used by application developers in fields such as visual simulation, games,
1176 virtual reality, scientific visualization and modeling.")
1177 (home-page "http://www.openscenegraph.org")
1178 ;; The 'LICENSE' file explains that the source is licensed under
1179 ;; LGPL 2.1, but with 4 exceptions. This version is called OSGPL.
1180 (license license:lgpl2.1)))
1181
1182 ;; We need this for simgear
1183 (define-public openscenegraph-3.4
1184 (package (inherit openscenegraph)
1185 (name "openscenegraph")
1186 (version "3.4.1")
1187 (source
1188 (origin
1189 (method git-fetch)
1190 (uri (git-reference
1191 (url "https://github.com/openscenegraph/OpenSceneGraph")
1192 (commit (string-append "OpenSceneGraph-" version))))
1193 (file-name (git-file-name name version))
1194 (sha256
1195 (base32
1196 "1fbzg1ihjpxk6smlq80p3h3ggllbr16ihd2fxpfwzam8yr8yxip9"))))
1197 (arguments
1198 (substitute-keyword-arguments (package-arguments openscenegraph)
1199 ((#:configure-flags flags)
1200 `(cons
1201 ;; The jpeg plugin requires conversion between integers and booleans
1202 "-DCMAKE_CXX_FLAGS=-fpermissive"
1203 ,flags))))
1204 (inputs
1205 `(("libjpeg" ,libjpeg-turbo)
1206 ,@(package-inputs openscenegraph)))))
1207
1208
1209 (define-public openmw-openscenegraph
1210 ;; OpenMW prefers its own fork of openscenegraph:
1211 ;; https://wiki.openmw.org/index.php?title=Development_Environment_Setup#OpenSceneGraph.
1212 (let ((commit "36a962845a2c87a6671fd822157e0729d164e940"))
1213 (hidden-package
1214 (package
1215 (inherit openscenegraph)
1216 (version (git-version "3.6" "1" commit))
1217 (source
1218 (origin
1219 (method git-fetch)
1220 (uri (git-reference
1221 (url "https://github.com/OpenMW/osg/")
1222 (commit commit)))
1223 (file-name (git-file-name (package-name openscenegraph) version))
1224 (sha256
1225 (base32
1226 "05yhgq3qm5q277y32n5sf36vx5nv5qd3zlhz4csgd3a6190jrnia"))))
1227 (arguments
1228 (substitute-keyword-arguments (package-arguments openscenegraph)
1229 ((#:configure-flags flags)
1230 ;; As per the above wiki link, the following plugins are enough:
1231 `(append
1232 '("-DBUILD_OSG_PLUGINS_BY_DEFAULT=0"
1233 "-DBUILD_OSG_PLUGIN_OSG=1"
1234 "-DBUILD_OSG_PLUGIN_DDS=1"
1235 "-DBUILD_OSG_PLUGIN_TGA=1"
1236 "-DBUILD_OSG_PLUGIN_BMP=1"
1237 "-DBUILD_OSG_PLUGIN_JPEG=1"
1238 "-DBUILD_OSG_PLUGIN_PNG=1"
1239 "-DBUILD_OSG_DEPRECATED_SERIALIZERS=0"
1240 ;; The jpeg plugin requires conversion between integers and booleans
1241 "-DCMAKE_CXX_FLAGS=-fpermissive")
1242 ,flags))))))))
1243
1244 (define-public povray
1245 (package
1246 (name "povray")
1247 (version "3.7.0.8")
1248 (source (origin
1249 (method git-fetch)
1250 (uri (git-reference
1251 (url "https://github.com/POV-Ray/povray")
1252 (commit (string-append "v" version))))
1253 (file-name (git-file-name name version))
1254 (sha256
1255 (base32
1256 "1q114n4m3r7qy3yn954fq7p46rg7ypdax5fazxr9yj1jklf1lh6z"))
1257 (modules '((guix build utils)))
1258 (snippet
1259 '(begin
1260 ;; Delete bundled libraries.
1261 (delete-file-recursively "libraries")
1262 #t))))
1263 (build-system gnu-build-system)
1264 (native-inputs
1265 `(("autoconf" ,autoconf)
1266 ("automake" ,automake)
1267 ("pkg-config" ,pkg-config)))
1268 (inputs
1269 `(("boost" ,boost)
1270 ("libjpeg" ,libjpeg-turbo)
1271 ("libpng" ,libpng)
1272 ("libtiff" ,libtiff)
1273 ("openexr" ,openexr)
1274 ("sdl" ,sdl)
1275 ("zlib" ,zlib)))
1276 (arguments
1277 '(#:configure-flags
1278 (list "COMPILED_BY=Guix"
1279 (string-append "--with-boost-libdir="
1280 (assoc-ref %build-inputs "boost") "/lib")
1281 "--disable-optimiz-arch")
1282 #:phases
1283 (modify-phases %standard-phases
1284 (add-after 'unpack 'run-prebuild
1285 (lambda _
1286 (setenv "HOME" (getcwd))
1287 (with-directory-excursion "unix"
1288 (substitute* "prebuild.sh"
1289 (("/bin/sh") (which "sh")))
1290 (invoke "sh" "prebuild.sh"))
1291 #t))
1292 ;; The bootstrap script is run by the prebuild script in the
1293 ;; "run-prebuild" phase.
1294 (delete 'bootstrap))))
1295 (synopsis "Tool for creating three-dimensional graphics")
1296 (description
1297 "@code{POV-Ray} is short for the Persistence of Vision Raytracer, a tool
1298 for producing high-quality computer graphics. @code{POV-Ray} creates
1299 three-dimensional, photo-realistic images using a rendering technique called
1300 ray-tracing. It reads in a text file containing information describing the
1301 objects and lighting in a scene and generates an image of that scene from the
1302 view point of a camera also described in the text file. Ray-tracing is not a
1303 fast process by any means, but it produces very high quality images with
1304 realistic reflections, shading, perspective and other effects.")
1305 (home-page "http://www.povray.org/")
1306 (license license:agpl3+)))
1307
1308 (define-public rapicorn
1309 (package
1310 (name "rapicorn")
1311 (version "16.0.0")
1312 (source (origin
1313 (method url-fetch)
1314 (uri (string-append "https://testbit.eu/pub/dists/rapicorn/"
1315 "rapicorn-" version ".tar.xz"))
1316 (sha256
1317 (base32
1318 "1y51yjrpsihas1jy905m9p3r8iiyhq6bwi2690c564i5dnix1f9d"))
1319 (patches (search-patches "rapicorn-isnan.patch"))))
1320 (build-system gnu-build-system)
1321 (arguments
1322 `(#:phases
1323 (modify-phases %standard-phases
1324 (add-after 'unpack 'fix-tests
1325 (lambda _
1326 ;; Our grep does not support perl regular expressions.
1327 (substitute* "taptool.sh"
1328 (("grep -P") "grep -E"))
1329 ;; Disable path tests because we cannot access /bin or /sbin.
1330 (substitute* "rcore/tests/multitest.cc"
1331 (("TCMP \\(Path::equals \\(\"/bin\"") "//"))
1332 #t))
1333 (add-before 'check 'pre-check
1334 (lambda _
1335 ;; The test suite requires a running X server (with DISPLAY
1336 ;; number 99 or higher).
1337 (system "Xvfb :99 &")
1338 (setenv "DISPLAY" ":99")
1339 #t))
1340 (add-after 'unpack 'replace-fhs-paths
1341 (lambda _
1342 (substitute* (cons "Makefile.decl"
1343 (find-files "." "^Makefile\\.in$"))
1344 (("/bin/ls") (which "ls"))
1345 (("/usr/bin/env") (which "env")))
1346 #t)))))
1347 ;; These libraries are listed in the "Required" section of the pkg-config
1348 ;; file.
1349 (propagated-inputs
1350 `(("librsvg" ,librsvg)
1351 ("cairo" ,cairo)
1352 ("pango" ,pango)
1353 ("libxml2" ,libxml2)
1354 ("python2-enum34" ,python2-enum34)))
1355 (inputs
1356 `(("gdk-pixbuf" ,gdk-pixbuf)
1357 ("libpng" ,libpng-1.2)
1358 ("readline" ,readline)
1359 ("libcroco" ,libcroco)
1360 ("python" ,python-2)
1361 ("cython" ,python2-cython)))
1362 (native-inputs
1363 `(("pandoc" ,pandoc)
1364 ("bison" ,bison)
1365 ("flex" ,flex)
1366 ("doxygen" ,doxygen)
1367 ("graphviz" ,graphviz)
1368 ("intltool" ,intltool)
1369 ("pkg-config" ,pkg-config)
1370 ("xvfb" ,xorg-server-for-tests)))
1371 (home-page "https://rapicorn.testbit.org/")
1372 (synopsis "Toolkit for rapid development of user interfaces")
1373 (description
1374 "Rapicorn is a toolkit for rapid development of user interfaces in C++
1375 and Python. The user interface is designed in a declarative markup language
1376 and is connected to the programming logic using data bindings and commands.")
1377 (license license:mpl2.0)))
1378
1379 (define-public ctl
1380 (package
1381 (name "ctl")
1382 (version "1.5.2")
1383 (source (origin
1384 (method url-fetch)
1385 (uri (string-append "https://github.com/ampas/CTL/archive/ctl-"
1386 version ".tar.gz"))
1387 (sha256
1388 (base32
1389 "1gg04pyvw0m398akn0s1l07g5b1haqv5na1wpi5dii1jjd1w3ynp"))))
1390 (build-system cmake-build-system)
1391 (arguments '(#:tests? #f)) ;no 'test' target
1392
1393 ;; Headers include OpenEXR and IlmBase headers.
1394 (propagated-inputs `(("openexr" ,openexr)))
1395
1396 (home-page "http://ampasctl.sourceforge.net")
1397 (synopsis "Color Transformation Language")
1398 (description
1399 "The Color Transformation Language, or CTL, is a small programming
1400 language that was designed to serve as a building block for digital color
1401 management systems. CTL allows users to describe color transforms in a
1402 concise and unambiguous way by expressing them as programs. In order to apply
1403 a given transform to an image, the color management system instructs a CTL
1404 interpreter to load and run the CTL program that describes the transform. The
1405 original and the transformed image constitute the CTL program's input and
1406 output.")
1407
1408 ;; The web site says it's under a BSD-3 license, but the 'LICENSE' file
1409 ;; and headers use different wording.
1410 (license (license:non-copyleft "file://LICENSE"))))
1411
1412 (define-public brdf-explorer
1413 ;; There are no release tarballs, and not even tags in the repo,
1414 ;; so use the latest revision.
1415 (let ((commit "5b2cd46f38a06e47207fa7229b72d37beb945019")
1416 (revision "1"))
1417 (package
1418 (name "brdf-explorer")
1419 (version (string-append "1.0.0-" revision "." (string-take commit 9)))
1420 (source (origin
1421 (method git-fetch)
1422 (uri (git-reference
1423 (url "https://github.com/wdas/brdf")
1424 (commit commit)))
1425 (sha256
1426 (base32
1427 "06vzbiajzbi2xl8jlff5d45bc9wd68i3jdndfab1f3jgfrd8bsgx"))
1428 (file-name (string-append name "-" version "-checkout"))))
1429 (build-system gnu-build-system)
1430 (arguments
1431 `(#:phases (modify-phases %standard-phases
1432 (replace 'configure
1433 (lambda* (#:key outputs #:allow-other-keys)
1434 (let ((out (assoc-ref outputs "out")))
1435 (invoke "qmake"
1436 (string-append "prefix=" out)))))
1437 (add-after 'install 'wrap-program
1438 (lambda* (#:key outputs #:allow-other-keys)
1439 (let* ((out (assoc-ref outputs "out"))
1440 (bin (string-append out "/bin"))
1441 (data (string-append
1442 out "/share/brdf")))
1443 (with-directory-excursion bin
1444 (rename-file "brdf" ".brdf-real")
1445 (call-with-output-file "brdf"
1446 (lambda (port)
1447 (format port "#!/bin/sh
1448 # Run the thing from its home, otherwise it just bails out.
1449 cd \"~a\"
1450 exec -a \"$0\" ~a/.brdf-real~%"
1451 data bin)))
1452 (chmod "brdf" #o555)))
1453 #t)))))
1454 (native-inputs
1455 `(("qttools" ,qttools))) ;for 'qmake'
1456 (inputs
1457 `(("qtbase" ,qtbase)
1458 ("mesa" ,mesa)
1459 ("glew" ,glew)
1460 ("freeglut" ,freeglut)
1461 ("zlib" ,zlib)))
1462 (home-page "https://www.disneyanimation.com/technology/brdf.html")
1463 (synopsis
1464 "Analyze bidirectional reflectance distribution functions (BRDFs)")
1465 (description
1466 "BRDF Explorer is an application that allows the development and analysis
1467 of bidirectional reflectance distribution functions (BRDFs). It can load and
1468 plot analytic BRDF functions (coded as functions in OpenGL's GLSL shader
1469 language), measured material data from the MERL database, and anisotropic
1470 measured material data from MIT CSAIL. Graphs and visualizations update in
1471 real time as parameters are changed, making it a useful tool for evaluating
1472 and understanding different BRDFs (and other component functions).")
1473 (license license:ms-pl))))
1474
1475 (define-public agg
1476 (package
1477 (name "agg")
1478 (version "2.5")
1479 (source (origin
1480 (method url-fetch)
1481 (uri (list (string-append
1482 "ftp://ftp.fau.de/gentoo/distfiles/agg-"
1483 version ".tar.gz")
1484 (string-append
1485 "ftp://ftp.ula.ve/gentoo/distfiles/agg-"
1486 version ".tar.gz")
1487
1488 ;; Site was discontinued.
1489 (string-append "http://www.antigrain.com/agg-"
1490 version ".tar.gz")))
1491 (sha256
1492 (base32 "07wii4i824vy9qsvjsgqxppgqmfdxq0xa87i5yk53fijriadq7mb"))
1493 (patches (search-patches "agg-am_c_prototype.patch"))))
1494 (build-system gnu-build-system)
1495 (arguments
1496 '(#:configure-flags
1497 (list (string-append "--x-includes=" (assoc-ref %build-inputs "libx11")
1498 "/include")
1499 (string-append "--x-libraries=" (assoc-ref %build-inputs "libx11")
1500 "/lib")
1501 "--disable-examples")
1502 #:phases
1503 (modify-phases %standard-phases
1504 (replace 'bootstrap
1505 (lambda _
1506 ;; let's call configure from configure phase and not now
1507 (substitute* "autogen.sh" (("./configure") "# ./configure"))
1508 (invoke "sh" "autogen.sh"))))))
1509 (native-inputs
1510 `(("pkg-config" ,pkg-config)
1511 ("libtool" ,libtool)
1512 ("autoconf" ,autoconf)
1513 ("automake" ,automake)))
1514 (inputs
1515 `(("libx11" ,libx11)
1516 ("freetype" ,freetype)
1517 ("sdl" ,sdl)))
1518
1519 ;; Antigrain.com was discontinued.
1520 (home-page "http://agg.sourceforge.net/antigrain.com/index.html")
1521 (synopsis "High-quality 2D graphics rendering engine for C++")
1522 (description
1523 "Anti-Grain Geometry is a high quality rendering engine written in C++.
1524 It supports sub-pixel resolutions and anti-aliasing. It is also library for
1525 rendering SVG graphics.")
1526 (license license:gpl2+)))
1527
1528 (define-public python-pastel
1529 (package
1530 (name "python-pastel")
1531 (version "0.2.0")
1532 (source
1533 (origin
1534 (method url-fetch)
1535 (uri (pypi-uri "pastel" version))
1536 (sha256
1537 (base32
1538 "0dnaw44ss10i10z4ksy0xljknvjap7rb7g0b8p6yzm5x4g2my5a6"))))
1539 (build-system python-build-system)
1540 (arguments
1541 `(#:phases (modify-phases %standard-phases
1542 (replace 'check
1543 (lambda _ (invoke "pytest" "pastel" "tests/"))))))
1544 (native-inputs
1545 `(("python-pytest" ,python-pytest)))
1546 (home-page "https://github.com/sdispater/pastel")
1547 (synopsis "Library to colorize strings in your terminal")
1548 (description "Pastel is a simple library to help you colorize strings in
1549 your terminal.")
1550 (license license:expat)))
1551
1552 (define-public python2-pastel
1553 (package-with-python2 python-pastel))
1554
1555 (define-public fgallery
1556 (package
1557 (name "fgallery")
1558 (version "1.8.2")
1559 (source (origin
1560 (method url-fetch)
1561 (uri
1562 (string-append
1563 "http://www.thregr.org/~wavexx/software/fgallery/releases/"
1564 "fgallery-" version ".zip"))
1565 (sha256
1566 (base32
1567 "18wlvqbxcng8pawimbc8f2422s8fnk840hfr6946lzsxr0ijakvf"))))
1568 (build-system gnu-build-system)
1569 (arguments
1570 `(#:tests? #f ; no tests
1571 #:phases
1572 (modify-phases %standard-phases
1573 (delete 'configure)
1574 (delete 'build)
1575 (replace 'install
1576 (lambda* (#:key inputs outputs #:allow-other-keys)
1577 (let* ((out (assoc-ref outputs "out"))
1578 (bin (string-append out "/bin/"))
1579 (share (string-append out "/share/fgallery"))
1580 (man (string-append out "/share/man/man1"))
1581 (perl5lib (getenv "PERL5LIB"))
1582 (script (string-append share "/fgallery")))
1583 (define (bin-directory input-name)
1584 (string-append (assoc-ref inputs input-name) "/bin"))
1585
1586 (mkdir-p man)
1587 (copy-file "fgallery.1" (string-append man "/fgallery.1"))
1588
1589 (mkdir-p share)
1590 (copy-recursively "." share)
1591
1592 ;; fgallery copies files from store when it is run. The
1593 ;; read-only permissions from the store directories will cause
1594 ;; fgallery to fail. Do not preserve file attributes when
1595 ;; copying files to prevent it.
1596 (substitute* script
1597 (("'cp'")
1598 "'cp', '--no-preserve=all'"))
1599
1600 (mkdir-p bin)
1601 (symlink script (string-append out "/bin/fgallery"))
1602
1603 (wrap-program script
1604 `("PATH" ":" prefix
1605 ,(map bin-directory '("imagemagick"
1606 "lcms"
1607 "fbida"
1608 "libjpeg"
1609 "zip"
1610 "jpegoptim"
1611 "pngcrush"
1612 "p7zip")))
1613 `("PERL5LIB" ":" prefix (,perl5lib)))
1614 #t))))))
1615 (native-inputs
1616 `(("unzip" ,unzip)))
1617 ;; TODO: Add missing optional dependency: facedetect.
1618 (inputs
1619 `(("imagemagick" ,imagemagick)
1620 ("lcms" ,lcms)
1621 ("fbida" ,fbida)
1622 ("libjpeg" ,libjpeg-turbo)
1623 ("zip" ,zip)
1624 ("perl" ,perl)
1625 ("perl-cpanel-json-xs" ,perl-cpanel-json-xs)
1626 ("perl-image-exiftool" ,perl-image-exiftool)
1627 ("jpegoptim" ,jpegoptim)
1628 ("pngcrush" ,pngcrush)
1629 ("p7zip" ,p7zip)))
1630 (home-page "http://www.thregr.org/~wavexx/software/fgallery/")
1631 (synopsis "Static photo gallery generator")
1632 (description
1633 "FGallery is a static, JavaScript photo gallery generator with minimalist
1634 look. The result can be uploaded on any web server without additional
1635 requirements.")
1636 (license license:gpl2+)))
1637
1638 (define-public opensubdiv
1639 (package
1640 (name "opensubdiv")
1641 (version "3.4.0")
1642 (source (origin
1643 (method git-fetch)
1644 (uri (git-reference
1645 (url "https://github.com/PixarAnimationStudios/OpenSubdiv")
1646 (commit (string-append "v" (string-join (string-split version #\.)
1647 "_")))))
1648 (file-name (git-file-name name version))
1649 (sha256
1650 (base32
1651 "0cippg6aqc5dlya1cmh3908pwssrg52fwgyylnvz5343yrxmgk12"))))
1652 (build-system cmake-build-system)
1653 (arguments
1654 `(#:phases (modify-phases %standard-phases
1655 (add-before 'configure 'set-glew-location
1656 (lambda* (#:key inputs #:allow-other-keys)
1657 (setenv "GLEW_LOCATION" (assoc-ref inputs "glew"))
1658 #t))
1659 (add-before 'check 'start-xorg-server
1660 (lambda* (#:key inputs #:allow-other-keys)
1661 ;; The test suite requires a running X server.
1662 (system (string-append (assoc-ref inputs "xorg-server")
1663 "/bin/Xvfb :1 &"))
1664 (setenv "DISPLAY" ":1")
1665 #t)))))
1666 (native-inputs
1667 `(("xorg-server" ,xorg-server-for-tests)))
1668 (inputs
1669 `(("glew" ,glew)
1670 ("libxrandr" ,libxrandr)
1671 ("libxcursor" ,libxcursor)
1672 ("libxinerama" ,libxinerama)
1673 ("libxi" ,libxi)
1674 ("zlib" ,zlib)
1675 ("glfw" ,glfw)))
1676 (home-page "https://graphics.pixar.com/opensubdiv/")
1677 (synopsis "High performance subdivision surface evaluation")
1678 (description "OpenSubdiv is a set of libraries that implement high
1679 performance subdivision surface (subdiv) evaluation on massively parallel CPU
1680 and GPU architectures.")
1681 (license license:asl2.0)))
1682
1683 (define-public opencsg
1684 (let ((dot-to-dash (lambda (c) (if (char=? c #\.) #\- c))))
1685 (package
1686 (name "opencsg")
1687 (version "1.4.2")
1688 (source
1689 (origin
1690 (method git-fetch)
1691 (uri (git-reference
1692 (url "https://github.com/floriankirsch/OpenCSG")
1693 (commit (string-append "opencsg-"
1694 (string-map dot-to-dash version)
1695 "-release"))))
1696 (file-name (git-file-name name version))
1697 (sha256
1698 (base32
1699 "00m4vs6jn3scqczscc4591l1d6zg6anqp9v1ldf9ymf70rdyvm7m"))))
1700 (build-system gnu-build-system)
1701 (arguments
1702 `(#:phases
1703 (modify-phases %standard-phases
1704 (replace 'configure
1705 (lambda* (#:key outputs #:allow-other-keys)
1706 (substitute* "src/Makefile"
1707 (("/usr/local") (assoc-ref outputs "out")))
1708 #t))
1709 (add-before 'build 'skip-example
1710 (lambda _ (chdir "src") #t)))))
1711 (inputs
1712 `(("glew" ,glew)
1713 ("freeglut" ,freeglut)))
1714 (synopsis "Library for rendering Constructive Solid Geometry (CSG)")
1715 (description
1716 "OpenCSG is a library for rendering Constructive Solid Geometry (CSG) using
1717 OpenGL. CSG is an approach for modeling complex 3D-shapes using simpler ones.
1718 For example, two shapes can be combined by uniting them, by intersecting them,
1719 or by subtracting one shape from the other.")
1720 (home-page "http://www.opencsg.org/")
1721 (license license:gpl2))))
1722
1723 (define-public coin3D
1724 ;; The ‘4.0.0’ zip archive isn't stable, nor in fact a release. See:
1725 ;; https://bitbucket.org/Coin3D/coin/issues/179/coin-400-srczip-has-been-modified
1726 (let ((revision 1)
1727 (changeset "ab8d0e47a4de3230a8137feb39c142d6ba45f97d"))
1728 (package
1729 (name "coin3D")
1730 (version
1731 (simple-format #f "3.1.3-~A-~A" revision (string-take changeset 7)))
1732 (source
1733 (origin
1734 (method hg-fetch)
1735 (uri (hg-reference
1736 (url "https://bitbucket.org/Coin3D/coin")
1737 (changeset changeset)))
1738 (file-name (git-file-name name version))
1739 (sha256
1740 (base32 "1ff44jz6lg4rylljvy69n1hcjh9y6achbv9jpn1cv2sf8cxn3r2j"))
1741 (modules '((guix build utils)))
1742 (snippet
1743 '(begin
1744 (for-each delete-file
1745 '("cfg/csubst.exe"
1746 "cfg/wrapmsvc.exe"))
1747 #t))))
1748 (build-system cmake-build-system)
1749 (native-inputs
1750 `(("doxygen" ,doxygen)
1751 ("graphviz" ,graphviz)))
1752 (inputs
1753 `(("boost" ,boost)
1754 ("freeglut" ,freeglut)
1755 ("glew" ,glew)))
1756 (arguments
1757 `(#:configure-flags
1758 (list
1759 "-DCOIN_BUILD_DOCUMENTATION_MAN=ON"
1760 (string-append "-DBOOST_ROOT="
1761 (assoc-ref %build-inputs "boost")))))
1762 (home-page "https://bitbucket.org/Coin3D/coin/wiki/Home")
1763 (synopsis
1764 "High-level 3D visualization library with Open Inventor 2.1 API")
1765 (description
1766 "Coin is a 3D graphics library with an Application Programming Interface
1767 based on the Open Inventor 2.1 API. For those who are not familiar with
1768 Open Inventor, it is a scene-graph based retain-mode rendering and model
1769 interaction library, written in C++, which has become the de facto
1770 standard graphics library for 3D visualization and visual simulation
1771 software in the scientific and engineering community.")
1772 (license license:bsd-3))))
1773
1774 (define-public coin3D-4
1775 (package
1776 (name "coin3D")
1777 (version "4.0.0")
1778 (source
1779 (origin
1780 (method git-fetch)
1781 (uri (git-reference
1782 (url "https://github.com/coin3d/coin")
1783 (commit (string-append "Coin-" version))
1784 (recursive? #t)))
1785 (file-name (git-file-name name version))
1786 (sha256
1787 (base32 "1ayg0hl8wanhadahm5xbghghxw1qjwqbrs3dl3ngnff027hsyf8p"))
1788 (modules '((guix build utils)))
1789 (snippet
1790 '(begin
1791 ;; Delete binaries
1792 (for-each delete-file
1793 '("cfg/csubst.exe"
1794 "cfg/wrapmsvc.exe"))
1795 ;; Delete references to packaging tool cpack. Otherwise the build
1796 ;; fails with "add_subdirectory given source "cpack.d" which is not
1797 ;; an existing directory."
1798 (substitute* "CMakeLists.txt"
1799 ((".*cpack.d.*") ""))
1800 #t))))
1801 (build-system cmake-build-system)
1802 (native-inputs
1803 `(("doxygen" ,doxygen)
1804 ("graphviz" ,graphviz)))
1805 (inputs
1806 `(("boost" ,boost)
1807 ("freeglut" ,freeglut)
1808 ("glew" ,glew)))
1809 (arguments
1810 `(#:configure-flags
1811 (list
1812 "-DCOIN_BUILD_DOCUMENTATION_MAN=ON"
1813 (string-append "-DBOOST_ROOT="
1814 (assoc-ref %build-inputs "boost")))))
1815 (home-page "https://github.com/coin3d/coin")
1816 (synopsis
1817 "High-level 3D visualization library with Open Inventor 2.1 API")
1818 (description
1819 "Coin is a 3D graphics library with an Application Programming Interface
1820 based on the Open Inventor 2.1 API. For those who are not familiar with Open
1821 Inventor, it is a scene-graph based retain-mode rendering and model interaction
1822 library, written in C++, which has become the de facto standard graphics
1823 library for 3D visualization and visual simulation software in the scientific
1824 and engineering community.")
1825 (license license:bsd-3)))
1826
1827 (define-public superfamiconv
1828 (package
1829 (name "superfamiconv")
1830 (version "0.8.8")
1831 (source
1832 (origin
1833 (method git-fetch)
1834 (uri (git-reference
1835 (url "https://github.com/Optiroc/SuperFamiconv")
1836 (commit (string-append "v" version))))
1837 (file-name (git-file-name name version))
1838 (sha256
1839 (base32
1840 "0848szv6a2b8wdganh6mw5i8vn8cqvn1kbwzx7mb9wlrf5wzqn37"))))
1841 (build-system gnu-build-system)
1842 (arguments
1843 `(#:tests? #f ; no tests
1844 #:phases
1845 (modify-phases %standard-phases
1846 (delete 'configure)
1847 (replace 'install
1848 (lambda* (#:key outputs #:allow-other-keys)
1849 (let* ((outdir (assoc-ref outputs "out"))
1850 (bindir (string-append outdir "/bin")))
1851 (install-file "bin/superfamiconv" bindir)
1852 #t))))))
1853 (home-page "https://github.com/Optiroc/SuperFamiconv")
1854 (synopsis "Tile graphics converter supporting SNES, Game Boy Color
1855 and PC Engine formats")
1856 (description "SuperFamiconv is a converter for tiled graphics, supporting
1857 the graphics formats of the SNES, Game Boy Color and PC Engine game consoles.
1858 Automated palette selection is supported.")
1859 (license license:expat)))
1860
1861 (define-public drawpile
1862 ;; This commit fix building with libmicrohttpd>=0.71.
1863 (let ((commit "ed1a75deb113da2d1df91a28f557509c4897130e")
1864 (revision "1"))
1865 (package
1866 (name "drawpile")
1867 (version (string-append "2.1.17-" revision "." (string-take commit 9)))
1868 (source (origin
1869 (method git-fetch)
1870 (uri (git-reference
1871 (url "https://github.com/drawpile/Drawpile")
1872 (commit commit)))
1873 (file-name (git-file-name name version))
1874 (sha256
1875 (base32
1876 "1y21h1hk9ipkjvhjgas0c5hkjyan92vsxbxrn60c906hzqln2fr1"))))
1877 (build-system qt-build-system)
1878 (arguments
1879 '(#:configure-flags
1880 (list "-DTESTS=ON" "-DTOOLS=ON" "-DKIS_TABLET=ON")))
1881 (native-inputs
1882 `(("extra-cmake-modules" ,extra-cmake-modules)
1883 ("pkg-config" ,pkg-config)))
1884 (inputs
1885 `(("giflib" ,giflib)
1886 ("karchive" ,karchive)
1887 ("kdnssd" ,kdnssd)
1888 ("libmicrohttpd" ,libmicrohttpd)
1889 ("libsodium" ,libsodium)
1890 ("libvpx" ,libvpx)
1891 ("libxi" ,libxi)
1892 ;; ("miniupnpc" ,miniupnpc) ;segfaults for some reason
1893 ("qtbase" ,qtbase)
1894 ("qtkeychain" ,qtkeychain)
1895 ("qtmultimedia" ,qtmultimedia)
1896 ("qtsvg" ,qtsvg)
1897 ("qtx11extras" ,qtx11extras)))
1898 (home-page "https://drawpile.net")
1899 (synopsis "Collaborative drawing program")
1900 (description "Drawpile is a drawing program that allows share the canvas
1901 with other users in real time.
1902
1903 Some feature highlights:
1904 @itemize
1905 @item Shared canvas using the built-in server or a dedicated server
1906 @item Record, play back and export drawing sessions
1907 @item Simple animation support
1908 @item Layers and blending modes
1909 @item Text layers
1910 @item Supports pressure sensitive Wacom tablets
1911 @item Built-in chat
1912 @item Supports OpenRaster file format
1913 @item Encrypted connections using SSL
1914 @item Automatic port forwarding with UPnP
1915 @end itemize\n")
1916 (license license:gpl3+))))