Merge branch 'master' into ungrafting
[jackhill/guix/guix.git] / gnu / packages / education.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2016 Danny Milosavljevic <dannym@scratchpost.org>
3 ;;; Copyright © 2016, 2017 Ricardo Wurmus <rekado@elephly.net>
4 ;;; Copyright © 2016 Hartmut Goebel <h.goebel@crazy-compilers.com>
5 ;;; Copyright © 2017, 2018, 2019, 2020 Efraim Flashner <efraim@flashner.co.il>
6 ;;; Copyright © 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
7 ;;; Copyright © 2018, 2019, 2020 Nicolas Goaziou <mail@nicolasgoaziou.fr>
8 ;;; Copyright © 2020 Robert Smith <robertsmith@posteo.net>
9 ;;; Copyright © 2020 Guy Fleury Iteriteka <gfleury@disroot.org>
10 ;;; Copyright © 2020 Jakub Kądziołka <kuba@kadziolka.net>
11 ;;; Copyright © 2020 Prafulla Giri <pratheblackdiamond@gmail.com>
12 ;;;
13 ;;; This file is part of GNU Guix.
14 ;;;
15 ;;; GNU Guix is free software; you can redistribute it and/or modify it
16 ;;; under the terms of the GNU General Public License as published by
17 ;;; the Free Software Foundation; either version 3 of the License, or (at
18 ;;; your option) any later version.
19 ;;;
20 ;;; GNU Guix is distributed in the hope that it will be useful, but
21 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
22 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
23 ;;; GNU General Public License for more details.
24 ;;;
25 ;;; You should have received a copy of the GNU General Public License
26 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
27
28 (define-module (gnu packages education)
29 #:use-module (ice-9 regex)
30 #:use-module (gnu packages)
31 #:use-module (gnu packages audio)
32 #:use-module (gnu packages base)
33 #:use-module (gnu packages bash)
34 #:use-module (gnu packages compression)
35 #:use-module (gnu packages curl)
36 #:use-module (gnu packages databases)
37 #:use-module (gnu packages flex)
38 #:use-module (gnu packages fonts)
39 #:use-module (gnu packages freedesktop)
40 #:use-module (gnu packages game-development)
41 #:use-module (gnu packages gettext)
42 #:use-module (gnu packages glib)
43 #:use-module (gnu packages gnome)
44 #:use-module (gnu packages golang)
45 #:use-module (gnu packages gtk)
46 #:use-module (gnu packages image)
47 #:use-module (gnu packages javascript)
48 #:use-module (gnu packages kde)
49 #:use-module (gnu packages kde-frameworks) ; extra-cmake-modules
50 #:use-module (gnu packages mp3)
51 #:use-module (gnu packages ncurses)
52 #:use-module (gnu packages perl)
53 #:use-module (gnu packages pkg-config)
54 #:use-module (gnu packages python)
55 #:use-module (gnu packages python-web)
56 #:use-module (gnu packages python-xyz)
57 #:use-module (gnu packages qt)
58 #:use-module (gnu packages readline)
59 #:use-module (gnu packages sdl)
60 #:use-module (gnu packages sqlite)
61 #:use-module (gnu packages texinfo)
62 #:use-module (gnu packages tls)
63 #:use-module (gnu packages video)
64 #:use-module (gnu packages xorg)
65 #:use-module (gnu packages xml)
66 #:use-module ((guix licenses) #:prefix license:)
67 #:use-module (guix packages)
68 #:use-module (guix download)
69 #:use-module (guix git-download)
70 #:use-module (guix svn-download)
71 #:use-module (guix utils)
72 #:use-module (guix build-system cmake)
73 #:use-module (guix build-system gnu)
74 #:use-module (guix build-system go)
75 #:use-module (guix build-system python)
76 #:use-module (guix build-system qt)
77 #:use-module (guix build-system trivial)
78 #:use-module (srfi srfi-1))
79
80 (define-public gcompris
81 (package
82 (name "gcompris")
83 (version "17.05")
84 (source (origin
85 (method url-fetch)
86 (uri (string-append "http://gcompris.net/download/gtk/src/gcompris-"
87 version ".tar.bz2"))
88 (sha256
89 (base32
90 "18y483alb4r4vfmh80nnl0pah5gv0b8frcm6l1drb9njn5xlcpgc"))))
91 (build-system gnu-build-system)
92 (arguments
93 `(#:configure-flags
94 ;; Use SDL mixer because otherwise GCompris would need an old version
95 ;; of Gstreamer.
96 (list "--enable-sdlmixer"
97 "LDFLAGS=-lgmodule-2.0")
98 #:phases
99 (modify-phases %standard-phases
100 (add-after 'set-paths 'set-sdl-paths
101 (lambda* (#:key inputs #:allow-other-keys)
102 (setenv "CPATH"
103 (string-append (assoc-ref inputs "sdl-mixer")
104 "/include/SDL:"
105 (or (getenv "CPATH") "")))
106 #t)))))
107 (inputs
108 `(("gtk+" ,gtk+-2)
109 ("librsvg" ,librsvg)
110 ("libxml2" ,libxml2)
111 ("sdl-mixer" ,sdl-mixer)
112 ("sqlite" ,sqlite)
113 ("glib:bin" ,glib)
114 ("python" ,python)))
115 (native-inputs
116 `(("intltool" ,intltool)
117 ("texinfo" ,texinfo)
118 ("texi2html" ,texi2html)
119 ("glib:bin" ,glib "bin")
120 ("pkg-config" ,pkg-config)))
121 (home-page "https://gcompris.net")
122 (synopsis "Educational software suite")
123 (description "GCompris is an educational software suite comprising of
124 numerous activities for children aged 2 to 10. Some of the activities are
125 game orientated, but nonetheless still educational. Below you can find a list
126 of categories with some of the activities available in that category.
127
128 @enumerate
129 @item computer discovery: keyboard, mouse, different mouse gestures, ...
130 @item arithmetic: table memory, enumeration, double entry table, mirror image, ...
131 @item science: the canal lock, the water cycle, the submarine, electric simulation ...
132 @item geography: place the country on the map
133 @item games: chess, memory, connect 4, oware, sudoku ...
134 @item reading: reading practice
135 @item other: learn to tell time, puzzle of famous paintings, vector drawing, cartoon making, ...
136 @end enumerate
137 ")
138 (license license:gpl3+)))
139
140 (define-public gcompris-qt
141 (package
142 (name "gcompris-qt")
143 (version "1.0")
144 (source
145 (origin
146 (method url-fetch)
147 (uri (string-append
148 "https://gcompris.net/download/qt/src/gcompris-qt-"
149 version ".tar.xz"))
150 (sha256
151 (base32 "08dw1q0h4qz2q0ksa5pbmb9v60hr1zv9skx6z8dlq9b1i7harnds"))))
152 (build-system cmake-build-system)
153 (arguments
154 `(#:phases
155 (modify-phases %standard-phases
156 (add-before 'check 'start-xorg-server
157 (lambda* (#:key inputs #:allow-other-keys)
158 ;; The test suite requires a running X server.
159 (system (string-append (assoc-ref inputs "xorg-server")
160 "/bin/Xvfb :1 &"))
161 (setenv "DISPLAY" ":1")
162 ;; The test suite wants to write to /homeless-shelter
163 (setenv "HOME" (getcwd))
164 #t))
165 (add-after 'install 'wrap-executable
166 (lambda* (#:key inputs outputs #:allow-other-keys)
167 (let ((out (assoc-ref outputs "out")))
168 (wrap-program (string-append out "/bin/gcompris-qt")
169 `("QT_PLUGIN_PATH" ":" prefix
170 ,(map (lambda (label)
171 (string-append (assoc-ref inputs label)
172 "/lib/qt5/plugins"))
173 '("qtbase" "qtdeclarative" "qtmultimedia" "qtsvg")))
174 `("QML2_IMPORT_PATH" ":" prefix
175 ,(map (lambda (label)
176 (string-append (assoc-ref inputs label)
177 "/lib/qt5/qml"))
178 '("qtdeclarative" "qtgraphicaleffects"
179 "qtmultimedia" "qtquickcontrols"))))
180 #t))))
181 #:configure-flags (list "-DQML_BOX2D_MODULE=disabled"
182 "-DBUILD_TESTING=TRUE")))
183 (native-inputs
184 `(("extra-cmake-modules" ,extra-cmake-modules)
185 ("gettext" ,gettext-minimal)
186 ("kdoctools" ,kdoctools)
187 ("perl" ,perl)
188 ("qttools" ,qttools)
189 ("xorg-server" ,xorg-server-for-tests)))
190 (inputs
191 `(("openssl" ,openssl)
192 ("python" ,python-wrapper)
193 ("qtbase" ,qtbase)
194 ("qtdeclarative" ,qtdeclarative)
195 ("qtgraphicaleffects" ,qtgraphicaleffects)
196 ("qtmultimedia" ,qtmultimedia)
197 ("qtquickcontrols" ,qtquickcontrols)
198 ("qtsensors" ,qtsensors)
199 ("qtsvg" ,qtsvg)
200 ("qtxmlpatterns" ,qtxmlpatterns)))
201 (home-page "https://gcompris.net/index-en.html")
202 (synopsis "Educational games for small children")
203 (description
204 "Gcompris offers a large collection of educational games for small
205 children, designed to be a unified interface to integrate more educational
206 games. Language-oriented games contain vocabulary, sounds, and voices for
207 many different languages.
208 Currently available boards include:
209 @enumerate
210 @item learning how to use a mouse and keyboard
211 @item learning simple arithmetic
212 @item learning how to read an analog clock
213 @item recognize letters after hearing their names
214 @item reading practice
215 @item small games (memory games, jigsaw puzzles, ...)
216 @end enumerate\n")
217 (license (list license:silofl1.1 ; bundled fonts
218 license:gpl3+))))
219
220 (define-public tipp10
221 (package
222 (name "tipp10")
223 (version "2.1.0")
224 (source (origin
225 (method url-fetch)
226 ;; guix download is not able to handle the download links on the
227 ;; home-page, which use '<meta http-equiv="refresh" …>'
228 (uri (string-append "mirror://debian/pool/main/"
229 "t/tipp10/tipp10_2.1.0.orig.tar.gz"))
230 (sha256
231 (base32
232 "0d387b404j88gsv6kv0rb7wxr23v5g5vl6s5l7602x8pxf7slbbx"))
233 (patches (search-patches "tipp10-fix-compiling.patch"
234 "tipp10-remove-license-code.patch"))))
235 (build-system cmake-build-system)
236 (arguments
237 `(#:tests? #f ; packages has no tests
238 #:phases
239 (modify-phases %standard-phases
240 (add-after 'unpack 'disable-new-version-check
241 (lambda _
242 ;; Make new version check to default to false.
243 ;; TODO: Remove the checkbox from the dialog and the check itself
244 (substitute* '("widget/settingspages.cpp" "widget/mainwindow.cpp")
245 (("settings.value(\"check_new_version\", true)")
246 "settings.value(\"check_new_version\", false)"))
247 #t))
248 (replace 'configure
249 (lambda* (#:key outputs #:allow-other-keys)
250 (let ((out (assoc-ref outputs "out")))
251 ;; Make program honor $PREFIX
252 (substitute* "tipp10.pro"
253 (("\\.path = /usr/") (string-append ".path = " out "/")))
254 (substitute* "def/defines.h"
255 (("\"/usr/") (string-append "\"" out "/")))
256 ;; Recreate Makefile
257 (invoke "qmake")))))))
258 (inputs
259 `(("qt4" ,qt-4)
260 ("sqlite" ,sqlite)))
261 (home-page "https://www.tipp10.com/")
262 (synopsis "Touch typing tutor")
263 (description "Tipp10 is a touch typing tutor. The ingenious thing about
264 the software is its intelligence feature: characters that are mistyped are
265 repeated more frequently. Beginners will find their way around right away so
266 they can start practicing without a hitch.
267
268 Useful support functions and an extensive progress tracker, topical lessons
269 and the ability to create your own practice lessons make learning to type
270 easy.")
271 (license license:gpl2)))
272
273 (define-public snap
274 (package
275 (name "snap")
276 (version "6.5.0")
277 (source
278 (origin
279 (method git-fetch)
280 (uri (git-reference
281 (url "https://github.com/jmoenig/Snap")
282 (commit (string-append "v" version))))
283 (file-name (git-file-name name version))
284 (sha256
285 (base32 "0sqd4ddkfc7f7gx02wffvwbqgfbhpkcgyv7v5rh3gx60jca02p4w"))))
286 (build-system trivial-build-system)
287 (arguments
288 `(#:modules ((guix build utils))
289 #:builder
290 (begin
291 (use-modules (guix build utils))
292 (let* ((source (assoc-ref %build-inputs "source"))
293 (out (assoc-ref %outputs "out"))
294 (share (string-append out "/share/snap")))
295 (copy-recursively source share)
296 ;; Replace the sole minified file in the package.
297 (with-directory-excursion (string-append share "/src")
298 (delete-file "FileSaver.min.js")
299 (symlink (string-append (assoc-ref %build-inputs "js-filesaver")
300 "/share/javascript/FileSaver.min.js")
301 "FileSaver.min.js"))
302 ;; Create a "snap" executable.
303 (let* ((bin (string-append out "/bin"))
304 (script (string-append bin "/snap"))
305 (snap (string-append share "/snap.html"))
306 (bash (string-append (assoc-ref %build-inputs "bash")
307 "/bin/sh"))
308 (xdg-open (string-append (assoc-ref %build-inputs "xdg-utils")
309 "/bin/xdg-open")))
310 (mkdir-p bin)
311 (call-with-output-file script
312 (lambda (port)
313 (format port "#!~a\n~a '~a'" bash xdg-open snap)))
314 (chmod script #o555)))
315 #t)))
316 (inputs
317 `(("bash" ,bash-minimal)
318 ("js-filesaver" ,js-filesaver)
319 ("xdg-utils" ,xdg-utils)))
320 (home-page "https://snap.berkeley.edu")
321 (synopsis "Visual, blocks based programming language")
322 (description "Snap! (formerly BYOB) is a visual, drag-and-drop
323 programming language. It is an extended reimplementation of Scratch (a
324 project of the Lifelong Kindergarten Group at the MIT Media Lab) that
325 allows you to Build Your Own Blocks. It also features first class
326 lists, first class procedures, and continuations. These added
327 capabilities make it suitable for a serious introduction to computer
328 science for high school or college students.
329
330 This package provides a @command{snap} executable calling @command{xdg-open}
331 to open the application in a web browser, for offline usage.")
332 (license license:agpl3+)))
333
334 (define-public toutenclic
335 (package
336 (name "toutenclic")
337 (version "7.00")
338 (source
339 (origin
340 (method url-fetch)
341 (uri (string-append "http://www.bipede.fr/downloads/logiciels/"
342 "ToutEnClic-" version "-src.zip"))
343 (sha256
344 (base32 "0xg24p925rl5bfqsq3jb2lrkidb0f3kbmay5iyxxmjsn3ra0blyh"))))
345 (build-system python-build-system)
346 (arguments
347 `(#:tests? #f ; no tests
348 #:phases
349 (modify-phases %standard-phases
350 (delete 'build)
351 (replace 'install
352 (lambda* (#:key outputs #:allow-other-keys)
353 (let* ((out (assoc-ref outputs "out"))
354 (share (string-append out "/share/toutenclic"))
355 (pixmaps (string-append out "/share/pixmaps"))
356 (doc (string-append out "share/doc/" ,name "-" ,version))
357 (bin (string-append out "/bin"))
358 (executable "toutenclic"))
359 ;; Install icon.
360 (install-file "toutenclic.png" pixmaps)
361 ;; Move files into "share/" directory.
362 (for-each (lambda (f) (install-file f share))
363 (find-files "." "\\.py$"))
364 ;; Install documentation.
365 (install-file "ToutEnClic.pdf" doc)
366 ;; Create executable in "bin/".
367 (mkdir-p bin)
368 (with-directory-excursion bin
369 (symlink (string-append share "/" executable ".py")
370 executable)))
371 #t))
372 (add-after 'install 'create-desktop-file
373 (lambda* (#:key outputs #:allow-other-keys)
374 (let* ((out (assoc-ref outputs "out"))
375 (applications (string-append out "/share/applications")))
376 (mkdir-p applications)
377 (call-with-output-file
378 (string-append applications "/toutenclic.desktop")
379 (lambda (file)
380 (format file
381 "[Desktop Entry]~@
382 Name=ToutEnClic~@
383 Comment=For schooling without difference~@
384 Exec=~a/bin/toutenclic~@
385 TryExec=~@*~a/bin/toutenclic~@
386 Terminal=false~@
387 Icon=toutenclic~@
388 Type=Application~%"
389 out)))
390 #t))))))
391 (native-inputs
392 `(("unzip" ,unzip)))
393 (inputs
394 `(("python-pyqt" ,python-pyqt)))
395 (synopsis "School tools for physically disabled children")
396 (description "ToutEnClic is intended to facilitate the schooling
397 of physically disabled children in ordinary schools. It is both
398 a multi-page virtual exercise book and a kit including pencil,
399 scissors, glue, ruler, compass, protractor and square. A virtual
400 keyboard is also available if the child does not have any other
401 specialized device.")
402 (home-page "https://bipede.fr/contrib/")
403 (license license:gpl3)))
404
405 (define-public childsplay
406 (package
407 (name "childsplay")
408 (version "3.4")
409 (source (origin
410 (method url-fetch)
411 (uri (string-append
412 "mirror://sourceforge/schoolsplay/"
413 "childsplay-" version ".tgz"))
414 (sha256
415 (base32
416 "0z7yp2swjnbz51vn2zyfnjn40jq38l5mbh15yafmx1z3vn2z1m77"))))
417 (build-system python-build-system)
418 (arguments
419 `(#:python ,python-2
420 #:tests? #f
421 #:phases
422 (modify-phases %standard-phases
423 (add-after 'unpack 'unbundle-dejavu-font
424 (lambda* (#:key inputs #:allow-other-keys)
425 (let* ((dejavu-dir
426 (string-append (assoc-ref inputs "font-dejavu")
427 "/share/fonts/truetype"))
428 (dejavu-font
429 (string-append dejavu-dir
430 "/DejaVuSansCondensed-Bold.ttf")))
431 (substitute* "SPConstants.py"
432 (("^(TTF(BOLD)? = ).*" _ prefix)
433 (string-append prefix "'" dejavu-font "'\n")))
434 (for-each (lambda (f) (delete-file f))
435 (find-files "lib/SPData" "DejaVu"))
436 #t)))
437 (delete 'build)
438 (replace 'install
439 (lambda* (#:key outputs #:allow-other-keys)
440 (let* ((out (assoc-ref outputs "out"))
441 (pixmaps (string-append out "/share/pixmaps"))
442 (share (string-append out "/share/childsplay"))
443 (doc (string-append out "/share/doc/" ,name "-",version)))
444 ;; Install icon.
445 (install-file "lib/SPData/themes/childsplay/logo_cp.svg" pixmaps)
446 ;; Install data.
447 (mkdir-p share)
448 (for-each (lambda (f)
449 (copy-recursively f (string-append share "/" f)))
450 '("alphabet-sounds" "lib" "locale" "SPWidgets"))
451 (for-each (lambda (f) (install-file f share))
452 (find-files "." "\\.(py|dev|db)$"))
453 ;; Install documentation.
454 (mkdir-p doc)
455 (copy-recursively "docs" doc)
456 #t)))
457 (add-after 'install 'create-executable
458 (lambda* (#:key outputs inputs #:allow-other-keys)
459 (let* ((python (string-append (assoc-ref inputs "python")
460 "/bin/python"))
461 (out (assoc-ref outputs "out"))
462 (bin (string-append out "/bin"))
463 (executable (string-append bin "/childsplay")))
464 (mkdir-p bin)
465 (call-with-output-file executable
466 (lambda (file)
467 (format file
468 "~a ~a"
469 python
470 (string-append out "/share/childsplay/childsplay.py"))))
471 (chmod executable #o555)
472 #t)))
473 (add-after 'install 'create-desktop-file
474 (lambda* (#:key outputs #:allow-other-keys)
475 (let* ((out (assoc-ref outputs "out"))
476 (applications (string-append out "/share/applications")))
477 (mkdir-p applications)
478 (call-with-output-file
479 (string-append applications "/childsplay.desktop")
480 (lambda (file)
481 (format file
482 "[Desktop Entry]~@
483 Name=Childsplay~@
484 Comment=Suite of educational games for young children~@
485 Comment[ca]=Conjunt de jocs educatius per a xiquets~@
486 Comment[es]=Conjunto de juegos educativos para niños~@
487 Comment[de]=Sammlung mit lehrreichen Spielen für kleine Kinder~@
488 Exec=~a/bin/childsplay~@
489 Terminal=false~@
490 Icon=logo_cp.svg~@
491 Type=Application~@
492 Categories=Application;Game;Education;KidsGame;~@
493 Keywords=suite;children;games;young;educational;~%"
494 out)))
495 #t))))))
496 (inputs
497 `(("font-dejavu" ,font-dejavu)
498 ("pygame" ,python2-pygame)
499 ("sqlalchemy" ,python2-sqlalchemy)))
500 (synopsis "Suite of educational games for young children")
501 (description "Childsplay is a collection of educational activities
502 for young children. Childsplay can be used at home, kindergartens and
503 pre-schools. Childsplay is a fun and safe way to let young children
504 use the computer and at the same time teach them a little math,
505 letters of the alphabet, spelling, eye-hand coordination, etc.")
506 (home-page "http://www.schoolsplay.org")
507 (license license:gpl3+)))
508
509 (define-public omnitux
510 (package
511 (name "omnitux")
512 (version "1.2.1")
513 (source
514 (origin
515 (method url-fetch)
516 (uri (string-append "mirror://sourceforge/omnitux/omnitux/"
517 "v" version "/omnitux-" version ".tar.bz2"))
518 (sha256
519 (base32 "1wmmmbzmxd0blhn00d4g91xwavnab143a31ca3i8hrqgzh6qz9w6"))
520 (modules '((guix build utils)))
521 (snippet
522 '(begin
523 ;; Remove pre-compiled .pyc files from source.
524 (for-each delete-file (find-files "bin" "\\.pyc$"))
525 #t))))
526 (build-system python-build-system)
527 (inputs
528 `(("python2-pygame" ,python2-pygame)
529 ("python2-pygtk" ,python2-pygtk)))
530 (arguments
531 `(#:tests? #f ;no test
532 #:python ,python-2
533 #:phases
534 (modify-phases %standard-phases
535 (delete 'build) ;no setup.py
536 (replace 'install
537 (lambda* (#:key outputs #:allow-other-keys)
538 (let* ((out (assoc-ref outputs "out"))
539 (share (string-append out "/share"))
540 (data (string-append share "/omnitux")))
541 ;; Install documentation.
542 (let ((doc (string-append share "/doc/" ,name "-" ,version)))
543 (for-each (lambda (f) (install-file f doc))
544 '("LICENSE.txt" "README.txt")))
545 ;; Install data.
546 (install-file "omnitux.sh" data)
547 (for-each (lambda (d)
548 (copy-recursively d (string-append data "/" d)))
549 '("bin" "data"))
550 ;; Install the launcher.
551 (let* ((bin (string-append out "/bin"))
552 (script (string-append bin "/omnitux"))
553 (bash (string-append (assoc-ref %build-inputs "bash")
554 "/bin/bash"))
555 (python (string-append (assoc-ref %build-inputs "python")
556 "/bin/python2")))
557 (mkdir-p bin)
558 (with-output-to-file script
559 (lambda ()
560 (format #t "#!~a~%" bash)
561 (format #t
562 "cd ~a; ~a menu.py~%"
563 (string-append data "/bin")
564 python)))
565 (chmod script #o755))
566 ;; Install icon and desktop file.
567 (let ((pixmaps (string-append share "/pixmaps")))
568 (install-file "data/default/icons/Omnitux_logo.svg" pixmaps))
569 (let ((apps (string-append out "/share/applications")))
570 (mkdir-p apps)
571 (with-output-to-file (string-append apps "/omnitux.desktop")
572 (lambda _
573 (format #t
574 "[Desktop Entry]~@
575 Name=Omnitux~@
576 GenericName=Omnitux
577 Comment=An educational game based on multimedia elements.~@
578 Comment[fr]=Un jeu ludo-éducatif basé sur des éléments multimédias.~@
579 Exec=~a/bin/omnitux~@
580 Type=Application~@
581 Categories=Game;Education;~@
582 Terminal=false~@
583 Icon=Omnitux_logo.svg~@"
584 out))))
585 #t))))))
586 (home-page "http://omnitux.sourceforge.net/")
587 (synopsis "Educational activities based on multimedia elements")
588 (description "The project aims to provide various educational
589 activities around multimedia elements (images, sounds, texts). Types
590 of activities include:
591 @itemize
592 @item associations,
593 @item items to place on a map or a schema,
594 @item counting activities,
595 @item puzzles,
596 @item card faces to remember,
597 @item find differences between two pictures,
598 @item ...
599 @end itemize
600
601 Activities are available in English, French, German, Polish,
602 Portuguese, Spanish and Italian.")
603 ;; Project's license is GPL3+, but multimedia elements are
604 ;; released under various licenses.
605 (license (list license:gpl3+
606 license:gpl2+
607 license:cc-by-sa2.0
608 license:cc-by-sa3.0
609 license:public-domain))))
610
611 (define-public fet
612 (package
613 (name "fet")
614 (version "5.48.1")
615 (source
616 (origin
617 (method url-fetch)
618 (uri (string-append "https://www.lalescu.ro/liviu/fet/download/"
619 "fet-" version ".tar.bz2"))
620 (sha256
621 (base32 "0k728l6zi0lkhzyipsb0f2jw53s4xicm7arp33ikhrvc4jlwcp4v"))))
622 (build-system gnu-build-system)
623 (arguments
624 `(#:phases
625 (modify-phases %standard-phases
626 (add-after 'unpack 'fix-hardcoded-directories
627 (lambda* (#:key outputs #:allow-other-keys)
628 (substitute* (list "fet.pro"
629 "src/src.pro"
630 "src/src-cl.pro"
631 "src/interface/fet.cpp")
632 (("/usr") (assoc-ref outputs "out")))
633 #t))
634 (replace 'configure
635 (lambda _ (invoke "qmake" "fet.pro"))))))
636 (inputs
637 `(("qtbase" ,qtbase)))
638 (home-page "https://www.lalescu.ro/liviu/fet/")
639 (synopsis "Timetabling software")
640 (description
641 "FET is a program for automatically scheduling the timetable of a school,
642 high-school or university. It uses a fast and efficient timetabling
643 algorithm.
644
645 Usually, FET is able to solve a complicated timetable in maximum 5-20 minutes.
646 For extremely difficult timetables, it may take a longer time, a matter of
647 hours.")
648 (license license:agpl3+)))
649
650 (define-public klavaro
651 (package
652 (name "klavaro")
653 (version "3.11")
654 (source
655 (origin
656 (method url-fetch)
657 (uri (string-append "mirror://sourceforge/klavaro/klavaro-"
658 version ".tar.bz2"))
659 (sha256
660 (base32 "1rkxaqb62w4mv86fcnmr32lq6y0h4hh92wmsy5ddb9a8jnzx6r7w"))))
661 (build-system gnu-build-system)
662 (native-inputs
663 `(("intltool" ,intltool)
664 ("pkg-config" ,pkg-config)))
665 (inputs
666 `(("cairo" ,cairo)
667 ("curl" ,curl)
668 ("gtk+" ,gtk+)
669 ("pango" ,pango)))
670 (home-page "https://klavaro.sourceforge.io/en/index.html")
671 (synopsis "Touch typing tutor")
672 (description
673 "Klavaro is a simple tutor to teach correct typing, almost independently of
674 language and very flexible regarding to new or unknown keyboard layouts.")
675 (license license:gpl3+)))
676
677 (define-public ktouch
678 (package
679 (name "ktouch")
680 (version "19.08.3")
681 (source
682 (origin
683 (method url-fetch)
684 (uri (string-append "mirror://kde/stable/applications/"
685 version "/src/ktouch-" version ".tar.xz"))
686 (sha256
687 (base32
688 "0dqxb3xsjc2rwc9779l5fnr4crhq51bc8ln4azbgnnkzldvq6a4a"))))
689 (build-system qt-build-system)
690 (arguments
691 `(#:phases
692 (modify-phases %standard-phases
693 (add-after 'configure 'patch-makefiles
694 (lambda* (#:key inputs #:allow-other-keys)
695 (let ((qtdec (assoc-ref inputs "qtdeclarative")))
696 (substitute* '("src/CMakeFiles/ktouch_autogen.dir/build.make"
697 "src/CMakeFiles/ktouch.dir/build.make")
698 (("/gnu/store/.*qmlcachegen")
699 (string-append qtdec "/bin/qmlcachegen"))))
700 #t)))))
701 (native-inputs
702 `(("extra-cmake-modules" ,extra-cmake-modules)
703 ("kdoctools" ,kdoctools)
704 ("pkg-config" ,pkg-config)))
705 (inputs
706 `(("kcmutils" ,kcmutils)
707 ("kcompletion" ,kcompletion)
708 ("kconfig" ,kconfig)
709 ("kconfigwidgets" ,kconfigwidgets)
710 ("kcoreaddons" ,kcoreaddons)
711 ("kdeclarative" ,kdeclarative)
712 ("ki18n" ,ki18n)
713 ("kiconthemes" ,kiconthemes)
714 ("kitemviews" ,kitemviews)
715 ("kqtquickcharts" ,kqtquickcharts)
716 ("ktextwidgets" ,ktextwidgets)
717 ("kwidgetsaddons" ,kwidgetsaddons)
718 ("kwindowsystem" ,kwindowsystem)
719 ("kxmlgui" ,kxmlgui)
720 ("libxcb" ,libxcb)
721 ("libxkbfile" ,libxkbfile)
722 ("qtbase" ,qtbase)
723 ("qtdeclarative" ,qtdeclarative)
724 ("qtgraphicaleffects" ,qtgraphicaleffects)
725 ("qtquickcontrols2" ,qtquickcontrols2)
726 ("qtx11extras" ,qtx11extras)
727 ("qtxmlpatterns" ,qtxmlpatterns)))
728 (home-page "https://edu.kde.org/ktouch/")
729 (synopsis "Touch typing tutor")
730 (description
731 "KTouch is an aid for learning how to type with speed and accuracy. It
732 provides a sample text to type and indicates which fingers should be used for
733 each key. A collection of lessons are included for a wide range of different
734 languages and keyboard layouts, and typing statistics are used to dynamically
735 adjust the level of difficulty.")
736 (license license:gpl2)))
737
738 (define-public anki
739 (package
740 (name "anki")
741 ;; Later versions have dependencies on npm packages not yet in Guix.
742 (version "2.1.16")
743 (source
744 (origin
745 (method url-fetch)
746 (uri (string-append "https://apps.ankiweb.net/downloads/archive/anki-"
747 version "-source.tgz"))
748 (sha256
749 (base32 "1gfr51rnllkyzli73p4r51h5ypzfa3m7lic3m3rzpywmqwrxs07k"))
750 (patches (search-patches "anki-mpv-args.patch"))))
751 (build-system gnu-build-system)
752 (arguments
753 `(#:make-flags (list (string-append "PREFIX=" %output))
754 #:tests? #f ;no check target
755 #:modules ((guix build gnu-build-system)
756 (guix build utils)
757 (ice-9 match))
758 #:phases
759 (modify-phases %standard-phases
760 (add-after 'unpack 'disable-update-check
761 ;; Don't ‘phone home’ unasked to check for updates.
762 (lambda _
763 (substitute* "aqt/update.py"
764 (("requests\\.post")
765 "throw.an.exception.instead"))
766 #t))
767 (delete 'configure) ;no configure script
768 (add-after 'install 'wrap
769 (lambda* (#:key inputs outputs #:allow-other-keys)
770 (let ((bin (string-append (assoc-ref outputs "out") "/bin"))
771 ;; List of paths to the site-packages directories of Python
772 ;; library inputs.
773 (site-packages
774 (map (lambda (pyinput)
775 (string-append
776 (cdr pyinput)
777 "/lib/python"
778 ;; Calculate the python version to avoid breaking
779 ;; with future 3.X releases.
780 ,(version-major+minor
781 (package-version python-wrapper))
782 "/site-packages"))
783 (filter (match-lambda
784 ((label . _)
785 (string-prefix? "python-" label)))
786 inputs)))
787 (qtwebengineprocess
788 (string-append (assoc-ref inputs "qtwebengine")
789 "/lib/qt5/libexec/QtWebEngineProcess")))
790 ;; The program fails to find the QtWebEngineProcess program, so
791 ;; we set QTWEBENGINEPROCESS_PATH to help it. PYTHONPATH is
792 ;; wrapped to avoid declaring Python libraries as propagated
793 ;; inputs.
794 (for-each (lambda (program)
795 (wrap-program program
796 `("QTWEBENGINEPROCESS_PATH" =
797 (,qtwebengineprocess))
798 `("PATH" prefix (,(string-append
799 (assoc-ref inputs "mpv")
800 "/bin")))
801 `("PYTHONPATH" = ,site-packages)))
802 (find-files bin ".")))
803 #t)))))
804 (native-inputs
805 `(("xdg-utils" ,xdg-utils)))
806 (inputs
807 `(("lame" ,lame)
808 ("mpv" ,mpv)
809 ("python" ,python-wrapper)
810 ("python-beautifulsoup4" ,python-beautifulsoup4)
811 ("python-decorator" ,python-decorator)
812 ("python-distro" ,python-distro)
813 ("python-jsonschema" ,python-jsonschema)
814 ("python-markdown" ,python-markdown)
815 ("python-pyaudio" ,python-pyaudio)
816 ;; `python-pyqtwebengine' must precede `python-pyqt' in PYTHONPATH.
817 ("python-pyqtwebengine" ,python-pyqtwebengine)
818 ("python-pyqt" ,python-pyqt)
819 ("python-requests" ,python-requests)
820 ("python-send2trash" ,python-send2trash)
821 ("python-sip" ,python-sip)
822 ;; `qtwebengine' is included in `pyqtwebengine', included here for easy
823 ;; wrapping.
824 ("qtwebengine" ,qtwebengine)))
825 (home-page "https://apps.ankiweb.net/")
826 (synopsis "Powerful, intelligent flash cards")
827 (description "Anki is a program which makes remembering things
828 easy. Because it's a lot more efficient than traditional study
829 methods, you can either greatly decrease your time spent studying, or
830 greatly increase the amount you learn.
831
832 Anyone who needs to remember things in their daily life can benefit
833 from Anki. Since it is content-agnostic and supports images, audio,
834 videos and scientific markup (via LaTeX), the possibilities are
835 endless. For example:
836 @itemize
837 @item Learning a language
838 @item Studying for medical and law exams
839 @item Memorizing people's names and faces
840 @item Brushing up on geography
841 @item Mastering long poems
842 @item Even practicing guitar chords!
843 @end itemize")
844 (license license:agpl3+)))
845
846 (define-public t4k-common
847 (package
848 (name "t4k-common")
849 (version "0.1.1")
850 (source
851 (origin
852 (method git-fetch)
853 (uri (git-reference
854 (url "https://github.com/tux4kids/t4kcommon")
855 (commit (string-append "upstream/" version))))
856 (file-name (git-file-name name version))
857 (sha256
858 (base32 "13q02xpmps9qg8zrzzy2gzv4a6afgi28lxk4z242j780v0gphchp"))
859 (patches
860 (search-patches "t4k-common-libpng16.patch"))))
861 (build-system cmake-build-system)
862 (arguments
863 `(#:tests? #f ;FIXME: cannot find how to run tests
864 #:phases
865 (modify-phases %standard-phases
866 (add-after 'set-paths 'set-sdl-paths
867 (lambda* (#:key inputs #:allow-other-keys)
868 (setenv "CPATH" (string-append (assoc-ref inputs "sdl")
869 "/include/SDL:"
870 (or (getenv "CPATH") "")))))
871 (add-after 'unpack 'fix-andika-font-path
872 (lambda* (#:key inputs #:allow-other-keys)
873 (substitute* "src/t4k_sdl.c"
874 (("(/usr/share/.*?)/AndikaDesRevG\\.ttf")
875 (string-append (assoc-ref inputs "font-andika")
876 "/share/fonts/truetype")))
877 #t)))))
878 (native-inputs
879 `(("pkg-config" ,pkg-config)))
880 (inputs
881 `(("font-andika" ,font-sil-andika)
882 ("libpng" ,libpng)
883 ("librsvg" ,librsvg)
884 ("libxml2" ,libxml2)
885 ("sdl" ,(sdl-union (list sdl sdl-image sdl-mixer sdl-net sdl-pango)))))
886 (home-page "https://github.com/tux4kids/t4kcommon")
887 (synopsis "Library of code shared between TuxMath and TuxType")
888 (description "Tux4Kids-Common is a library of code shared between
889 TuxMath and TuxType.")
890 (license license:gpl3+)))
891
892 (define-public tuxmath
893 (package
894 (name "tuxmath")
895 (version "2.0.3")
896 (source
897 (origin
898 (method git-fetch)
899 (uri (git-reference
900 (url "https://github.com/tux4kids/tuxmath")
901 (commit (string-append "upstream/" version))))
902 (file-name (git-file-name name version))
903 (sha256
904 (base32 "1f1pz83w6d3mbik2h6xavfxmk5apxlngxbkh80x0m55lhniwkdxv"))
905 (modules '((guix build utils)))
906 ;; Unbundle fonts.
907 (snippet
908 `(begin
909 (for-each delete-file (find-files "data/fonts" "\\.ttf$"))
910 #t))))
911 (build-system gnu-build-system)
912 (arguments
913 `(#:tests? #f ;no test
914 #:phases
915 (modify-phases %standard-phases
916 (add-after 'set-paths 'set-sdl-paths
917 (lambda* (#:key inputs #:allow-other-keys)
918 (setenv "CPATH"
919 (string-append (assoc-ref inputs "sdl")
920 "/include/SDL:"
921 (or (getenv "CPATH") "")))
922 #t))
923 (add-after 'install 'install-desktop-file
924 (lambda* (#:key outputs #:allow-other-keys)
925 (let* ((out (assoc-ref outputs "out"))
926 (apps (string-append out "/share/applications"))
927 (pixmaps (string-append out "/share/pixmaps")))
928 (install-file "tuxmath.desktop" apps)
929 (for-each (lambda (f) (install-file f pixmaps))
930 (find-files "data/images/icons/"
931 "tuxmath\\.(png|ico|svg)$"))
932 #t))))))
933 (native-inputs
934 `(("pkg-config" ,pkg-config)))
935 (inputs
936 `(("librsvg" ,librsvg)
937 ("libxml2" ,libxml2)
938 ("sdl" ,(sdl-union (list sdl sdl-image sdl-mixer sdl-net sdl-pango)))
939 ("t4k-common" ,t4k-common)))
940 (home-page "https://github.com/tux4kids/tuxmath")
941 (synopsis "Educational math tutorial game")
942 (description "@emph{Tux, of Math Command} is an educational math
943 tutorial game starring Tux, the Linux penguin, in which you play the
944 part of Commander Tux, as he defends his friends from an attack of
945 math equations. Comets are crashing towards the friendly penguins in
946 their igloos, and you must destroy the comets by solving their
947 equations.
948
949 TuxMath also includes Factoroids, a game that gives practice in
950 factoring numbers and simplifying fractions, as well as zapping rocks
951 floating through space.")
952 (license license:gpl3+)))
953
954 (define-public mdk
955 (package
956 (name "mdk")
957 (version "1.3.0")
958 (source
959 (origin
960 (method url-fetch)
961 (uri (string-append "mirror://gnu/mdk/v" version "/mdk-"
962 version ".tar.gz"))
963 (sha256
964 (base32
965 "0bhk3c82kyp8167h71vdpbcr852h5blpnwggcswqqwvvykbms7lb"))))
966 (build-system gnu-build-system)
967 (arguments
968 `(#:configure-flags (list "--enable-gui=yes" "-with-readline=yes")))
969 (native-inputs
970 `(("flex" ,flex)
971 ("intltool" ,intltool)
972 ("pkg-config" ,pkg-config)))
973 (inputs
974 `(("glib" ,glib)
975 ("gtk+" ,gtk+)
976 ("libglade" ,libglade)
977 ("ncurses" ,ncurses)
978 ("pango" ,pango)
979 ("readline" ,readline)))
980 (home-page "https://www.gnu.org/software/mdk/manual/")
981 (synopsis "Virtual development environment for Knuth's MIX")
982 (description
983 "GNU MDK is the Mix Development Kit, an emulation of the pedagogical
984 computer MIX and its assembly language MIXAL. MIX has a virtual CPU with
985 standard features such as registers, memory cells, an overflow toggle,
986 comparison flags, input-output devices, and a set of binary instructions.
987 The package includes a compiler, a virtual machine, a GUI for the virtual
988 machine, and more.")
989 (license license:gpl3+)))
990
991 (define-public exercism
992 (package
993 (name "exercism")
994 (version "3.0.13")
995 (source
996 (origin
997 (method git-fetch)
998 (uri (git-reference
999 (url "https://github.com/exercism/cli")
1000 (commit (string-append "v" version))))
1001 (file-name (git-file-name name version))
1002 (sha256
1003 (base32
1004 "17gvz9a0sn4p36hf4l77bxhhfipf4x998iay31layqwbnzmb4xy7"))
1005 (patches (search-patches "exercism-disable-self-update.patch"))))
1006 (build-system go-build-system)
1007 (arguments
1008 `(#:import-path "github.com/exercism/cli/exercism"
1009 #:unpack-path "github.com/exercism/cli"
1010 #:install-source? #f))
1011 (inputs
1012 `(("github.com/blang/semver" ,go-github-com-blang-semver)
1013 ("github.com/spf13/cobra" ,go-github-com-spf13-cobra)
1014 ("github.com/spf13/pflag" ,go-github-com-spf13-pflag)
1015 ("github.com/spf13/viper" ,go-github-com-spf13-viper)
1016 ("golang.org/x/net" ,go-golang-org-x-net)
1017 ("golang.org/x/text" ,go-golang-org-x-text)))
1018 (home-page "https://exercism.io")
1019 (synopsis "Mentored learning for programming languages")
1020 (description "Commandline client for exercism.io, a free service providing
1021 mentored learning for programming languages.")
1022 (license license:expat)))